Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/linux/24.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/shell/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
获取linux shell中的所有别名_Linux_Shell_Command Line - Fatal编程技术网

获取linux shell中的所有别名

获取linux shell中的所有别名,linux,shell,command-line,Linux,Shell,Command Line,如何列出shell中定义的所有别名。 与下面的命令类似,列出目录中的所有文件/文件夹 我在~/.bashrc中定义了一些别名,我想列出所有这些 命令 只需在终端中键入别名? 这将为您提供所有活动别名 例如: $alias alias ..='cd ..' alias ...='cd ../..' alias ga='git add' alias gc='git commit' alias gitlg='git log --graph --pretty=format:'\''%Cred%h%Cre

如何列出shell中定义的所有别名。 与下面的命令类似,列出目录中的所有文件/文件夹 我在~/.bashrc中定义了一些别名,我想列出所有这些

命令
只需在终端中键入
别名
? 这将为您提供所有活动别名

例如:

$alias
alias ..='cd ..'
alias ...='cd ../..'
alias ga='git add'
alias gc='git commit'
alias gitlg='git log --graph --pretty=format:'\''%Cred%h%Creset -
%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset'\'' --abbrev-
commit'
alias gs='git st'
alias ll='ls -l'
alias ls='ls -F --color=auto --show-control-chars'
$alias
别名..='cd..'
别名…='cd../.'
别名ga='git add'
别名gc='git commit'
别名gitlg='git log--graph--pretty=format:'\''%Cred%h%Creset-
%C(黄色)%d%新月形%s%C绿色(%cr)%C(粗体蓝色)%新月形'\''--缩写-
承诺
别名gs='git st'
别名ll='ls-l'
别名ls='ls-F--color=auto--show control chars'

您是否想知道是否已经为特定命令设置了UNIX别名

您可以通过在命令行中发出以下命令轻松找到它:

命令 此命令将列出当前为您的shell帐户设置的所有别名。

可能重复的别名
$alias
alias ..='cd ..'
alias ...='cd ../..'
alias ga='git add'
alias gc='git commit'
alias gitlg='git log --graph --pretty=format:'\''%Cred%h%Creset -
%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset'\'' --abbrev-
commit'
alias gs='git st'
alias ll='ls -l'
alias ls='ls -F --color=auto --show-control-chars'
alias