Merge branch 'master' of github.com:Faerbit/.dotfiles
This commit is contained in:
commit
7d5e65d418
@ -6,5 +6,6 @@
|
|||||||
[core]
|
[core]
|
||||||
editor = vim -c 'startinsert'
|
editor = vim -c 'startinsert'
|
||||||
excludesfile = ~/.globalgitignore
|
excludesfile = ~/.globalgitignore
|
||||||
|
pager = less -F -X
|
||||||
[push]
|
[push]
|
||||||
default = simple
|
default = simple
|
||||||
|
@ -1 +1,2 @@
|
|||||||
*.swp
|
*.swp
|
||||||
|
*.swo
|
||||||
|
5
vimrc
5
vimrc
@ -18,6 +18,8 @@ if exists("*vundle#begin")
|
|||||||
Plugin 'garbas/vim-snipmate'
|
Plugin 'garbas/vim-snipmate'
|
||||||
Plugin 'honza/vim-snippets'
|
Plugin 'honza/vim-snippets'
|
||||||
Plugin 'alfredodeza/coveragepy.vim'
|
Plugin 'alfredodeza/coveragepy.vim'
|
||||||
|
Plugin 'tikhomirov/vim-glsl'
|
||||||
|
Plugin 'ntpeters/vim-better-whitespace'
|
||||||
|
|
||||||
" All of your Plugins must be added before the following line
|
" All of your Plugins must be added before the following line
|
||||||
call vundle#end() " required
|
call vundle#end() " required
|
||||||
@ -59,6 +61,9 @@ if argc() == 2
|
|||||||
endif
|
endif
|
||||||
|
|
||||||
"Map <F8> on python files
|
"Map <F8> on python files
|
||||||
|
au FileType python :map <F8> i <F8>
|
||||||
|
au FileType python :imap <F8> import pdb; pdb.set_trace()<ESC>
|
||||||
|
"Map <F10> on python files
|
||||||
au FileType python :map <F10> :Coveragepy show<cr>
|
au FileType python :map <F10> :Coveragepy show<cr>
|
||||||
au FileType python :imap <F10> <Esc><F10>
|
au FileType python :imap <F10> <Esc><F10>
|
||||||
|
|
||||||
|
@ -1,3 +1,14 @@
|
|||||||
|
sysupgrade(){
|
||||||
|
old_kernel=$(pacman -Q linux-raspberrypi | awk '{print $2 }')
|
||||||
|
sudo pacmatic -Syu
|
||||||
|
new_kernel=$(pacman -Q linux-raspberrypi | awk '{print $2 }')
|
||||||
|
if [[ $old_kernel != $new_kernel ]]
|
||||||
|
then
|
||||||
|
sudo mkinitcpio -k "$new_kernel-ARCH" -g /boot/initrd
|
||||||
|
fi
|
||||||
|
cower -u
|
||||||
|
}
|
||||||
|
|
||||||
copy_img_to_usb(){
|
copy_img_to_usb(){
|
||||||
if [[ $1 = "" ]]
|
if [[ $1 = "" ]]
|
||||||
then
|
then
|
||||||
@ -64,3 +75,7 @@ pacman_disowned(){
|
|||||||
|
|
||||||
comm -23 "$fs" "$db"
|
comm -23 "$fs" "$db"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
virtual_env_prompt() {
|
||||||
|
REPLY=${VIRTUAL_ENV+(${VIRTUAL_ENV:t}) }
|
||||||
|
}
|
||||||
|
51
zshrc
51
zshrc
@ -1,8 +1,26 @@
|
|||||||
|
# source all other zsh files
|
||||||
|
if [ -f .zsh_environment ]
|
||||||
|
then
|
||||||
|
source ~/.zsh_environment
|
||||||
|
fi
|
||||||
|
#for accounts whithout root
|
||||||
|
if [ -f .zsh_grml ]
|
||||||
|
then
|
||||||
|
source ~/.zsh_grml
|
||||||
|
fi
|
||||||
|
#for untrusted machines
|
||||||
|
if [ -f .zsh_sensitive ]
|
||||||
|
then
|
||||||
|
source ~/.zsh_sensitive
|
||||||
|
fi
|
||||||
|
source ~/.zsh_functions
|
||||||
|
export EDITOR=vim
|
||||||
|
|
||||||
alias sudo='sudo '
|
alias sudo='sudo '
|
||||||
alias tasks="ps -u fab"
|
alias tasks="ps -u fab"
|
||||||
alias update-grub="grub-mkconfig -o /boot/grub/grub.cfg"
|
alias update-grub="grub-mkconfig -o /boot/grub/grub.cfg"
|
||||||
alias sml2p='/home/fab/.Sync-my-L2P/Sync-my-L2P.run'
|
alias sml2p='/home/fab/.Sync-my-L2P/Sync-my-L2P.run'
|
||||||
alias update-mirrors='sh -c "reflector -p http -l 20 --sort rate | tee /etc/pacman.d/mirrorlist"'
|
alias update-mirrors='sh -c "reflector -p http -l 50 --sort rate | tee /etc/pacman.d/mirrorlist"'
|
||||||
alias ssh='ssh '
|
alias ssh='ssh '
|
||||||
alias ping='ping '
|
alias ping='ping '
|
||||||
alias aur-update='pacaur -Syu --devel --noconfirm'
|
alias aur-update='pacaur -Syu --devel --noconfirm'
|
||||||
@ -23,6 +41,8 @@ alias gad='git add'
|
|||||||
alias gcm='git commit'
|
alias gcm='git commit'
|
||||||
alias resource='source ~/.zshrc'
|
alias resource='source ~/.zshrc'
|
||||||
alias battery='upower -i /org/freedesktop/UPower/devices/battery_BAT0 | grep "time to empty"'
|
alias battery='upower -i /org/freedesktop/UPower/devices/battery_BAT0 | grep "time to empty"'
|
||||||
|
alias poweroff='sudo poweroff'
|
||||||
|
alias reboot='sudo reboot'
|
||||||
if [ -f .zsh_environment ]
|
if [ -f .zsh_environment ]
|
||||||
then
|
then
|
||||||
source ~/.zsh_environment
|
source ~/.zsh_environment
|
||||||
@ -40,15 +60,42 @@ fi
|
|||||||
source ~/.zsh_functions
|
source ~/.zsh_functions
|
||||||
export EDITOR=vim
|
export EDITOR=vim
|
||||||
export PATH=$PATH:/home/fab/bin:/home/fab/.gem/ruby/2.1.0/bin
|
export PATH=$PATH:/home/fab/bin:/home/fab/.gem/ruby/2.1.0/bin
|
||||||
|
alias emacs='emacs -nw'
|
||||||
|
alias aiawiki='ssh aia -L 80:ldap2:80'
|
||||||
|
alias rbtv='livestreamer twitch.tv/rocketbeanstv &'
|
||||||
|
alias taketv='livestreamer twitch.tv/taketv &'
|
||||||
|
alias ls='ls --color=auto'
|
||||||
export ASPROOT=~/.asp
|
export ASPROOT=~/.asp
|
||||||
|
export PATH=$PATH:/home/fab/bin:/home/fab/.gem/ruby/2.2.0/bin
|
||||||
|
export LFS=/mnt/lfs
|
||||||
|
|
||||||
#vi mode
|
#vi mode
|
||||||
bindkey -v
|
bindkey -v
|
||||||
export KEYTIMEOUT=1
|
export KEYTIMEOUT=1
|
||||||
|
bindkey -M viins 'fd' vi-cmd-mode
|
||||||
bindkey -M vicmd 'k' history-beginning-search-backward
|
bindkey -M vicmd 'k' history-beginning-search-backward
|
||||||
bindkey -M vicmd 'j' history-beginning-search-forward
|
bindkey -M vicmd 'j' history-beginning-search-forward
|
||||||
|
|
||||||
#backspace working after returning from command mode
|
#backspace working after returning from command mode
|
||||||
bindkey '^?' backward-delete-char
|
bindkey '^?' backward-delete-char
|
||||||
bindkey '^h' backward-delete-char
|
bindkey '^h' backward-delete-char
|
||||||
|
|
||||||
|
if [ -f /usr/share/doc/pkgfile/command-not-found.zsh ]
|
||||||
|
then
|
||||||
|
source /usr/share/doc/pkgfile/command-not-found.zsh
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -f /usr/bin/virtualenvwrapper_lazy.sh ]
|
||||||
|
then
|
||||||
|
# Automatically source virtualenv
|
||||||
|
source /usr/bin/virtualenvwrapper_lazy.sh
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -f /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh ]
|
||||||
|
then
|
||||||
|
source /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
|
||||||
|
fi
|
||||||
|
|
||||||
|
# displaying current virtual env
|
||||||
|
grml_theme_add_token virtual-env -f virtual_env_prompt '%F{magenta}' '%f'
|
||||||
|
zstyle ':prompt:grml:left:setup' items rc virtual-env change-root user at host path vcs percent
|
||||||
|
Loading…
Reference in New Issue
Block a user