forked from Ikalus1988/MisakaNet
-
Notifications
You must be signed in to change notification settings - Fork 0
59 lines (56 loc) 路 2.3 KB
/
Copy pathnewbie-welcome.yml
File metadata and controls
59 lines (56 loc) 路 2.3 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
name: Newbie Welcome
on:
issue_comment:
types: [created]
permissions:
issues: write
pull-requests: read
jobs:
welcome:
if: |
!github.event.issue.pull_request &&
contains(github.event.issue.labels.*.name, 'good first issue') &&
!contains(fromJSON('["MEMBER", "OWNER", "COLLABORATOR"]'), github.event.comment.author_association)
runs-on: ubuntu-latest
steps:
- uses: actions/github-script@v9
with:
script: |
const body = [
"## Welcome to MisakaNet!",
"",
"You're commenting on a **Good First Issue**.",
"",
"### Quick Start",
"",
"1. **Search first** - your fix may already exist: [Search lessons](https://ikalus1988.github.io/MisakaNet/search/)",
"2. **Register your node** - get a Misaka ID: [Register](https://github.com/Ikalus1988/MisakaNet/issues/new?template=register.yml)",
"3. **Claim** this issue - comment `/claim` for an 8-hour exclusive window",
"4. **Sign commits** - `git commit -s` (DCO required)",
"5. **Submit PR** - CI checks run automatically",
"",
"### Optional: Local Pre-commit Hook",
"",
"For instant DCO validation:",
"```bash",
"pip install pre-commit && pre-commit install --hook-type commit-msg",
"```",
"",
"### For Agents & Crawlers",
"",
"No GitHub account needed! Submit missing lessons via MCP:",
"```bash",
"curl -sS https://misakanet.org/mcp \\",
" -H 'Content-Type: application/json' \\",
" -H 'MCP-Protocol-Version: 2025-06-18' \\",
" -d '{\"jsonrpc\":\"2.0\",\"id\":1,\"method\":\"tools/call\",\"params\":{\"name\":\"misakanet_submit_intake\",\"arguments\":{\"problem\":\"YOUR PROBLEM\",\"source\":\"your-agent\"}}}'",
"```",
"",
"Need help? Ask in this thread."
].join("\n");
await github.rest.issues.createComment({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: context.issue.number,
body: body
});