我想在shell脚本中掌握当前目录的父目录的父目录的基本名称。
例如:
$ pwd /home/tmp/terminal/env/1239754/control/state $
我想要这个- 1239754。
1239754
linux bash shell
bash ×1
linux ×1
shell ×1