loop-main() {
# When running under systemd, the system just started. Ve nice and
# give programs some time to finish their startup.
- sleep 5
+ sleep 10
while true; do
premain_sec=$EPOCHSECONDS
main
if [[ ! $last_emacs_check || $emacsfiles ]] || (( last_emacs_check < EPOCHSECONDS - 300 )); then
if pgrep -G iank -u iank -f 'emacs --daemon' &>/dev/null; then
# i dun care if this fails
- emacsfiles="$(timeout 1 emacsclient --eval "$elisp"| sed '/^"nil"$/d;s/^"(/E: /;s/)"$//' ||:)"
+ emacsfiles="$(timeout 1 emacsclient -a /usr/bin/true --eval "$elisp" 2>/dev/null | sed '/^"nil"$/d;s/^"(/E: /;s/)"$//' ||:)"
if [[ $emacsfiles ]]; then
chars+=("$emacsfiles")
fi