First off, thank you for considering contributing to the ForLoop Plugin! It's people like you that make the ForLoop Plugin such a great tool for the community.
This project and everyone participating in it is governed by the Code of Conduct. By participating, you are expected to uphold this code.
Before creating an issue, check if:
- The README answers your question
- The docs/ folder has relevant documentation
- A similar issue already exists in the issue tracker
If not, feel free to open an issue with the "question" label.
Bugs are tracked as GitHub issues. Create an issue and provide the following information:
- Summary: A clear, descriptive title
- Environment: opencode version, Node.js version, OS
- Steps to Reproduce: Detailed steps to reproduce the issue
- Expected behavior: What you expected to happen
- Actual behavior: What actually happened
- Logs: Any relevant error messages or logs
- Additional context: Screenshots, workarounds tried, etc.
Feature suggestions are welcome! Create an issue with:
- Summary: Clear, descriptive title
- Problem statement: What problem does this solve?
- Proposed solution: How should it work?
- Alternatives considered: Other approaches you've thought about
- Use cases: Who will benefit from this feature?
- Additional context: Examples, mockups, etc.
- Fork the repository and clone it locally:
git clone https://github.com/YOUR_USERNAME/forloop-opencode-plugin.git
cd forloop-opencode-plugin- Install dependencies:
npm install- Set up local development:
# Add the plugin to your local opencode.json pointing to this directory
jq '.plugin |= (. // []) + ["file://'"$(pwd)"'"] | .plugin |= unique' \
opencode.json > opencode.json.tmp && mv opencode.json.tmp opencode.json-
Make your changes following the coding conventions
-
Run tests:
# Run all tests
npm test
# Run specific test suite
npm run test:unit
npm run test:integration- Run type checking:
npm run typecheck- Create a branch from
main:
git checkout -b feature/your-feature-name-
Make your changes following our coding standards:
- Write tests for new functionality
- Update documentation for user-facing changes
- Follow existing code style
- Add inline comments only when necessary (code should be self-documenting)
-
Commit your changes with clear, descriptive messages:
git commit -m "feat: add new feature description"We follow Conventional Commits:
feat:for new featuresfix:for bug fixesdocs:for documentation changesstyle:for formatting changesrefactor:for code refactoringtest:for adding testschore:for maintenance tasks
- Push to your fork:
git push origin feature/your-feature-name- Open a Pull Request against the
mainbranch
Before submitting your PR, ensure:
- Tests pass (
npm test) - Type checking passes (
npm run typecheck) - Code follows existing style
- Documentation is updated
- Commit messages are clear and follow conventions
- PR description explains the change and why
- TypeScript: Strict mode enabled, explicit types
- Formatting: Consistent indentation, meaningful variable names
- Error handling: Return user-friendly error messages from tools
- Comments: Only for complex logic, not for obvious code
- Unit tests: Test individual functions/components in isolation
- Integration tests: Test API interactions (requires API token)
- Test naming: Describe the expected behavior
- Test structure: Arrange, Act, Assert pattern
Example:
describe('forloopSprintList', () => {
it('should list sprints successfully', async () => {
// Arrange
mockClient.listSprints.mockResolvedValue([...])
// Act
const result = await tool.execute({}, {} as any)
// Assert
expect(result).toContain('Sprints')
})
})- Update
CHANGELOG.mdwith new version and changes - Bump version in
package.json:
npm version patch # or minor, or major- Push tags:
git push --follow-tags- Publish to npm:
npm publishFeel free to open an issue or reach out to the maintainers.
Thank you for contributing! 🚀