簡體   English   中英

從命令行運行特定的Perl腳本

[英]run specific perl script from command line

沒有那么多編程經驗,但是我看到了每個人都在談論的那些快速讀者之一的開源代碼,並認為嘗試在自己的計算機上運行它是很酷的。

這些文件位於此處: https : //github.com/pasky/speedread

我想知道我應該在命令提示符下鍵入什么才能使程序運行。 我的計算機上已經有一個perl解釋器。 但是我不確定如何使程序運行。 抱歉,這是一個超級笨拙的問題。

我試過了

perl C:\speadread-master\speedread (and yes, it was on the C: drive)

我得到了錯誤:

Use of encoding pragma is deprecated at C:\speadread-master\speedread line 39.
'stts' is not recognized as an internal or external command, operable program of batch file. 
←[31mc←[0←[K

我也嘗試過(因為它出現在github的gif中)

~/speedread$ head -n 21 tea.txt | ./speedread -w 250

我得到了錯誤:

'~' is not recognized as an internal or external command, operable program or batch file

除了amon注釋 ,wo還指出了對Unix命令/顯示的強烈依賴,您還誤解了head命令:

~/speedread$是Unix 命令提示符with ~表示您的HOME目錄(在Windows中為USERPROFILE )。 您不應該鍵入它。

實際命令是:

head -n 21 tea.txt | ./speedread -w 250

此外,您在git msysgit發行版( bin/head.exe )中有一個head.exe (unix命令head Windows版本)。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM