all-contributors:在README.md文档里自动添加贡献者名单
感谢贡献者🤝
Misaka-xxw 📝 |
Misaka-xxw-10032 🖋 |
Misaka-xxw-20001 💻 |
||||
|
网上的教程:https://www.jianshu.com/p/0c61cec0f5d1
官方文档:https://allcontributors.org/docs/zh-cn/overview
安装应用
安装该Github应用的网址:https://allcontributors.org/docs/zh-cn/bot/installation
all-contributors-cli和使用配置
依赖npm或者yarn1
2npm i -D all-contributors-cli
npx all-contributors init
回答它问你的问题,会获得类似这样的一个json。失败的话可能是因为你的仓库没公开什么的1
2
3
4
5
6
7
8
9
10
11
12
13
14
15{
"projectName": "XMU-CS-exam",
"projectOwner": "Misaka-xxw",
"repoType": "github",
"repoHost": "https://github.com",
"files": [
"README.md"
],
"imageSize": 100,
"commit": true,
"commitConvention": "gitmoji",
"contributorsPerLine": 7,
"linkToUsage": true
}
还会在README.md文档里生成一些html标签,不要删除。会在之间自动生成贡献者表格1
2
3
4
5<!-- ALL-CONTRIBUTORS-BADGE:START - Do not remove or modify this section -->
<!-- ALL-CONTRIBUTORS-BADGE:END -->
<!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section -->
<!-- ALL-CONTRIBUTORS-LIST:END -->
常用指令:1
2
3npx all-contributors check # 检查未添加的贡献者
npx all-contributors add Misaka-xxw content # 添加贡献者Misaka-xxw,职责是内容
npx all-contributors generate # 生成表格
然后直接push即可o( ̄▽ ̄)ブ
附录:官方文档的职责表
Emoji/Type | Represents | Comments |
---|---|---|
🔊 audio | Audio | Podcasts, background music or sound effects |
♿️ a11y | Accessibility | Reporting or working on accessibility issues |
🐛 bug | Bug reports | Links to issues reported by the user on this project |
📝 blog | Blogposts | Links to the blogpost |
💼 business | Business Development | People who execute on the business end |
💻 code | Code | Links to commits by the user on this project |
🖋 content | Content | e.g. website copy, blog posts are separate |
🔣 data | Data | Links to contributed data for the project (both tests and datasets) |
📖 doc | Documentation | Links to commits by the user on this project, Wiki, or other source of documentation |
🎨 design | Design | Links to the logo/iconography/visual design/etc. |
💡 example | Examples | Links to the examples |
📋 eventOrganizing | Event Organizers | Links to event page |
💵 financial | Financial Support | People or orgs who provide financial support, links to relevant page |
🔍 fundingFinding | Funding/Grant Finders | People who help find financial support |
🤔 ideas | Ideas & Planning | |
🚇 infra | Infrastructure | Hosting, Build-Tools, etc. Links to source file (like travis.yml) in repo, if applicable |
🚧 maintenance | Maintenance | People who help in maintaining the repo, links to commits by the user on this project |
🧑🏫 mentoring | Mentoring | People who mentor new contributors, links to the repo home |
📦 platform | Packaging | Porting to support a new platform |
🔌 plugin | Plugin/utility libraries | Links to the repo home |
📆 projectManagement | Project Management | |
📣 promotion | Promotion | |
💬 question | Answering Questions | Answering Questions in Issues, Stack Overflow, Gitter, Slack, etc. |
🔬 research | Research | Literature review. |
👀 review | Reviewed Pull Requests | |
🛡️ security | Security | Identify and/or reduce security threats, GDPR, Privacy, etc |
🔧 tool | Tools | Links to the repo home |
🌍 translation | Translation | Links to the translated content |
⚠️ test | Tests | Links to commits by the user on this project |
✅ tutorial | Tutorials | Links to the tutorial |
📢 talk | Talks | Links to the slides/recording/repo/etc |
📓 userTesting | User Testing | Links to user test notes |
📹 video | Videos | Links to the video |