快捷键note

iterm2

bash添加颜色(utunbu配色方案)

->
Git show branch name ->
ps1 语法

#enables colorin the terminal bash shell export
export CLICOLOR=1

#sets up thecolor scheme for list export
export LSCOLORS=gxfxcxdxbxegedabagacad

#sets up theprompt color (currently a green similar to linux terminal)
export PS1="\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;36m\]\W\[\033[01;33m\]\$(parse_git_branch)\[\033[00m\]\$ "

#enables colorfor iTerm
export TERM=xterm-color

alias

alias
alias ll='ls -alF'
alias la='ls -A'
alias l='ls -CF'

Bash git 自动补全

brew install bash-completion
cd /usr/local/opt/bash-completion/etc/bash_completion.d
curl -L -O https://raw.github.com/git/git/master/contrib/completion/git-completion.bash
brew unlink bash-completion
brew link bash-completion

常用命令

tail -f -n 5 xxx.log  #显示最后5行
tailf -n xxx.log

tail

快捷键

ctrl+u 剪切文本直到行的起始(可以用于清空行)
ctrl+k 剪切文本直到行的末尾
ctrl+y 粘贴最近剪切的文本
ctrl+e 跳到行首
ctrl+a 调到行尾 (cmd + -> 也行,开启了profile-keys-key mappings-natrual text editing)
ctrl+L 清空屏幕(功能相当于命令clear)

Vscode

快捷键

shift+opt+鼠标:选择列并同时编辑
shift+cmd+p :显示所有命令
直接把文件夹拖到目录栏,可以加入工作区

Goland

  1. git展示local changes
    Preference --> version control --> commit --> 取消勾选第一个 --> 展示git log
  2. opt+cmd+L :format 当前文件

Vim

配置

修改~/.vimrc

#set encoding=utf-8  " The encoding displayed. 
#set fileencoding=utf-8  " The encoding written to file. 
set nu 
syntax on #语法高亮
set mouse=a #用来开启鼠标功能的。a表示所有模式
set ts=4  #tab 4个字符
set expandtab

搜索

/ 搜索

插入

I 行首插入
A 行尾插入
o 上面插入一行
O 下面插入一行

移动

h j k l 左下上右
w b 向前向后一个单词
ctrl+e ctrl+y 向下向上滚动一行
ctrl+f ctrl+b 向下向上滚动一屏
0 $ 行首行尾
:30 到第30行

撤销

u 撤销上一步

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值