dot

packages and services management
Log | Files | Refs | README

commit 088004a2a44be880ac63f7f90d0276a89470adf1
parent e65c848fb4c878f915ff47eab9a2874ad6d11382
Author: josuah <mail@josuah.net>
Date:   Sat, 10 Sep 2016 11:53:04 +0200

Cleanup, cleanup...

Diffstat:
MREADME | 27---------------------------
Mbin/buffers | 2+-
Minstall.sh | 65+++++++++++++++++++++++++++++------------------------------------
Mvim/.vimrc | 3+--
Dzathura/buil.sh | 13-------------
5 files changed, 31 insertions(+), 79 deletions(-)

diff --git a/README b/README @@ -19,32 +19,6 @@ INSTALL plugins (-v) by running the 'install.sh' script. -TOOLS I USE --------------------------------------------------------------------------------- - - cgo gopher client http://github.com/kieselsteini/cgo - dmenu program launcher http://tools.suckless.org/dmenu - dwm window manager http://dwm.suckless.org - mplayer media player http://mplayer.org - mutt mail client http://www.mutt.org - rirc irc client http://github.com/rcr/rirc - st terminal http://st.suckless.org - smu markup converter http://github.com/Gottox/smu - vis editor http://github.com/martanne/vis - dvtm multiplexer http://brain-dump.org/projects/dvtm - abduco attach/detach http://brain-dump.org/projects/abduco - cmus music player http://cmus.github.io - - And before: - - tmux multiplexer http://tmux.github.io - dtach attach/detach http://brain-dump.org/projects/abduco - ctags universal ctags http://ctags.io - - I am shell agnostic, as all variables, aliases and functions - are in .profile - - SHELL SCRIPTS ------------------------------------------------------------------------------- @@ -80,7 +54,6 @@ VIM PLUGINS gitgutter https://github.com/airblade/vim-gitgutter - PROJECTS -------------------------------------------------------------------------------- diff --git a/bin/buffers b/bin/buffers @@ -90,7 +90,7 @@ a | attach ) printf '\033[1A' # get the session name by prompting the user - name="$(abduco | sed 1d | sort -t "$TAB" -k 3 | tr '!' '/' | fzy | tr '/' '!')" + name="$(abduco | sed 1d | sort -k 4 | tr ! / | fzy | tr / !)" name="${name##*$TAB}" printf '%s\n' "$name" diff --git a/install.sh b/install.sh @@ -1,10 +1,19 @@ #!/bin/sh pwd="$(cd "$(dirname "$0")" && pwd)" -Sync="$HOME/Sync" -vim_bundle="$HOME/.vim/bundle" -mail='mail@josuah.net' -host='mail.gandi.net' + +help=" +SYNTAX + ~${pwd#$HOME}/install.sh OPTION + +OPTIONS + -g Clone git repositories as listed in the README file. + -m Prompt for e-mail password to save in a unsafe text file. + -l Link the dotfiles from subdirectories of: $pwd. + -s Link the sub-sub-directories of: ~/Sync. + -v Install asyncronously the vim plugins. + -c Activates the crontab. +" NL=' ' @@ -20,22 +29,19 @@ case "$1" in done ;; -m) + mail='mail@josuah.net' + host='mail.gandi.net' + mkdir -p "$HOME/Mail" "$HOME/.cache/mail" - printf 'password: '; read password - printf 'machine %s\nlogin %s\npassword "%s"' \ - "$host" "$mail" "$password" \ - > "$HOME/.netrc" + read -p 'password: ' pass + printf 'machine %s\nlogin %s\npassword "%s"' "$host" "$mail" "$pass" \ + > "$HOME/.netrc" chmod 750 "$HOME/.netrc" ;; -s) - find "$Sync" -maxdepth 1 -path "$Sync/[A-Z][a-z]*" | while read path - do mkdir -p "$HOME/${path#$Sync/}" - done + Sync="$HOME/Sync" - find "$Sync" -mindepth 2 -maxdepth 2 -path "$Sync/[A-Z][a-z]*" \ - | while read path - do ln -sf "$path" "$HOME/${path#$Sync/}" - done + find "$Sync" -maxdepth 1 -type d -path "$Sync/*" -exec ln -sf {} ~ \; ;; -l) find "$pwd" -path "$pwd/[^.]*/.*" | while read path @@ -47,37 +53,24 @@ case "$1" in done ;; -v ) - b="$HOME/.vim/bundle" + b=~/.vim/bundle - [ -d "$b" ] && rm -r "$b" "$HOME/.vim/autoload/pathogen.vim" - mkdir -p "$b" "$HOME/.vim/autoload" - wget -qO "$HOME/.vim/autoload/pathogen.vim" https://tpo.pe/pathogen.vim + [ -d "$b" ] && rm -r "$b" ~/.vim/autoload/pathogen.vim + mkdir -p "$b" ~/.vim/autoload + wget -qO ~/.vim/autoload/pathogen.vim https://tpo.pe/pathogen.vim - IFS="$NL" - for p in $(sed '/^[ \t-]*$/ d - 1,/^VIM PLUGINS$/ d; /^PROJECTS$/,$ d' "$pwd/README") + sed '/^[ \t-]*$/ d; 1,/^VIM$/ d; /^PROJECTS$/,$ d' "$pwd/README" \ + | while read p do wget -qO- "${p##* }/archive/master.tar.gz" | tar -xvz -f- -C "$b" & done - unset IFS wait ;; -c ) - c="$HOME/.config/cron/tab" + c=~/.config/cron/tab crontab "$c" crontab -l ;; -* ) printf '%s\n' " -SYNTAX - $pwd/install.sh [ OPTION ] - -OPTIONS - -g Clone git repositories as listed in the README file. - -m Prompt for e-mail password to save in a unsafe text file. - -l Link the dotfiles from subdirectories of: $pwd. - -s Link the sub-sub-directories of: $Sync. - -v Install asyncronously the vim plugins. - -c Activates the crontab. -" ;; +* ) printf '%s\n' "$help" ;; esac diff --git a/vim/.vimrc b/vim/.vimrc @@ -83,8 +83,7 @@ highlight VertSplit cterm=none autocmd VimEnter * :silent !mkdir -p ~/.cache/vim/ autocmd VimEnter * :match ErrorMsg /\%81v.\+/ -autocmd WinNew * :match ErrorMsg /\%81v.\+/ -autocmd WinNew * :match ErrorMsg /\%81v.\+/ +autocmd WinEnter * :match ErrorMsg /\%81v.\+/ " PLUGINS diff --git a/zathura/buil.sh b/zathura/buil.sh @@ -1,13 +0,0 @@ -# Document viewer with minimal interface - -tar=https://pwmt.org/projects/zathura/download/zathura-0.3.6.tar.gz - -build() -{ - make \ - PREFIX="$PREFIX" \ - GIRARA_LIB="$PREFIX/lib" \ - GIRARA_INC="$PREFIX/include" \ - install - -}