mirror of
https://github.com/linux-odyssey/linux-odyssey.git
synced 2026-11-08 11:30:12 +08:00
quest: add check empty file stage
This commit is contained in:
1 parent
dd7cded09e
commit
06c694ee68
1 file changed
+16
-1
+16
-1
@@ -47,7 +47,22 @@ stages:
|
|||||||
- type: narrative
|
- type: narrative
|
||||||
content:
|
content:
|
||||||
- 你應該可以看到終端機上顯示了 `hello.txt` 這個檔案。
|
- 你應該可以看到終端機上顯示了 `hello.txt` 這個檔案。
|
||||||
- 我們再來試試建立其他的檔案吧!
|
- 我們來看看 `hello.txt` 檔案的內容吧!
|
||||||
|
- 我們可以使用之前學過的 `cat` 指令來查看檔案內容。
|
||||||
|
hints:
|
||||||
|
- 輸入 `cat hello.txt` 來查看 `hello.txt` 檔案的內容
|
||||||
|
|
||||||
|
- id: cat
|
||||||
|
condition:
|
||||||
|
command:
|
||||||
|
- ^cat hello.txt$
|
||||||
|
responses:
|
||||||
|
- type: narrative
|
||||||
|
content:
|
||||||
|
- 咦?竟然什麼都沒有!
|
||||||
|
- 沒錯,使用 `touch` 指令建立的檔案是空的。
|
||||||
|
- 我們在未來會學習如何編輯檔案的內容。
|
||||||
|
- 再來試試建立其他的檔案吧!
|
||||||
- 請你試著在終端機上建立另一個檔案,檔名為 `world.txt`。
|
- 請你試著在終端機上建立另一個檔案,檔名為 `world.txt`。
|
||||||
hints:
|
hints:
|
||||||
- 輸入 `touch world.txt` 來建立一個檔案
|
- 輸入 `touch world.txt` 來建立一個檔案
|
||||||
|
|||||||
Reference in new issue
Block a user