about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--init/functions.el7
1 files changed, 7 insertions, 0 deletions
diff --git a/init/functions.el b/init/functions.el
index c0169955a19a..019bf1646079 100644
--- a/init/functions.el
+++ b/init/functions.el
@@ -224,4 +224,11 @@ Including indent-buffer, which should not be called automatically on save."
          (last-window (car (seq-intersection right-windows bottom-windows))))
     (eq (current-buffer) (window-buffer last-window))))
 
+(defun inferior-erlang-nix-shell ()
+  "Start an inferior Erlang process from the root of the current
+  project."
+  (interactive)
+  (inferior-erlang
+   (format "nix-shell --command erl %s" (cdr (project-current)))))
+
 (provide 'functions)