switch to a directory
#查看当前所在路径
bixiaopeng@bixiaopengtekimacbook-pro ~$ pwd
/users/bixiaopeng
#使用命令: cd directory path
Bixiaopeng@bixiaopengtekimacbook-pro ~$ cd apktool
#查看切换后的路径
bixiaopeng@bixiaopengtekimacbook-pro apktool$ PWD
/users/bixiaopeng/apktool
Switch to home directory
#方法一: cd
bixiaopeng@bixiaopengtekimacbook-pro apktool$ cd
bixiaopeng@bixiaopengtekimacbook-pro ~$ pwd
/users/bixiaopeng
#方法二: cd ~
bixiaopeng@bixiaopengtekimacbook-pro ~$ CD Apktool
Bixiaopeng@bixiaopengtekimacbook-pro apktool$ CD ~
bixiaopeng@bixiaopengtekimacbook-pro ~$ pwd
/Users/ Bixiaopeng
switch to the previous level of the directory
Bixiaopeng@bixiaopengtekimacbook-pro ~$ cd apktool/framework/
Bixiaopeng@bixiaopengtekimacbook-pro framework$ PWD
/users/bixiaopeng/apktool/framework
bixiaopeng@bixiaopengtekimacbook-pro framework$ CD.
Bixiaopeng@bixiaopengtekimacbook-pro apktool$ pwd
/users/bixiaopeng/apktool
the directory before switching to the current directory
Bixiaopeng@bixiaopengtekimacbook-pro apktool$ CD-
/users/bixiaopeng/apktool/framework
Bixiaopeng@bixiaopengtekimacbook-pro framework$ pwd
/users/bixiaopeng/apktool/framework
switch to level two directory
Bixiaopeng@bixiaopengtekimacbook-pro framework$ CD. /..
Bixiaopeng@bixiaopengtekimacbook-pro ~$ pwd
/users/bixiaopeng
Use the parameters of the previous command as a parameter to the CD
Bixiaopeng@bixiaopengtekimacbook-pro ~$ CD/
bixiaopeng@bixiaopengtekimacbook-pro/$ CD!$
CD/