How to Contribute
Thank you for your interest in contributing to DeepScanBot! We welcome contributions from the community.
Code of Conduct
This project adheres to our Code of Conduct. By participating, you are expected to uphold this code. Please report unacceptable behavior by opening an issue or emailing deepscanbot@mindfiresolutions.com.
Getting Started
1. Fork the Repository
Start by forking the DeepScanBot repository on GitHub.
2. Clone Your Fork
git clone https://github.com/YOUR_USERNAME/DeepScanBot.git
cd DeepScanBot
3. Set Up Development Tools
# Code formatting
go install mvdan.cc/gofumpt@latest
# Import management
go install github.com/daixiang0/gci@latest
# Linting
go install github.com/golangci/golangci-lint/cmd/golangci-lint@latest
# Git hooks
go install github.com/evilmartians/lefthook@latest && lefthook install
4. Sync and Create a Branch
Make sure your fork is up to date with the base repository before creating a feature branch:
# Add the upstream remote (one-time setup)
git remote add upstream https://github.com/mindfiredigital/DeepScanBot.git
# Sync with the latest development branch
git checkout development
git pull upstream development
git push origin development
# Create your feature branch
git checkout -b feat/your-feature-name
Development Workflow
Code Formatting
All Go code must be formatted with gofumpt:
gofumpt -l -w .
Import Management
Imports must be organized with gci:
gci write --skip-vendor -s standard -s default -s "prefix(github.com/mindfiredigital/DeepScanBot)" .
Linting
Run the linter before committing:
golangci-lint run ./...
Testing
Ensure all tests pass:
go test ./...
Local npm Package Testing
Test the npm package locally before committing:
# Build binaries for all platforms
goreleaser build --snapshot --clean
# Verify binaries
node scripts/verify-binary.js
# Create npm package
npm pack
# Install locally for testing
npm install -g ./deep-scan-bot-*.tgz
# Test the installed binary
deepscanbot --version
deepscanbot -h
# Uninstall after testing
npm uninstall -g @mindfiredigital/deep-scan-bot
Pre-publish Checks
Before publishing, run the prepublish check:
node scripts/prepublish-check.js
Commit Messages
This project uses Conventional Commits:
feat: add new feature
fix: resolve issue with X
docs: update documentation
refactor: improve code structure
test: add tests for X
chore: update dependencies
Pull Request Process
- Ensure your code passes all linting and tests
- Update documentation if needed
- Submit a pull request with a clear description of changes
- Your PR will be reviewed by maintainers
Project Structure
apps/
cli/ # CLI entry point and tests
docs/ # Docusaurus documentation site
packages/
crawler/ # Core crawling logic
fetcher/ # HTTP fetch layer
logger/ # Logging utilities
parser/ # HTML parsing
storage/ # Result storage and reports
types/ # Shared type definitions