docs: add contributing guidelines #38
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| jobs: | |
| lint: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup Bun | |
| uses: oven-sh/setup-bun@v2 | |
| with: | |
| bun-version: latest | |
| - name: Install dependencies | |
| run: bun install --ignore-scripts | |
| - name: Check formatting and lint | |
| run: bun run lint | |
| test: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup Bun | |
| uses: oven-sh/setup-bun@v2 | |
| with: | |
| bun-version: latest | |
| - name: Install dependencies | |
| run: bun install --ignore-scripts | |
| - name: Run tests | |
| run: bun test | |
| test-postinstall: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| - name: Test postinstall script | |
| run: node postinstall.mjs | |
| - name: Verify agents were installed | |
| run: | | |
| test -f ~/.config/opencode/agents/opencoder.md | |
| test -f ~/.config/opencode/agents/opencoder-planner.md | |
| test -f ~/.config/opencode/agents/opencoder-builder.md | |
| echo "All agents installed successfully" | |
| - name: Test preuninstall script | |
| run: node preuninstall.mjs | |
| - name: Verify agents were removed | |
| run: | | |
| test ! -f ~/.config/opencode/agents/opencoder.md | |
| test ! -f ~/.config/opencode/agents/opencoder-planner.md | |
| test ! -f ~/.config/opencode/agents/opencoder-builder.md | |
| echo "All agents removed successfully" |