|
From: | Emanuel Berg |
Subject: | Re: Start Emacs with a minimal bash and Emacs lisp mixed script for testing. |
Date: | Tue, 03 Aug 2021 17:55:15 +0200 |
User-agent: | Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) |
Hongyi Zhao wrote: > #!/usr/bin/env bash > :; set -e # -*- mode: emacs-lisp; lexical-binding: t -*- > :; # https://github.com/abo-abo/swiper/issues/2899#issuecomment-889926472 > :; # https://github.com/hlissner/doom-emacs/blob/develop/bin/doom > :; emacs -Q --load "$(realpath -e $0)" -- "$@" > > ;;Bootstrap straight > [...] > > But when quit Emacs with `C-x C-c', the script always complains the > following info: > > init.the-bash-elisp-mix-script: line 7: syntax error near > unexpected token `;;' The bash script will continue to execute after you kill Emacs. Try: #! /bin/bash :; set -e :; emacs -Q --load "$(realpath -e $0)" -- "$@"; exit (setq test-var 3) Then type test-var and do `eval-last-sexp'. -- underground experts united https://dataswamp.org/~incal
[Prev in Thread] | Current Thread | [Next in Thread] |