about summary refs log tree commit diff
path: root/users/wpcarro/emacs/pkgs/maybe/default.nix
diff options
context:
space:
mode:
authorWilliam Carroll <wpcarro@gmail.com>2022-07-29T18·15-0700
committerclbot <clbot@tvl.fyi>2022-07-30T00·35+0000
commit230c4bbb3e9f44875d6593a7c6cb0ca33bb63805 (patch)
tree55207bf03a894ffdd2b5687216081ee81e3fb195 /users/wpcarro/emacs/pkgs/maybe/default.nix
parent4a4f8f93583df81344dd1c91f033d8644028dc85 (diff)
feat(wpcarro/emacs): Package maybe.el r/4344
(Temporarily) remove dependency on list.el in favor of dash, which I'm not
thrilled about.

Change-Id: Ic4348ee72582dee63ba07a183f3bda65baa7e2d6
Reviewed-on: https://cl.tvl.fyi/c/depot/+/5999
Reviewed-by: wpcarro <wpcarro@gmail.com>
Autosubmit: wpcarro <wpcarro@gmail.com>
Tested-by: BuildkiteCI
Diffstat (limited to 'users/wpcarro/emacs/pkgs/maybe/default.nix')
-rw-r--r--users/wpcarro/emacs/pkgs/maybe/default.nix24
1 files changed, 24 insertions, 0 deletions
diff --git a/users/wpcarro/emacs/pkgs/maybe/default.nix b/users/wpcarro/emacs/pkgs/maybe/default.nix
new file mode 100644
index 000000000000..68e058b42b19
--- /dev/null
+++ b/users/wpcarro/emacs/pkgs/maybe/default.nix
@@ -0,0 +1,24 @@
+{ pkgs, depot, ... }:
+
+let
+  maybe = pkgs.callPackage
+    ({ emacsPackages }:
+      emacsPackages.trivialBuild {
+        pname = "maybe";
+        version = "1.0.0";
+        src = ./maybe.el;
+        packageRequires = [ ];
+      })
+    { };
+
+  emacs = (pkgs.emacsPackagesFor pkgs.emacs28).emacsWithPackages (epkgs: [
+    maybe
+  ]);
+in
+maybe.overrideAttrs (_old: {
+  doCheck = true;
+  checkPhase = ''
+    ${emacs}/bin/emacs -batch \
+      -l ert -l ${./tests.el} -f ert-run-tests-batch-and-exit
+  '';
+})