Skip to content

Commit 7994475

Browse files
committed
translate /intro-to-rails/getting-started to zh-tw
1 parent 7f6fe3e commit 7994475

File tree

2 files changed

+28
-29
lines changed

2 files changed

+28
-29
lines changed
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
message "`cd` stands for change directory."
1+
message "`cd` 的意思是切換目錄(Change Directory)"
22

33
option "Windows" do
44
console "cd c:\\Sites"
5-
message "`cd c:\\Sites` sets our Sites directory to our current directory."
5+
message "`cd c:\\Sites` 會把 Sites 設成當前目錄。"
66
end
7-
option "Mac or Linux" do
7+
option "Mac Linux" do
88
console "cd ~"
9-
message "`cd ~` sets our home directory to our current directory."
9+
message "`cd ~` 會把家目錄設成當前目錄。"
1010
end
Original file line numberDiff line numberDiff line change
@@ -1,99 +1,98 @@
11
img src: "img/Start_page.png", alt: "Start Page"
22

33
goals do
4-
goal "Create Your New Application"
5-
message "Let's get started! By the end of this step, we'll have a brand-spankin'-new (empty) rails app."
4+
goal "建立你的 New Application"
5+
message "來,開始吧!在這一步驟的最後,我們會得到一個全新的(空白)Rails 應用程式。"
66
end
77

88
steps do
99

10-
tip "If you have _any_ problems, contact a TA immediately."
10+
tip "有*「任何」*問題,請立刻舉手問助教。"
1111

1212
step do
1313
insert 'switch_to_home_directory'
1414
end
1515

1616
step do
1717
console "mkdir railsbridge"
18-
message "This command creates a new directory for us to store our project in."
18+
message "這會新增一個資料夾,讓我們把專案放在裡面。"
1919
end
2020

2121
step do
2222
console "cd railsbridge"
2323
end
2424

2525
step do
26-
message "Check to see if you have any existing suggestotron apps from a previous workshop."
26+
message "確定一下你有沒有之前工作坊留下來的 suggestotron 應用程式在裡面"
2727
console "ls"
28-
message "That command will list the files in your railsbridge directory. If you have any old suggestotron apps in that list, you can remove them to prevent hiccups:"
28+
message "這指令會列出 railsbridge 資料夾裡面的檔案。如果列出了舊的 suggestotron 應用程式,你可以刪掉它們來避免干擾:"
2929
console "rm -rf suggestotron"
3030
end
3131

3232
step do
3333
console "rails new suggestotron"
34-
message "'rails new' creates a new rails project with the name you give."
35-
message "In this case we told it to create a new project called `suggestotron`. We'll go into detail on what it created shortly."
34+
message "'rails new' 會用你給的名字來建立新的 Rails 專案"
35+
message "這次我們叫它建立叫做 `suggestotron` 的新專案。我們馬上就會詳述它到底建立了什麼。"
3636
end
3737

3838
step do
3939
console "cd suggestotron"
40-
message "'cd' stands for change directory."
41-
message "'cd suggestotron' makes suggestotron our current directory."
40+
message "'cd' 指的是切換目錄 (change directory)。"
41+
message "'cd suggestotron' suggestotron 資料夾設成當前資料夾。"
4242
end
4343

4444
step do
4545
console "ls"
46-
message "'ls' stands for 'list (stuff)'."
47-
message "It shows you the contents of the current folder."
46+
message "'ls' 指的是列出東西 (list stuff)"
47+
message "它會把目前資料夾的內容列出來給你看。"
4848
end
4949

5050
step do
5151
message <<-MARKDOWN
52-
Open the suggestotron folder as a project in your text editor.
52+
在你的文字編輯器裡面用專案的方式打開 suggestotron 資料夾。
5353

54-
In **Sublime Text 2**, you can use the `Project > Add Folder to Project...` menu option:
54+
**Sublime Text 2** 裡面,你可以選擇 `Project > Add Folder to Project...`
5555

5656
<img src='img/sublime_add_folder_to_project.png' />
5757

58-
Select your `suggestotron` folder from the file picker that opens. If everything works out Sublime should look something like this:
58+
然後在檔案對話方塊裡面選擇 `suggestotron` 資料夾。如果一切沒問題的話,Sublime 會變得像這樣:
5959

6060
<img src='img/sublime_project_as_folder.png' />
6161
MARKDOWN
6262
end
6363

6464
message <<-MARKDOWN
65-
You can see that <code>rails new</code> created a lot directories and
66-
files. The ones we want to focus on today are:
65+
你會發現 <code>rails new</code> 開了一大堆資料夾和檔案。今天我們要看的是這些:
6766
MARKDOWN
6867

6968
table border: "1", cellspacing: "0", cellpadding: "3", align: "center" do
7069
tr {
71-
th "File/Folder"
72-
th "Purpose"
70+
th "檔案/資料夾"
71+
th "用途"
7372
}
7473
tr {
7574
td "app/"
76-
td "Contains the controllers, models, and views for your application. You will do most of your work here."
75+
td "包含你應用程式的 controllersmodelsviews。你要改的東西大多是這些。"
7776
}
7877
tr {
7978
td "config/"
80-
td "Configure your application's runtime rules, routes, database, and more."
79+
td "設定應用程式的執行階段規則、路由設定(routes)、資料庫等等。"
8180
}
8281
tr {
8382
td "db/"
84-
td "Shows your current database schema, as well as the database migrations."
83+
td "顯示你目前資料庫的 schema(結構定義),以及資料庫的 migrations"
8584
}
8685
tr {
8786
td "public/"
88-
td "The only folder seen to the world as-is. If you put files in here, they will be served directly without any processing by Rails."
87+
td "這是唯一一個資料夾會是放什麼就出現什麼的。如果你把檔案放裡面,server 會直接回傳,不會經過 Rails 的處理。"
8988
}
9089
tr {
9190
td "app/assets/"
92-
td "This is where your images, JavaScript, stylesheets (CSS), and other static files should go. Modern rails apps use something called the Assets Pipeline, which combines all the JavaScript and CSS files in this directory into a single file for speediness."
91+
td "你會要把圖片、JavaScriptstylesheets (CSS) 還有其他靜態檔案放在裡面。現代的 Rails 應用程式使用一種叫做 Assets Pipeline 的東西,把在這資料夾裡面的所有 JavaScript CSS 檔合併成一個檔案來加速。"
9392
}
9493
end
9594

96-
message "There is a lot more that `rails new` created. Probably enough to fill a book, so we're going to ignore them for now."
95+
message "`rails new` 還建立了其他很多東西。大概可以寫一本書來講,所以我們現在先無視它們。"
9796
end
9897

9998
next_step "add_the_project_to_a_git_repo"

0 commit comments

Comments
 (0)