mirror of
https://github.com/linux-odyssey/linux-odyssey.git
synced 2026-11-06 03:20:13 +08:00
fix: update quest [move]
This commit is contained in:
1 parent
551d502845
commit
3a28af0a67
1 file changed
+45
-45
+45
-45
@@ -3,24 +3,24 @@ instruction: |
|
|||||||
在這個關卡中,你將會學到:
|
在這個關卡中,你將會學到:
|
||||||
1. 如何用 `mv` 移動檔案與資料夾
|
1. 如何用 `mv` 移動檔案與資料夾
|
||||||
|
|
||||||
準備好就輸入 `echo start` 開始吧!
|
按下中間的 `start` 按鈕來開始這個關卡。
|
||||||
|
|
||||||
requirements:
|
requirements:
|
||||||
- create
|
- create
|
||||||
|
|
||||||
stages:
|
stages:
|
||||||
- id: start
|
- id: start
|
||||||
task: 輸入 `echo start` 來開始
|
task: 按下 `start` 按鈕開始
|
||||||
condition:
|
condition:
|
||||||
command:
|
command:
|
||||||
- ^echo start$
|
- ^echo start$
|
||||||
responses:
|
responses:
|
||||||
- type: narrative
|
- type: narrative
|
||||||
content:
|
content: |
|
||||||
- 今天我們要學習如何移動檔案與資料夾。
|
今天我們要學習如何移動檔案與資料夾。
|
||||||
- 現在資料夾裡有一個 `hello.txt` 跟一個 `world.txt`,以及一個 `notes` 資料夾。
|
現在資料夾裡有一個 `hello.txt` 跟一個 `world.txt`,以及一個 `notes` 資料夾。
|
||||||
- 請先用 `ls` 與 `cat` 來查看它們的內容。
|
請先用 `ls` 與 `cat` 來查看它們的內容。
|
||||||
- 看完之後,使用 `echo continue` 來繼續吧!
|
看完之後,使用 `echo continue` 來繼續吧!
|
||||||
hints:
|
hints:
|
||||||
- ➤ 用 `ls`、`ls notes` 來查看資料夾內的檔案
|
- ➤ 用 `ls`、`ls notes` 來查看資料夾內的檔案
|
||||||
- ➤ 用 `cat hello.txt` 以及 `cat world.txt` 來查看檔案內容
|
- ➤ 用 `cat hello.txt` 以及 `cat world.txt` 來查看檔案內容
|
||||||
@@ -35,11 +35,11 @@ stages:
|
|||||||
- ^echo continue$
|
- ^echo continue$
|
||||||
responses:
|
responses:
|
||||||
- type: narrative
|
- type: narrative
|
||||||
content:
|
content: |
|
||||||
- 現在我們要來學習如何移動檔案與資料夾。
|
現在我們要來學習如何移動檔案與資料夾。
|
||||||
- '`mv` 指令是移動 move 的縮寫,可以用來移動檔案與資料夾。'
|
`mv` 指令是移動 move 的縮寫,可以用來移動檔案與資料夾。
|
||||||
- 使用方式為 `mv [來源] [目的地]`。
|
使用方式為 `mv [來源] [目的地]`。
|
||||||
- 我們先來將 `hello.txt` 移動到 `notes` 資料夾中吧!
|
我們先來將 `hello.txt` 移動到 `notes` 資料夾中吧!
|
||||||
hints:
|
hints:
|
||||||
- ➤ 使用 `mv hello.txt notes` 來將 `hello.txt` 移動到 `notes` 資料夾中
|
- ➤ 使用 `mv hello.txt notes` 來將 `hello.txt` 移動到 `notes` 資料夾中
|
||||||
|
|
||||||
@@ -57,9 +57,9 @@ stages:
|
|||||||
exists: false
|
exists: false
|
||||||
responses:
|
responses:
|
||||||
- type: narrative
|
- type: narrative
|
||||||
content:
|
content: |
|
||||||
- 你做得很好!
|
你做得很好!
|
||||||
- 我們用 `ls` 跟 `ls notes` 來查看一下資料夾內的檔案吧!
|
我們用 `ls` 跟 `ls notes` 來查看一下資料夾內的檔案吧!
|
||||||
hints:
|
hints:
|
||||||
- ➤ 使用 `ls`、`ls notes` 來查看資料夾內的檔案
|
- ➤ 使用 `ls`、`ls notes` 來查看資料夾內的檔案
|
||||||
|
|
||||||
@@ -74,8 +74,8 @@ stages:
|
|||||||
- ^ls$
|
- ^ls$
|
||||||
responses:
|
responses:
|
||||||
- type: narrative
|
- type: narrative
|
||||||
content:
|
content: |
|
||||||
- '`hello.txt` 已經不在資料夾中了!'
|
`hello.txt` 已經不在資料夾中了!
|
||||||
|
|
||||||
- id: ls-notes-hello
|
- id: ls-notes-hello
|
||||||
requirements:
|
requirements:
|
||||||
@@ -90,8 +90,8 @@ stages:
|
|||||||
- hello.txt
|
- hello.txt
|
||||||
responses:
|
responses:
|
||||||
- type: narrative
|
- type: narrative
|
||||||
content:
|
content: |
|
||||||
- '`hello.txt` 出現在 `notes` 資料夾中了!'
|
`hello.txt` 出現在 `notes` 資料夾中了!
|
||||||
|
|
||||||
- id: continue-mv
|
- id: continue-mv
|
||||||
requirements:
|
requirements:
|
||||||
@@ -103,10 +103,10 @@ stages:
|
|||||||
- ^echo continue$
|
- ^echo continue$
|
||||||
responses:
|
responses:
|
||||||
- type: narrative
|
- type: narrative
|
||||||
content:
|
content: |
|
||||||
- '`mv` 指令也可以用來更改檔案名稱。'
|
`mv` 指令也可以用來更改檔案名稱。
|
||||||
- '只要將目的地改成新的檔案名稱就可以了。'
|
只要將目的地改成新的檔案名稱就可以了。
|
||||||
- 現在我們要將 `world.txt` 更名為 `wow.txt`。
|
現在我們要將 `world.txt` 更名為 `wow.txt`。
|
||||||
hints:
|
hints:
|
||||||
- ➤ 使用 `mv world.txt wow.txt` 來將 `world.txt` 更名為 `wow.txt`
|
- ➤ 使用 `mv world.txt wow.txt` 來將 `world.txt` 更名為 `wow.txt`
|
||||||
|
|
||||||
@@ -124,9 +124,9 @@ stages:
|
|||||||
exists: false
|
exists: false
|
||||||
responses:
|
responses:
|
||||||
- type: narrative
|
- type: narrative
|
||||||
content:
|
content: |
|
||||||
- 你做得很好!
|
你做得很好!
|
||||||
- 我們用 `ls` 來確認一下資料夾內的檔案吧!
|
我們用 `ls` 來確認一下資料夾內的檔案吧!
|
||||||
hints:
|
hints:
|
||||||
- ➤ 使用 `ls` 來查看資料夾內的檔案
|
- ➤ 使用 `ls` 來查看資料夾內的檔案
|
||||||
|
|
||||||
@@ -143,12 +143,12 @@ stages:
|
|||||||
- wow.txt
|
- wow.txt
|
||||||
responses:
|
responses:
|
||||||
- type: narrative
|
- type: narrative
|
||||||
content:
|
content: |
|
||||||
- '`world.txt` 現在已經變成 `wow.txt` 了。'
|
`world.txt` 現在已經變成 `wow.txt` 了。
|
||||||
- 接下來我們來學習如何移動資料夾吧!
|
接下來我們來學習如何移動資料夾吧!
|
||||||
- 移動資料夾非常簡單,方法跟移動檔案一樣。
|
移動資料夾非常簡單,方法跟移動檔案一樣。
|
||||||
- '`mv` 指令會自動將資料夾內的所有檔案一起移動'
|
`mv` 指令會自動將資料夾內的所有檔案一起移動
|
||||||
- 我們先來將 `notes` 資料夾改名叫作 `docs` 吧!
|
我們先來將 `notes` 資料夾改名叫作 `docs` 吧!
|
||||||
hints:
|
hints:
|
||||||
- ➤ 使用 `mv notes docs` 來將 `notes` 資料夾改名叫作 `docs`
|
- ➤ 使用 `mv notes docs` 來將 `notes` 資料夾改名叫作 `docs`
|
||||||
|
|
||||||
@@ -166,9 +166,9 @@ stages:
|
|||||||
exists: false
|
exists: false
|
||||||
responses:
|
responses:
|
||||||
- type: narrative
|
- type: narrative
|
||||||
content:
|
content: |
|
||||||
- 你做得很好!
|
你做得很好!
|
||||||
- 我們用 `ls` 來確認一下資料夾內的檔案吧!
|
我們用 `ls` 來確認一下資料夾內的檔案吧!
|
||||||
hints:
|
hints:
|
||||||
- ➤ 使用 `ls` 來查看資料夾內的檔案
|
- ➤ 使用 `ls` 來查看資料夾內的檔案
|
||||||
|
|
||||||
@@ -185,11 +185,11 @@ stages:
|
|||||||
- docs
|
- docs
|
||||||
responses:
|
responses:
|
||||||
- type: narrative
|
- type: narrative
|
||||||
content:
|
content: |
|
||||||
- '`notes` 資料夾已經變成 `docs` 了。'
|
`notes` 資料夾已經變成 `docs` 了。
|
||||||
- 那麼最後來考考你:
|
那麼最後來考考你:
|
||||||
- 試著將 `docs/hello.txt` 移動到家目錄底下的 `hi.txt`。
|
試著將 `docs/hello.txt` 移動到家目錄底下的 `hi.txt`。
|
||||||
- 如果你不知道怎麼做,可以輸入 `echo hint` 來取得提示。
|
如果你不知道怎麼做,可以輸入 `echo hint` 來取得提示。
|
||||||
|
|
||||||
- id: END
|
- id: END
|
||||||
requirements:
|
requirements:
|
||||||
@@ -209,12 +209,12 @@ stages:
|
|||||||
- ^echo hint$
|
- ^echo hint$
|
||||||
responses:
|
responses:
|
||||||
- type: narrative
|
- type: narrative
|
||||||
content:
|
content: |
|
||||||
- 你可以使用 `mv docs/hello.txt hi.txt` 來完成這個任務。
|
你可以使用 `mv docs/hello.txt hi.txt` 來完成這個任務。
|
||||||
hints:
|
hints:
|
||||||
- ➤ 使用 `mv docs/hello.txt hi.txt` 來將 `docs/hello.txt` 移動到家目錄底下的 `hi.txt`
|
- ➤ 使用 `mv docs/hello.txt hi.txt` 來將 `docs/hello.txt` 移動到家目錄底下的 `hi.txt`
|
||||||
responses:
|
responses:
|
||||||
- type: narrative
|
- type: narrative
|
||||||
content:
|
content: |
|
||||||
- 你做得很好!
|
你做得很好!
|
||||||
- 你已經學會如何移動檔案與資料夾了!
|
你已經學會如何移動檔案與資料夾了!
|
||||||
Reference in new issue
Block a user