I'm trying to write a small script to change the current directory to my project directory:
(我正在尝试编写一个小脚本以将当前目录更改为我的项目目录:)
#!/bin/bash
cd /home/tree/projects/java
I saved this file as proj, added execute permission with chmod
, and copied it to /usr/bin
.
(我将此文件另存为proj,并使用chmod
添加了执行权限,然后将其复制到/usr/bin
。)
When I call it by: proj
, it does nothing. (当我通过以下方式调用它时: proj
,它什么都不做。)
What am I doing wrong? (我究竟做错了什么?)
ask by ashokgelal translate from so 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…