![](/img/trans.png)
[英]Default file ending in Mac, Linux and Windows to run executable in the shell/terminal
[英]linux shell script to run an executable file in current folder
我總是在/ home / a中有一個名為toUpperCase的可執行文件。
現在,我在文件夾/ home / bla / blabla / b中 ,我有一個要轉換為大寫的文本文件( toConvert.txt )。 我要做的就是在/ home / bla / blabla / b中執行的腳本執行類似
#!/bin/bash
./"/home/a/toUpperCase" toConvert.txt
所以最后我應該在/ home / bla / blabla / b文件夾中轉換了convert.txt
但這給了我類似line 2: .//home/a/toUpperCase: does not exist
的錯誤line 2: .//home/a/toUpperCase: does not exist
我如何解決這個問題? 謝謝!
將腳本更改為:
#!/bin/bash
"/home/a/toUpperCase" toConvert.txt
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.