gem install nanoc
nanoc --version
nanoc create_site web
nanoc compile
nanoc view
gem install kramdown
gem install adsf
---
title: Home
---
# This is Bob's web page
Welcome! I like to code and I need some internet presence.
## Interests
- Programming
- Design
- Typography
## Hobbies
- Baseball
- Tennis
compile '/'
fileter :kramdown
layout 'default'
end
<%= yield %>
如此即可讓整個網頁更個人化
nanoc create_item contact
打開新產生的文件,然後輸入以下的文字:
---
title: A New Item
---
My email address is [email protected]
接者, 更動以下幾個地方來完成我們的個人網頁。我們在 Rules 裡面告訴 nanoc 要處理 contact.html 這個檔案
compile '/contact' do
filter :kramdown
layout 'default'
end
<%= yield %>
重新編譯開啓伺服器後,試試看點擊 home 跟 contact 來確定路徑是否都設定正確。