mirror of
https://github.com/altercation/solarized
synced 2024-11-24 20:53:03 +00:00
29 lines
1.1 KiB
Bash
29 lines
1.1 KiB
Bash
#!/bin/bash
|
|
|
|
cd $ROOT_DIR
|
|
DOT_FILES="lastpass weechat ssh Xauthority"
|
|
for dotfile in $DOT_FILES; do conform_link "$DATA_DIR/$dotfile" ".$dotfile"; done
|
|
|
|
# }}}
|
|
# crontab update from file {{{
|
|
# TODO: refactor with suffix variables (or common cron values)
|
|
|
|
case "$PLATFORM" in
|
|
linux)
|
|
#conform_link "$CONF_DIR/shell/zshenv" ".zshenv"
|
|
crontab -l > $ROOT_DIR/tmp/crontab-conflict-arch
|
|
cd $ROOT_DIR/$CONF_DIR/cron
|
|
if [[ "$(diff ~/tmp/crontab-conflict-arch crontab-current-arch)" == ""
|
|
]];
|
|
then # no difference with current backup
|
|
logger "$LOG_PREFIX: crontab live settings match stored "\
|
|
"settings; no restore required"
|
|
rm ~/tmp/crontab-conflict-arch
|
|
else # current crontab settings in file do not match live settings
|
|
crontab $ROOT_DIR/$CONF_DIR/cron/crontab-current-arch
|
|
logger "$LOG_PREFIX: crontab stored settings conflict with "\
|
|
"live settings; stored settings restored. "\
|
|
"Previous settings recorded in ~/tmp/crontab-conflict-arch."
|
|
fi
|
|
;;
|
|
|