交流点有用的 shell alias

2014 年 12 月 26 日
 alexapollo

我先来:
pin='pip install -i http://pypi.douban.com/simple'
cd..='cd ..'
cd...='cd ../..'
cd....='cd ../../..'
cd.....='cd ../../../..'
gp='git push'
gup='git pull --rebase'
f='find . | grep --color'
g='find . | xargs grep --color -n'
m='make -j 8'

4348 次点击
所在节点    程序员
20 条回复
rick09
2014 年 12 月 26 日
怎么可以少了 rm='rm -i'
Tink
2014 年 12 月 26 日
rm = rm -rf /
ChiangDi
2014 年 12 月 26 日
alias ... "cd ../../"
alias .... "cd ../../../"
alias ..... "cd ../../../../"
alias rm "rm -i"
alias cp "cp -i"
alias mv "mv -i"
alias s "subl"
alias mux "tmuxinator"
alias sl "ls"

# git alias
alias g "git"
alias ga "git add"
alias gc "git commit -v"
alias gc! "git commit -v --amend"
alias gp "git push"
alias gcm "git checkout master"
alias gst "git status"
LazyZhu
2014 年 12 月 26 日
cd 为啥还是两个点?
推荐bash的pushd/popd,切换目录更方便
viator42
2014 年 12 月 26 日
ll = ls -al
没有这个简直没法过.
xzl380
2014 年 12 月 26 日
ffffwh
2014 年 12 月 26 日
alias emcas=emacs
alias eamcs=emacs
。。。
vibbow
2014 年 12 月 26 日
alias cls=clear
vibbow
2014 年 12 月 26 日
alias dir=ls -alt
XiaoxiaoPu
2014 年 12 月 26 日
alias r='echo -ne "\033c"'
bingdian
2014 年 12 月 26 日
alias server="open http://localhost:8000 && python -m SimpleHTTPServer "

顺便再分享个 http://dotfiles.github.io/
iptux
2014 年 12 月 26 日
razrlele
2014 年 12 月 26 日
alias emacs="vim"
veapon
2014 年 12 月 26 日
veapon
2014 年 12 月 26 日
saber000
2014 年 12 月 27 日
alias clr='printf "\ec"'
47jm9ozp
2014 年 12 月 27 日
.gitconfig里面

[alias]
lg = log --all --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --
R4rvZ6agNVWr56V0
2014 年 12 月 27 日
alias site="curl -s -o /dev/null -w '%{http_code}'"
zhujinliang
2014 年 12 月 27 日
gohere="export GOPATH=`pwd`"
reverland
2014 年 12 月 27 日
~  type rot13
rot13 is an alias for tr '[A-Za-z]' '[N-ZA-Mn-za-m]'


~  type rot13r
rot13r is an alias for tr '[N-ZA-Mn-za-m]' '[A-Za-z]'

这是一个专为移动设备优化的页面(即为了让你能够在 Google 搜索结果里秒开这个页面),如果你希望参与 V2EX 社区的讨论,你可以继续到 V2EX 上打开本讨论主题的完整版本。

https://www.v2ex.com/t/157003

V2EX 是创意工作者们的社区,是一个分享自己正在做的有趣事物、交流想法,可以遇见新朋友甚至新机会的地方。

V2EX is a community of developers, designers and creative people.

© 2021 V2EX