Monorepo for Aesthetic.Computer aesthetic.computer
at main 42 lines 1.2 kB view raw
1#!/usr/bin/env bash 2 3# boot up the platform in a terminal 4# running emacs inside 5clear 6 7echo -e "\n\033[1;37m*** Booting the Aesthetic Computer Platform ***\033[0m\n" 8 9# clear out everything inside .emacs.d except the .gitignore 10if [ "$1" = "reset:emacs" ]; then 11 echo "*** -> Clearing emacs plugins." 12 cd ~/.emacs.d 13 find . -mindepth 1 -maxdepth 1 -not -name '.gitignore' -not -name '.' -not -name '..' | xargs rm -rf > /dev/null 2>&1 14 cd - > /dev/null 15else 16 echo "*** -> Using cached emacs configuration." 17fi 18 19echo "*** -> Starting emacs daemon..." 20 21# Kill any existing emacs daemon 22emacsclient -e '(kill-emacs)' 2>/dev/null || true 23 24# Start emacs daemon with the aesthetic computer configuration 25emacs -q --daemon -l ~/aesthetic-computer/dotfiles/dot_config/emacs.el 26 27# Wait for daemon to be ready 28echo "*** -> Waiting for daemon to be ready..." 29while ! emacsclient -e 't' >/dev/null 2>&1; do 30 sleep 1 31done 32 33if [ "$1" = "fish" ]; then 34 echo "*** -> Starting fish shell..." 35 fish 36else 37 echo "*** -> Starting emacsclient..." 38 # Start emacsclient with aesthetic backend 39 emacsclient -c --eval "(aesthetic-backend (quote \"$1\"))" 40fi 41 42echo -e "\n\033[1;35m*** Goodbye ***\033[0m\n"