LoginSignup
0
0

More than 1 year has passed since last update.

エイリアスの設定方法【bash】【zsh】

Posted at

エイリアスの設定方法

alias 別名= '実際に実行するコマンド'と.zshrc.bashrc`に記述することでエイリアスが設定できます。

エイリアス設定例
alias g='git'
alias gst='git status'
alias gd='git diff'
alias gdc='git diff --cached'
alias gl='git pull'
alias gup='git pull --rebase'
alias gp='git push'
alias gd='git diff'

alias d=‘docker’
alias dc=‘docker-compose’
alias dcnt=‘docker container’
alias dcur=‘docker container ls -f status=running -l -q’
alias dexec=‘docker container exec -it $(dcur)’
alias dimg=‘docker image’
alias drun=‘docker container run —rm -d’
alias drunit=‘docker container run —rm -it’
alias dstop=‘docker container stop $(dcur)’

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0