不小心逛到GitHub的 Gist, Gist這是拿來給大家記錄和分享一些程式小片段的服務,
Gist is a simple way to share snippets and pastes with others. All gists are Git repositories, so they are automatically versioned, forkable and usable from Git.
繼承Git的優良血統, Gist同樣的有版本控制、另開分支、複製下載…的功能。另外還有提供把Gist嵌入其他網站或部落格的script,只要網站有支援Javascript語法張貼,大大們都可以輕鬆分享自己的小心血。
每天都和Ruby, Ruby on Rails, Swift…這些程式碼混在一起,一直都有很多需要筆記的地方,本來是用google note暫記,然後要整理到部落格之類的服務,除了考慮到程式碼的編輯、顯示,而且開發過程中很多東西會一直需要修改修正也希望留下記錄,有時候一次來不及作完整可以下次再繼續,在Gist這裡剛好可以放我的那些程式小屑屑,順便學習使用 Markdown的語法。
待辦事項: to do list checkbox: "- [ ] XXXXx" "- [ ] "每一個中間都要有空格,空的表示未勾選,x 表示勾選,顯示上會有小圈圈可以點
- Location 資料庫寫死
- Hospital status? on : off
- [ ] Hospital,前台不要,後台要
- [ ] Hospital.status 直接勾選變更?
要如何在Markdown文件中加入程式碼: 加入程式碼,用``這個包起來:
inline code I think you should use an
<addr>
element here instead.
GitHub Flavored Markdown GitHub 有自己版本的 Markdown語法
GitHub.com uses its own version of the Markdown syntax that provides an additional set of useful features, many of which make it >easier to work with content on GitHub.com.
如果是要編輯整段程式碼,在程式碼前後加上```,就可以完美呈現惹,在官方文件上是說4個空白或一個tab,或者是前後用``包起來,但在Gist中,好像不起作用,不知道是不是因為Gist的原因。
a.each do |b|
b.status = true
b.save`
end
一般連結Link
Go to Markdown Taiwan
Go TO Markdown Taiwan
不支援_blank啊
一般連結Link
Go TO [Markdown Taiwan](http://markdown.tw/)
Go TO [Markdown Taiwan](http://markdown.tw/ "這裡只能放title屬性")
<a href="markdown.tw" target="_blank">不支援_blank啊</a>
參考式連結
This is an example reference-style link.
I get 10 times more traffic from [Google] 1 than from [Yahoo] 2 or [MSN] 3.
[id]: http://example.com/ "Optional Title Here"
[id] 這一行可以寫在任何地方,用法如下:
[an example] 連結顯示文字,[id] 連結網址
This is [an example][id] reference-style link.
參考連結,可以方便管理連結?將整個段落的連結整理到段落下方
I get 10 times more traffic from [Google] [1] than from
[Yahoo] [2] or [MSN] [3].
[1]: http://google.com/ "Google"
[2]: http://search.yahoo.com/ "Yahoo Search"
[3]: http://search.msn.com/ "MSN Search"
John Gruber: Markdown就是從這位大大手上出來的,內有說明文件
John Gruber的Daring Fireball網站,平常沒事會咬咬嚼嚼 Apple 各種八掛動態的那個
Markdown: 語法說明,看到.tw,嘴角昇起一抹他鄉遇老鄉的微笑,是中文版的窩♪
GitHub: 關於Markdown的功能說明