nixpkgs/pkgs/applications/editors/emacs-modes/cask/default.nix

55 lines
1.6 KiB
Nix
Raw Normal View History

2016-07-21 00:06:36 +01:00
{ stdenv, fetchFromGitHub, emacs, python }:
2014-09-17 23:46:45 +01:00
stdenv.mkDerivation rec {
2016-10-29 21:51:23 +01:00
version = "0.8.1";
2016-07-21 00:06:36 +01:00
name = "cask-${version}";
2014-09-17 23:46:45 +01:00
2016-07-21 00:06:36 +01:00
src = fetchFromGitHub {
owner = "cask";
repo = "cask";
rev = "v${version}";
2016-10-29 21:51:23 +01:00
sha256 = "1sl094adnchjvf189c3l1njawrj5ww1sv5vvjr9hb1ng2rw20z7b";
2014-09-17 23:46:45 +01:00
};
buildInputs = [ emacs python ];
# byte-compiling emacs files automatically triggers cask's bootstrap
# mechanism, what we don't want.
dontBuild = true;
installPhase = ''
install -d "$out/share/emacs/site-lisp"
install cask*.el* "$out/share/emacs/site-lisp"
install -d "$out/bin"
install bin/cask "$out/bin"
# We also need to install cask's templates in order for 'cask
# init' to work properly.
install -d "$out/templates"
install templates/* "$out/templates"
2014-09-17 23:46:45 +01:00
# In order to work with cask's hard coded file paths (during bootstrap),
# we have to create these links.
ln -s "$out/share/emacs/site-lisp/"* "$out"
# This file disables cask's self-updating function.
touch "$out/.no-upgrade"
'';
meta = with stdenv.lib; {
description = "Project management tool for Emacs";
longDescription =
''
Cask is a project management tool for Emacs that helps automate the
package development cycle; development, dependencies, testing,
building, packaging and more. Cask can also be used to manage
dependencies for your local Emacs configuration.
'';
homepage = "https://github.com/cask/cask";
license = licenses.gpl3Plus;
platforms = platforms.all;
maintainers = [ maintainers.jgeerds ];
};
}