From 1e0b44c8a74365faccc1184dc6ddcf1eb7e0c5bc Mon Sep 17 00:00:00 2001 From: Gianluca Recchia Date: Sat, 29 Feb 2020 17:29:22 +0100 Subject: [PATCH] add support for elisp scripts --- lxc/execute | 3 +++ lxc/executors/emacs | 2 ++ tests/test.el | 1 + 3 files changed, 6 insertions(+) create mode 100644 lxc/executors/emacs create mode 100644 tests/test.el diff --git a/lxc/execute b/lxc/execute index 8bbea7d..f7082ca 100755 --- a/lxc/execute +++ b/lxc/execute @@ -87,6 +87,9 @@ case "$lang" in "rust") bin=rust ;; +"elisp" | "el") + bin=emacs + ;; "bash") bin=bash ;; diff --git a/lxc/executors/emacs b/lxc/executors/emacs new file mode 100644 index 0000000..dcff507 --- /dev/null +++ b/lxc/executors/emacs @@ -0,0 +1,2 @@ +cd /tmp/$2 +runuser -l runner$1 -c "cd /tmp/$2 ; cat args.args | xargs -d '\n' timeout -s KILL 3 emacs -Q --script code.code" diff --git a/tests/test.el b/tests/test.el new file mode 100644 index 0000000..2c2a402 --- /dev/null +++ b/tests/test.el @@ -0,0 +1 @@ +(message "good")