nixpkgs/pkgs/development/tools/cask/default.nix

55 lines
1.5 KiB
Nix
Raw Normal View History

{ lib, stdenv, python3, emacs, bash }:
2019-03-31 23:18:17 +02:00
stdenv.mkDerivation rec {
pname = "cask";
2019-03-31 23:18:17 +02:00
inherit (emacs.pkgs.melpaStablePackages.cask) src version;
2019-03-31 23:18:17 +02:00
doCheck = true;
nativeBuildInputs = [ emacs ];
buildInputs = with emacs.pkgs; [
s f dash ansi ecukes servant ert-runner el-mock
noflet ert-async shell-split-string git package-build
] ++ [
2021-03-25 11:21:54 +01:00
python3
bash
];
2021-03-25 11:21:54 +01:00
strictDeps = true;
buildPhase = ''
runHook preBuild
emacs --batch -L . -f batch-byte-compile cask.el cask-cli.el
runHook postBuild
'';
2019-03-31 23:18:17 +02:00
installPhase = ''
runHook preInstall
2019-03-31 23:18:17 +02:00
mkdir -p $out/bin
mkdir -p $out/templates
mkdir -p $out/share/emacs/site-lisp/cask/bin
install -Dm644 *.el *.elc $out/share/emacs/site-lisp/cask
install -Dm755 bin/cask $out/share/emacs/site-lisp/cask/bin
2019-03-31 23:18:17 +02:00
install -Dm644 templates/* $out/templates/
touch $out/.no-upgrade
ln -s $out/share/emacs/site-lisp/cask/bin/cask $out/bin/cask
runHook postInstall
2019-03-31 23:18:17 +02:00
'';
meta = with lib; {
2019-03-31 23:18:17 +02:00
description = "Project management 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://cask.readthedocs.io/en/latest/index.html";
2019-03-31 23:18:17 +02:00
license = licenses.gpl3Plus;
platforms = platforms.all;
2019-03-31 23:18:17 +02:00
maintainers = [ maintainers.flexw ];
};
}