我在 bash 文件中有一个 if 语句:
if [ -f bin/post_compile ]; then
echo "-----> Running post-compile hook"
chmod +x bin/post_compile
sub-env bin/post_compile
fi
Run Code Online (Sandbox Code Playgroud)
是什么-f意思?
如果该文件存在并且是常规文件。
http://www.tldp.org/LDP/Bash-Beginners-Guide/html/sect_07_01.html
你的英文陈述:
如果文件“/bin/post_compile”存在并且是常规文件,则:
sub-env万一 (fi)