Files
dotfiles/gen-gh-pages/compile.sh

26 lines
596 B
Bash
Raw Normal View History

2016-12-28 02:08:34 -08:00
#!/usr/bin/env bash
# Local compilation script for generating HTML from README.org
# Note: For CI, this is now handled by GitHub Actions (.github/workflows/gh-pages.yml)
set -e
2016-12-28 02:08:34 -08:00
THIS_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
# Use system emacs or EMACS environment variable
EMACS="${EMACS:-emacs}"
2016-12-28 02:08:34 -08:00
cd "$THIS_DIR"
2016-12-28 02:08:34 -08:00
# Install cask dependencies if needed
if [ ! -d ".cask" ]; then
cask install
fi
2016-12-28 02:08:34 -08:00
# Generate HTML
2017-09-10 03:42:27 -07:00
cask exec "$EMACS" --script generate-html.el
2016-12-28 02:08:34 -08:00
# Move the generated file
mv "$THIS_DIR/../dotfiles/emacs.d/README.html" .
2017-09-08 12:57:43 -07:00
echo "Generated README.html in $THIS_DIR"