学无止境html
最近在从新学习js基础,但是感受别人在讨论框架啊什么的,就以为对于js基础学习提不起劲,想起来node不就是用基础js,也算是学以至用。node
一 nvm下载git
- 先下载nvm,下载过程当中还遇到了问题,见博客nvm安装
node学习其实不须要下面这些,只是我以为学习自己就是一种好奇心的延伸,所以,出于兴趣,特意的配置了一下这些github
二 iterm2终端下载及主题配置vim
- 以为mac自带终端好丑,因此安装了iterm2,iterm下载地址
- 而后配置iterm2的主题
下载地址:http://ethanschoonover.com/solarized 下载的是压缩文件,你先解压一下,而后打开 iTerm2,按Command + ,键,打开 Preferences 配置界面,而后Profiles -> Colors -> Color Presets -> Import,选择刚才解压的solarized->iterm2-colors-solarized->Solarized Dark.itermcolors文件,导入成功,最后选择 Solarized Dark 主题,就能够了。 
- 配置oh my zsh
Oh My Zsh 是对主题的进一步扩展
3.1 一键安装
$ sh -c "$(curl -fsSL https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"
安装好以后,须要把 Zsh 设置为当前用户的默认 Shell(这样新建标签的时候才会使用 Zsh):
$ chsh -s /bin/zsh
3.2 主题
而后,咱们编辑vim ~/.zshrc
文件,将主题配置修改成ZSH_THEME="agnoster"。
agnoster是比较经常使用的 zsh 主题之一,你能够挑选你喜欢的主题,zsh 主题列表:https://github.com/robbyrussell/oh-my-zsh/wiki/themes
3.3 高亮和自动插件
- 下载高亮插件
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting
- 自动补全插件
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting
这只是安装好了,还须要在zsh的配置里面加上
执行vi ~/.zshrc
,而后找到plugins=(git),基本上在最后一页了,修改成plugins=(git zsh-syntax-highlighting zsh-autosuggestions),就能够了
有时候由于自动填充的颜色和背景颜色很类似,以致于自动填充没有效果,咱们能够手动更改下自动填充的颜色配置,我修改的颜色值为:6666ff 
- 配置meslo字体
使用上面的主题,须要 Meslo 字体支持,要否则会出现乱码的状况,字体下载地址:https://github.com/powerline/fonts/blob/master/Meslo%20Slashed/Meslo%20LG%20M%20Regular%20for%20Powerline.ttf
下载好以后,直接在 Mac OS 中安装便可。 而后打开 iTerm2,按Command + ,键,打开 Preferences 配置界面,而后Profiles -> Text -> Font -> Chanage Font,选择 Meslo LG M Regular for Powerline 字体。 
另外,VS Code 的终端字体,也须要进行配置,打开 VS Code,按Command + ,键,打开用户配置,搜索fontFamily,而后将右边的配置增长"terminal.integrated.fontFamily": "Meslo LG M for Powerline",示例: 
- 左右键跳转
主要是按住option + → or ←
键,在命令的开始和结尾跳转切换,本来是不生效的,须要手动开启下。
打开 iTerm2,按Command +
,键,打开 Preferences 配置界面,而后Profiles → Keys → Load Preset... → Natural Text Editing
,就能够了。

- iterm的快速隐藏显示
这个功能也很是使用,就是经过快捷键,能够快速的隐藏和打开 iTerm2,示例配置(option + space):

参考资料:框架