Home

Guten Ye edited this page Mar 5, 2015 · 6 revisions

Development Documentation

Getting Started

Syntax Highlight in vim

Edit ~/.vim/filetype.vim

au! BufNewFile,BufRead ~/.zsh/completion/*   setfiletype zsh
au! BufNewFile,BufRead ~/.zsh/Pluginfile     setfiletype zsh

How it Works

ZCM Layout

~/.zshrc
~/.zsh/
    Pluginfile         # enable/disable plugin here
    foo.zsh            # a foo plugin
    foo.profile.zsh    # load by ~/.zprofile

    themes/            # theme files
    keymaps/           # keymap files

    completion/        # all completions file are putted here. e.g. _foo
    bin/               # user made scripts

the ~/.zsh/Pluginfile file

theme default.rbenv.ssh.git
keymap vim

plugin git
plugin ruby

Create a Theme

In ~/.zshrc

# PS1 is something like this '$cwd $git_info$git_status %(!.$root.$normal)'

themerc=(
  cwd      "$fg[cyan]"
    git_info "$fg[blue]"
  root     "$fg_bold[red]"
  normal   "$fg_bold[green]"
  eos      "$reset_color"
)

helperrc=(
    git_added     " ✚"
    git_modified  " ✹"
    git_deleted   " ✖"
    git_renamed   " ➜"
    git_unmerged  " ═"
    git_untracked " ✭"
)

themerc defines color. helperrc defines prompt string.