-
Notifications
You must be signed in to change notification settings - Fork 0
54 lines (46 loc) · 1.85 KB
/
Copy pathsetup.yml
File metadata and controls
54 lines (46 loc) · 1.85 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
name: Template Setup
on:
push:
branches: [main]
jobs:
setup:
if: github.run_number == 1
runs-on: ubuntu-latest
permissions:
issues: write
steps:
- uses: actions/checkout@v4
- name: Check if template
id: check
run: |
NAME=$(node -e "console.log(JSON.parse(require('fs').readFileSync('package.json','utf8')).name)")
if [ "$NAME" = "my-extension" ]; then
echo "is_template=true" >> "$GITHUB_OUTPUT"
else
echo "is_template=false" >> "$GITHUB_OUTPUT"
fi
- name: Create setup checklist
if: steps.check.outputs.is_template == 'true'
env:
GH_TOKEN: ${{ github.token }}
run: |
gh issue create \
--title "Setup: Configure your extension" \
--body "$(cat <<'EOF'
Welcome! You've created a new project from **vscode-extension-starter**. Here's your setup checklist:
## Required
- [ ] Update `package.json` — change `name`, `displayName`, `description`, `publisher`
- [ ] Update command prefix in `package.json` contributes (replace `my-extension.`)
- [ ] Update command prefix in `src/commands/helloWorld.js`
- [ ] Set `engines.vscode` to the minimum VS Code version you need
## CI/CD Setup
- [ ] **VS Marketplace:** Add `VSCE_PAT` GitHub Secret — see [Marketplace Setup Guide](docs/MARKETPLACE_SETUP.md)
- [ ] **Open VSX:** Add `OVSX_PAT` GitHub Secret — see [Open VSX Setup Guide](docs/OPENVSX_SETUP.md)
## Recommended
- [ ] Add your own commands in `src/commands/`
- [ ] Write tests in `tests/` and run with `npm test`
- [ ] Update `CHANGELOG.md` with your changes
- [ ] Delete this issue when done
Happy building!
EOF
)"