Github 徽章整理
相信很多在Github上玩耍過的同學們都會發現,在很多項目的README裏會有各式各樣的徽章,是不是頓時感覺到很高上大?沒關係,讀完這篇文章你就也可以擁有這些徽章了,甚至可以定製自己的徽章。
NodeJs
如果這是一個用npm管理的一個包,請添加:
[版本圖片](https://www.npmjs.com/package/項目名)
如果你使用了第三方的組件,那可以標識是否爲最新版本。
TypeScript
如果你是TypeScript開發者,那麼請把下面的這些徽章用起來吧:
[![TypeScript](https://badges.frapsoft.com/typescript/love/typescript.svg?v=101)](https://github.com/ellerbrock/typescript-badges/)
[![TypeScript](https://badges.frapsoft.com/typescript/code/typescript.svg?v=101)](https://github.com/ellerbrock/typescript-badges/)
[![TypeScript](https://badges.frapsoft.com/typescript/awesome/typescript.png?v=101)](https://github.com/ellerbrock/typescript-badges/)
[![TypeScript](https://badges.frapsoft.com/typescript/version/typescript-v18.svg?v=101)](https://github.com/ellerbrock/typescript-badges/)
還有更多的格式與尺寸詳見這裏。
awesome
如果你是awesome系列的項目,那可以添加awesome徽章:
[圖片](https://github.com/sindresorhus/awesome)
Google Analytics
Google Analytics是通過嵌入圖像追蹤項目訪問量的一種方法。
如我的DogFood項目就內嵌了一個追蹤圖像:
具體制作過程可以參考。
Gitter
這是對issue功能的一個補充。正常情況下,當你給某個項目提出問題時,需要新建一個issue提出,並且需要等待開發者的回覆(短則一兩天,長則大半年),效率不是很高。而Gitter就提供了一個實時的聊天室,項目的開發者可以用github賬號登陸之,爲某個項目創建一個聊天室,然後再項目的Readme中加入如下代碼:
[![Gitter](https://badges.gitter.im/Join Chat.svg)](聊天室 URL)
就可以顯示聊天室的徽章啦:
[
單擊即可進入聊天室,與開發者進行實時溝通。
Code Related
有很多的在線測試平臺都提供測試狀態標識,你可以把他們放到相應項目中的README中:
- Travis Ci
- Codecov
- Code Climate
- bithound
Version Stability
[![deprecated](http://badges.github.io/stability-badges/dist/deprecated.svg)](http://github.com/badges/stability-badges)
[![experimental](http://badges.github.io/stability-badges/dist/experimental.svg)](http://github.com/badges/stability-badges)
[![unstable](http://badges.github.io/stability-badges/dist/unstable.svg)](http://github.com/badges/stability-badges)
[![stable](http://badges.github.io/stability-badges/dist/stable.svg)](http://github.com/badges/stability-badges)
[![frozen](http://badges.github.io/stability-badges/dist/frozen.svg)](http://github.com/badges/stability-badges)
[![locked](http://badges.github.io/stability-badges/dist/locked.svg)](http://github.com/badges/stability-badges)
更多請看這裏。
Open Source
[![Open Source Love](https://badges.frapsoft.com/os/v1/open-source.svg?v=103)](https://github.com/ellerbrock/open-source-badge/)
[![Open Source Love](https://badges.frapsoft.com/os/v2/open-source.svg?v=103)](https://github.com/ellerbrock/open-source-badge/)
[![Open Source Love](https://badges.frapsoft.com/os/v3/open-source.svg?v=103)](https://github.com/ellerbrock/open-source-badge/)
還有更多的徽章格式與尺寸詳見這裏。
Licences
Software
開源軟件協議的種類非常多,具體可以參考阮一峯的如何選擇開源許可證?,本文列舉了MIT和GPL:
[![MIT Licence](https://badges.frapsoft.com/os/mit/mit.svg?v=103)](https://opensource.org/licenses/mit-license.php)
[![GPL Licence](https://badges.frapsoft.com/os/gpl/gpl.svg?v=103)](https://opensource.org/licenses/GPL-3.0/)
還有更多的徽章格式與尺寸詳見這裏。
Creative Commons
知識共享是一系列著作權許可方式,我們可以在官網選擇自己的許可協議。如我採用了知識共享署名-相同方式共享:
This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.
Others
Github上有一個badges的倉庫,裏面收集了一些常用的,大家可以參考一下。
Your Badges
如果你需要自己定製一個徽章的話,可以參考這裏。
About me
- Weibo:@AnSwEr不是答案
- GitHub:AnSwErYWJ
- Blog:AnSwEr不是答案的專欄
This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.
本作品採用知識共享署名-相同方式共享 4.0 國際許可協議進行許可。