Skip to content

acherub/dotfiles

Repository files navigation

acherub's dotfiles

Installation

You can clone the repository and run the script to install:

source install.sh

The installation is to copy dotfiles from the project folder, say ~/Projects/dotfiles, to ~

VIM

Vim plugins

  • vim-gitgutter
    • The highlight for sign column was disabled for vim-airline
  • nerdtree
    • <F5> to toggle nerdtree
  • unimpaired
    • Document
    • yol: toggle list
    • yon: toggle number
    • yoh: toggle hlsearch
    • [ / ] to open / close settings
    • b: buffer switch
    • B: buffer first/last
    • q: quickfix switch
    • Q: quickfix first/last
    • <space>: to add new line before/after current line
    • e: bubble line up/down
  • vim-airline
    • The theme is also set to solarized
  • vim-surround
    • cs + marker1 + marker2: change marker1 as marker2 (ex: cs"')
    • ds + marker: delete marker (ex: ds")
    • ys: add surround
  • tagbar
    • <F7>: Toggle TagBar
  • taglist
    • depends on ctags
    • <F11>: Toggle Tlist
  • nerdcommenter
    • <leader> is set to ,
    • , + cl: comment current line. We can add count before the command. (, + cb is preferred for block)
    • , + cu: Uncomment the selected lines
    • , + ca: Change the style of comment. (From /* */ to // in c/cpp)
  • nerdtree
  • vim-easymotion
    • g:EasyMotion_leader_key is set to ,
    • , + s
    • , + w
    • , + b
    • , + f
  • vim-repeat
  • matchit
  • vim-colorschemes
    • Set the colortheme as solarized in vimrc
    • For windows, solorzied is not used.
  • vim-latex
  • ctrlp
    • , + p: Open the ctrl p window, current directory and sub-directories
    • , + m: Open the ctrl p window, with recently modified files
  • leaderf
    • , + ff: Open the leaderf window
  • vim-gutentags
    • Generate tags automatically when the root folder (with .croot) is found
    • ctags is required

VIM Theme - Solarized

Here are some notes about setting terminal color in windows

Windows Support

Download the ansi_blows. color scheme

Pietty

  1. Download the color settings from official website
  2. Unzip it and enter putty-colors-solarized directory, copy the color settings.
  3. Edit PieTTY.ini and add the color settings to the session that you want.
  4. Check the setting Terminal-type string in Connection -> Data should be xterm-256color
  5. Check the setting Allow terminal to use xterm 256-colour mode in Window -> Colours is enabled

Bash/dircolors

Download the dircolors for solarized in dircolors-solarized. I use dircolors.256dark and it works fine. In the install script, the file will be copied as ~/.dircolors and there's an command in .alias to apply the setting

test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"

Git Gutter

The highlight for sign column was disabled for vim-airline

highlight clear SignColumn

Customized VIM commands

Function keys

  • <F5>: Toggle NERDTree (on Left)
  • <F6>: Not using
  • <F7>: Toggle TagBar
  • <F8>: Trinity Toggle All
  • <F9>: Trinity Toggle ScrExpl
  • <F10>: Trinity Toggle TagList
  • <F11>: Trinity Toggle NerdTree (onRight)

Commands with Leader keys

  • , + r: Replace the current word in all opened buffers
  • , + v: Reload
  • , + ss: Strip trailing whitespace

Normal Mode Shortcuts

  • ;;: Mapping ;; to <ESC> in normal mode

Mac

Oh-my-zsh

Oh-my-zsh changes the style of editing. Please install it right after you get a new computer. Here's couple of plugins used here:

  • Theme: powerlevel10k
  • Plugins: zsh-completions zsh-autosuggestions zsh-syntax-highlighting

fzf is also one of the must use plugin to enhance the performance.

About

acherub's dotfiles

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published