Skip to content

maple-leaf/dotfiles

Repository files navigation

基于oh-my-zsh的自定义设置

环境安装

  • 安装oh-my-zsh
  • 安装fzf: brew install fzf
  • [可选]安装tmux: brew install tmux
  • [可选]安装vim 或者 neovim: brew install vim/macvim/neovim
  • [可选]安装tmuxinator: gem install tmuxinator

zsh配置

tmux

  • 配置:个人基于https://github.com/tony/tmux-config进行更改
  • 安装
    • ln -s ~/dotfiles/.tmux.conf .tmux.conf
    • install TPM: git clone https://github.com/tmux-plugins/tpm ~/.tmux/plugins/tpm
    • start tmux: tmux
    • install TPM plugins: <ctrl+a>+I
  • tmux内无法使用y进行拷贝时,请检查Terminal设置, 允许Application can access clipboard。具体查看这个issue

vim/neovim

  • 配置
  • 如果你在tmux内使用neovim则需要将alias.zsh关于nvim的alias注释去掉,并安装reattch-to-user-namespace,解决剪贴板问题。
    • alias nvim="reattach-to-user-namespace -l nvim"
    • brew install reattach-to-user-namespace

本扩充配置介绍:

  • fco: fuzzy-finder方式的git分支切换

  • fcoc: fuzzy-finder方式的git commit切换

  • fadd: fuzzy-finder方式的git add, 按来添加/取消添加已修改的文件

  • ftags: fuzzy-finder方式的git tags切换

  • flo: fuzzy-finder方式的git log查看, 在具体commit按enter查看详细

  • ftags: fuzzy-finder方式的git tags切换

  • fstal: fuzzy-finder方式的git tags切换

    • enter: 查看diff
    • ctrl-d: 丢弃stash
    • ctrl-b: 选择源branch签出输入的分支名然后还原stash
  • 使用gdc替代gdca别名

  • glo: 查看格式化好的log, 格式:

    b35840e author 2016-12-05T16:51:16+08:00 the message
    file/1/of/all/changed/files
    file/2/of/all/changed/files
    ...
    
  • gloc: 仅查看当前分支相对于master分支所有新增commit格式化好的log, 格式如上

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages