diff options
author | Karel Kočí <karel.koci@nic.cz> | 2020-10-08 07:55:40 +0200 |
---|---|---|
committer | Karel Kočí <karel.koci@nic.cz> | 2020-10-08 07:55:40 +0200 |
commit | ce284a3dae12e78aa69c88ab4fef3dfd19b0fb0d (patch) | |
tree | 127260500d075ed6189c38564fca947c255bd4cd | |
parent | 6c87803ec2c5338f9246c8689f3aded284417604 (diff) | |
download | myconfigs-ce284a3dae12e78aa69c88ab4fef3dfd19b0fb0d.tar.gz myconfigs-ce284a3dae12e78aa69c88ab4fef3dfd19b0fb0d.tar.bz2 myconfigs-ce284a3dae12e78aa69c88ab4fef3dfd19b0fb0d.zip |
Refresh local scripts
-rwxr-xr-x | install | 2 | ||||
-rwxr-xr-x | local/bin/allsync | 18 | ||||
-rwxr-xr-x | local/bin/project-test | 2 | ||||
-rwxr-xr-x | local/bin/vim-project-gen | 4 | ||||
-rwxr-xr-x | local/bin/wake-desktop | 2 |
5 files changed, 11 insertions, 17 deletions
@@ -23,6 +23,7 @@ if ask "git" "Install GIT configuration"; then inst gitconfig ~/.gitconfig inst gitignore ~/.gitignore git config --global core.excludesfile ~/.gitignore + inst local/bin/cznic-git-config ~/.local/bin/cznic-git-config fi if ask "gpg" "Install GPG configuration"; then @@ -40,7 +41,6 @@ fi if ask "vim" "Install VIM scripts"; then inst vimrc ~/.vimrc inst vim/ ~/.vim - inst local/bin/vim-project-gen ~/.local/bin/vim-project-gen mkdir -p ~/.cache/vim # directory for *.swp files mkdir -p ~/.cache/vim-undo # directory for undo files # Vim plugin manager diff --git a/local/bin/allsync b/local/bin/allsync index b475460..3943ab4 100755 --- a/local/bin/allsync +++ b/local/bin/allsync @@ -1,20 +1,18 @@ #!/bin/sh +set -eu sec() { echo -e '\e[1;34m==========' "$@" '==========\e[0m' } - -run() { - sec "Mail" - mbsync -a - ~/.local/sbin/newmail-notify - - sec "Calendar and contacts" - vdirsyncer sync +fail() { + echo -e '\e[1;31m---' "$@" '---' "($?)" '\e[0m' } +sec "Mail" +mbsync -a +~/.local/sbin/newmail-notify || fail "Mail synchronization reported failure" - -run +sec "Calendar and contacts" +vdirsyncer sync || "Calendar and contacts synchronization reported failure" diff --git a/local/bin/project-test b/local/bin/project-test index a0591d8..e8c6261 100755 --- a/local/bin/project-test +++ b/local/bin/project-test @@ -39,5 +39,5 @@ done while read -r rev; do git checkout "$rev" git submodule update - eval $@ + eval "$@" done < <(git rev-list "$REF"..HEAD) diff --git a/local/bin/vim-project-gen b/local/bin/vim-project-gen deleted file mode 100755 index 6a50ba5..0000000 --- a/local/bin/vim-project-gen +++ /dev/null @@ -1,4 +0,0 @@ -#!/bin/bash -# Generates ctags and cscope files for project. -ctags -R -f .tags -#cscope -Rbq -f .cscope.out diff --git a/local/bin/wake-desktop b/local/bin/wake-desktop index 24a3cea..b691ddd 100755 --- a/local/bin/wake-desktop +++ b/local/bin/wake-desktop @@ -1,2 +1,2 @@ #!/bin/sh -ssh turris.prg etherwake -i br-lan 70:85:c2:4a:59:f2 +exec ssh turris.prg etherwake -i br-lan 70:85:c2:4a:59:f2 |