feat: Add Taskfile, CI workflows, and filtered contact generation#1
Merged
feat: Add Taskfile, CI workflows, and filtered contact generation#1
Conversation
This commit adds comprehensive CI/CD infrastructure and contact list automation: Build System: - Add Taskfile.yml with 17+ tasks (build, test, lint, ci, generate-contacts) - Modern go-task setup with smart caching and cross-platform support CI/CD Workflows: - test.yml: Run tests on Go 1.21/1.22, frontend build, code quality checks - release.yml: Build cross-platform binaries (Linux, macOS, Windows, AMD64/ARM64) - generate-contacts.yml: Automated contact filtering on filter file changes Contact Generation: - New CLI: --generate-contacts with --filter-file, --source-file, --output-file - Support for 3 output formats: - radioid (default): RadioID.net format - dm32uv: Baofeng DM32UV format - at890: AnyTone 890 format (quoted fields) - Taskfile task: task generate-contacts (with FORMAT= env var) Documentation: - Updated README with Taskfile usage and contact generation examples - Added filters/ directory with README and example filter CSV Closes #<issue-number>
- Update go.mod to Go 1.26.1 - Update CI workflows to use Go 1.26.1 - Add .golangci.yml with comprehensive linter configuration - Fix unchecked errors in cmd/generate_contacts.go - All tests pass, linting clean
- Add pre-commit hook that runs golangci-lint before each commit - Add scripts/install-hooks.sh for easy installation - Update README with git hooks documentation - Hook can be bypassed with --no-verify in emergencies
- Add comprehensive project structure overview - Document all supported radios (DB25-D, DM32UV, AnyTone 890) - Document Taskfile workflow and available tasks - Document CI/CD workflows and release process - Document contact generation with all 3 formats - Document git hooks and code quality requirements - Update Go version to 1.26.1 - Add CLI examples for common operations
- Add brandmeister-automation.yml workflow for auto-generating contacts - Add .goreleaser.yml for cross-platform binary releases - Update release.yml to use GoReleaser - Add release tasks to Taskfile - Update documentation
- Add MIT LICENSE file required for goreleaser - Remove SBOM generation (requires syft which isn't in CI by default)
The Go tests were failing because main.go embeds frontend/dist but that directory wasn't being built in the test-go job. Added Bun setup and frontend-build step before running Go tests.
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR adds comprehensive CI/CD infrastructure using go-task (Taskfile) and automated filtered contact list generation.
Changes
Build System
task build- Build with frontendtask fast-build- Quick build without frontendtask test- Run all teststask ci- Run all CI checks (fmt, vet, lint, test)task generate-contacts- Generate filtered contact listsCI/CD Workflows
test.yml: Runs on PRs and pushes to main
release.yml: Triggered on version tags (v*)
generate-contacts.yml: Automated contact filtering
filters/directoryContact Generation
New CLI flags for
--generate-contacts:./codeplugs --generate-contacts \ --filter-file filters/my-contacts.csv \ --source-file user.csv \ --output-file contacts.csv \ --contact-format dm32uv # or radioid (default), at890Supported formats:
radioid(default): RadioID.net formatdm32uv: Baofeng DM32UV formatat890: AnyTone 890 format (quoted fields, CRLF)Documentation
filters/README.mdwith filter file format detailsfilters/example-filter.csvTesting
Migration Notes
Makefile is still present for backward compatibility but marked as deprecated. Users should migrate to
taskcommands.