My Bash and Vim config files. Maybe someone will find'em handy :)
##.bashrc open the file and just a have a look at all the aliases
##.vimrc
F2 - toggle paste mode that will keep the indentation intact
F4 - toggle diff of currently opened buffers/splits
F5 - remove all trailing whitespaces
F6 - toggle 80 chars vertical line
F7 - toggle line numbering
F8 - toggle tag lists (require cTags)
F10 - toggle hex view
F12 - toggle visual whitespaces
C-t up/down/left/right - navigate between tabs
C-[hjkl] - navigate between splits/buffers
S - yank a text then use S to replace a word and paster many times
##.inputrc contains a nice bash setting that allows you to search through your history using the up and down arrows. i.e. type "cd /" and press the up arrow and you'll search through everything in your history that starts with "cd /". Thaks to Jude Robinson @ https://coderwall.com/p/oqtj8w
Clone repo:
git clone https://github.com/kowalcj0/bash-that-vim.git
Initialize all the submodules:
git submodule init
git submodule update
# or in case you had an older version of this repo
git submodule foreach git pull --rebase origin master
# do not use
git submodule update --init
git pull --recurse-submodules
Create a backup copy of your current cfg files:
cp ~/.bashrc ~/.bashrc.bak
cp ~/.vimrc ~/.vimrc.bak
cp ~/.inputrc ~/.inputrc.bak
Delete your old cfg files:
rm ~/.bashrc
rm ~/.vimrc
rm ~/.inputrc
rm ~/.profile
rm ~/.iftoprc
rm ~/.gitignore
Create new absolute symlinks for all dot files and .vim folder:
ln -sf ~/git/dotfiles/.bashrc ~/.bashrc
ln -sf ~/git/dotfiles/.vimrc ~/.vimrc
ln -sf ~/git/dotfiles/.inputrc ~/.inputrc
ln -sf ~/git/dotfiles/.vim ~/.vim
ln -sf ~/git/dotfiles/.profile ~/.profile
ln -sf ~/git/dotfiles/.iftoprc ~/.iftoprc
ln -sf ~/git/dotfiles/global_gitignore ~/.gitignore
ln -sf ~/git/dotfiles/.git-prompt.sh ~/.git-prompt.sh
ln -sf ~/git/dotfiles/.git-completion.bash ~/.git-completion.bash
This answer on superuser.com to explains why you need to create those absolute symlinks :)
Load new Bash settings:
source ~/.bashrc
or simply open new bash session to enable .inputrc
Once that done you can edit your cfg files as usual:
vim ~/.bashrc
vim ~/.vimrc
or use handy aliases:
- ba for vim ~/.bashrc
- vv for vim ~/.vimrc
- F2 paste code and keep formatting
- F4 toggle diff of currently opened buffers/splits
- F5 remove all trailing whitespaces
- F6 toggle 80 chars vertical line
- F7 toggle line numbering
- F8 toggle tag lists (require cTags)
- F10 toggle hex view
- F12 toggle visual whitespaces
- press Asterisk to do a visual search
- ctrl+t+arrows move around tabs
- :Dox generate doc template
- R run python script from Vim
- play with EN spellcheker
- ,+c toggle line and column highlight
- iyw then S to replace word multiple time
- move visual block with angle brackets
- create new folder in the Dropbox folder ie.: tomboy-notes
- go to Tomboy'd preferences: Edit -> Preferences -> Synchronisation
- Choose "Local folder" from the "Service" dropdown menu
- Then point at the folder you've created in the first step
- Hit "Close" and continue working :)
-
close tasque
-
create new folder in the Dropbox folder ie.: tasque-db
-
move contents of ~/.config/tasque folder to the newly created tasque-db dir
-
delete the empty ~/.config/tasque
-
create a symlink:
ln -s /home/your_user_name/Dropbox/tasque-db tasque
-
open tasque