Created
February 13, 2017 21:02
-
-
Save anonymous/78faa02b66c7da10613011dda8d75a29 to your computer and use it in GitHub Desktop.
Pretty print emacs s expressions from the command line
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -o errexit | |
set -o nounset | |
set -o pipefail | |
if [ "$#" != "1" ]; then | |
echo "Needs precisely one argument" 2>&1 | |
exit 1 | |
fi; | |
emacs -q --batch --eval \ | |
$'(progn (package-initialize) (require \'f) (message (pp (read (f-read (car command-line-args-left))))))' "$1" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment