@@ -0,0 +1,43 @@
1+{ stdenv, fetchurl, emacs, python }:
2+
3+stdenv.mkDerivation rec {
4+ name = "cask-${version}";
5+ version = "0.8.4";
6+
7+ src = fetchurl {
8+ url = "https://github.com/cask/cask/archive/v${version}.tar.gz";
9+ sha256 = "02f8bb20b33b23fb11e7d2a1d282519dfdb8b3090b9672448b8c2c2cacd3e478";
10+ };
11+
12+ doCheck = true;
13+
14+ dontBuild = true;
15+
16+ installPhase = ''
17+ mkdir -p $out/bin
18+ mkdir -p $out/templates
19+ install -Dm644 *.el $out/
20+ install -Dm755 bin/cask $out/bin
21+ install -Dm644 templates/* $out/templates/
22+ touch $out/.no-upgrade
23+ mkdir -p $out/usr/share/emacs/site-lisp/cask
24+ ln -s cask{,-bootstrap}.el $out/usr/share/emacs/site-lisp/cask/
25+ '';
26+
27+ meta = with stdenv.lib; {
28+ description = "Project management for Emacs";
29+ longDescription = ''
30+ Cask is a project management tool for Emacs that helps automate the
31+ package development cycle; development, dependencies, testing, building,
32+ packaging and more.
33+ Cask can also be used to manage dependencies for your local Emacs configuration.
34+ '';
35+
36+ homepage = https://cask.readthedocs.io/en/latest/index.html;
37+ license = licenses.gpl3Plus;
38+ platforms = platforms.linux;
39+ maintainers = [ maintainers.flexw ];
40+ };
41+
42+ nativeBuildInputs = [ emacs python ];
43+}