MACOS下使用alias命令
语法:
alias name='command line'
用法:
alias grep='grep --color'
列出所有的设置:
alias 或 alias -p
针对某个用户生效:
放到 /Users/用户/.profile 文件
针对全部用户生效:
放到 /etc/profile 文件
MAC的配置:
alias ls='ls -G'
alias ll='ls -l' #
alias la='ls -a' #mac使用la命令
alias grep='grep --color'
alias find='find --color'
alias git='git --color'
注意使用 source .profile 让配置生效
网友评论