官术网_书友最值得收藏!

The cd command

Where pwd or $PWD gets the current working directory for the shell, the cd Bash builtin command sets the working directory:

$ pwd
/home/bashuser
$ cd /tmp
$ pwd
/tmp

When issued with no arguments, the cd command defaults to the current user's home directory. Again, it does this by reading the $HOME environment variable first, if it can:

$ cd
$ pwd
/home/bashuser

You can change to the parent of the current directory with the .. name:

$ pwd
/home/bashuser
$ cd ..
$ pwd
/home
主站蜘蛛池模板: 北海市| 汤阴县| 蕲春县| 正定县| 张家港市| 长海县| 辛集市| 黑水县| 永兴县| 玉溪市| 高邮市| 玛沁县| 南澳县| 新闻| 泸州市| 霍林郭勒市| 滦南县| 景东| 新丰县| 巴南区| 襄汾县| 开平市| 凯里市| 手游| 瑞昌市| 台北市| 抚松县| 调兵山市| 平度市| 铜梁县| 永宁县| 子长县| 贵定县| 富宁县| 汶川县| 玉林市| 临桂县| 桂平市| 新余市| 广西| 澄江县|