* Refactor internal return types and cognitive complexity
- Eliminate named record return types in _buildContext and _loadIgnores in favor of standard Future<T> single-value returns
- Audit and document _parse* methods in config_parser.dart and helper methods in test suites
- Extract top-level test helpers _createMockRelease and _runInstallScriptTest in install_script_test.dart to lower main function cognitive complexity score
- Update definition-of-done skill fail-threshold to 20
* Tighten CI cognitive complexity fail-threshold to 20 (#212)
* Automate CI threshold assertion and delegate DOD skill to CI workflow (#212)
* Move CI workflow consistency test out of recipe drift into dedicated test suite (#212)
* Remove unused normalizedSkillPath from _getIgnoresForSkill (#212)
* Migrate generator test off deprecated resolvedRules onto resolvedRuleConfigs
* Remove duplicate validate_skills CLI workflow job
* Ensure lint_skills_test is path-resilient and asserts non-empty directoryConfigs
* Fix omit_local_variable_types lints in lint_skills_test.dart
* Simplify lint_skills_test to direct ConfigParser.loadConfig() call
* Update onboarding docs and skills to include directoryConfigs.isNotEmpty assertion when loading config
* Address PR discussion r3617291798: handle working directory when run from repo root
* Make working directory path resolution cross-platform for Windows, macOS, and Linux
* Format lint_skills_test.dart with dart format
---------
Co-authored-by: Reid-Agent <269567208+reidbaker-agent@users.noreply.github.com>
* Add v0.4.0-dev.1 preview: native binary distribution
- New tag-triggered release workflow builds dart_skills_lint as a
standalone native binary for macOS arm64/x64 and Linux x64/arm64
via `dart compile exe`, packages each as a tarball with SHA256,
and cuts a GitHub Release with release notes extracted from
CHANGELOG.md.
- New install.sh detects OS/arch, downloads the matching tarball,
verifies SHA256, and installs to INSTALL_DIR (default /usr/local/bin
with sudo fallback). REPO/VERSION/INSTALL_DIR are env-configurable
so the script survives the impending dart_skills_lint repo move
with a single default-value edit.
- Pub.dev install paths (`dart pub global activate` and dev_dependency)
are unchanged; binaries are a parallel channel.
- macOS binaries in this preview are unsigned. Homebrew formula is
deferred until the new home repo is settled to avoid forcing
early adopters through a re-tap on migration.
* Bump GitHub Actions to Node 24-compatible versions
- actions/upload-artifact: v4 → v7 (was the Node 20 deprecation
warning source from the first fork test)
- actions/download-artifact: v4 → v8
- softprops/action-gh-release: v2 → v3
All three were on Node 20, which GitHub forces to Node 24 on
2026-06-16. Each matrix job uploads with a unique artifact
name, so v5+'s duplicate-name restriction is non-issue.
download-artifact v8's new error-on-hash-mismatch default is
a security upgrade.
* Update README install section for v0.4.0-dev.1 binary preview
Lead with install.sh as the recommended path; add a direct-curl
variant for environments that don't pipe scripts to bash. Keep
the pub.dev paths (dev_dependency and `dart pub global activate`)
unchanged under a "Dart developers" section.
Documents the macOS Gatekeeper workaround for unsigned preview
binaries, a brief note that Homebrew is coming after the imminent
repo migration, and the pinning syntax to opt into the preview
track. Bumps the stable caret range example from ^0.2.0 to ^0.3.0.
* Address Gemini review on install.sh
- install.sh:118 (high): print the macOS Gatekeeper note BEFORE the
--help launch check so users see the xattr workaround even when
Gatekeeper blocks the binary. On macOS, downgrade the --help
failure from a hard err to an informational message since the
install itself succeeded; the launch will work once quarantine
is cleared. Non-macOS still hard-errs on launch failure.
- install.sh:80 (medium): strip leading '*' from SHA256SUMS field 2
before comparison so binary-mode hash files (sha256sum -b output)
work as well as text-mode.
* Address self-review on PR #158
- install.sh: collapse three hand-rolled "Supported: ..." messages
behind one SUPPORTED_TARGETS constant, so the error text and the
final platform check share a source of truth. Error text now lists
normalized targets (macos-arm64, macos-x64, linux-x64, linux-arm64)
instead of raw uname variants.
- CHANGELOG.md: shrink the 0.4.0-dev.1 entry to match the 0.3.1
style — flat user-facing bullets, no internal workflow detail or
Homebrew roadmap.
- README.md: reorder the Installation section so the pub.dev path
(existing Dart audience) comes first, followed by install.sh and
the direct-download path for the no-Dart preview audience.
* Refactor install.sh tests to be robust, add Linux tests and missing error coverage
* Fix custom linter warnings and format test file
* Fix omit_obvious_local_variable_types analyzer warning in test
* Pin softprops/action-gh-release to commit SHA to resolve review feedback
* Pin VeryGoodOpenSource/very_good_coverage to commit SHA
* Add tag mapping comments to pinned action commit SHAs
* Fix flaky Windows dart analyze; enforce dart_code_linter on test/
Drop the dart_code_linter analyzer `plugin` registration from
analysis_options.yaml. When registered, `dart analyze` loaded the plugin
in a separate isolate that re-emitted the `dart_code_linter:` rules as
diagnostics over the plugin protocol for all non-excluded files. Delivery
of those diagnostics to the CLI is asynchronous and racy, so on slower
Windows CI runners they intermittently appeared and `--fatal-infos` turned
them fatal -- a flaky, platform-specific failure (#144). `dart analyze` now
enforces only core lints, deterministically across platforms.
The dedicated `dart run dart_code_linter:metrics` step is the deterministic
enforcement path for those rules; extend it to cover `test` as well as
`lib` so the test suite gets real, cross-platform coverage instead of the
accidental flaky version.
Fix the test-file violations this surfaces:
- avoid-late-keyword: replace `late Directory tempDir` fixtures with a
shared createTempDir() helper that registers cleanup via addTearDown,
removing duplicated tearDown blocks.
- avoid-dynamic: `dynamic noSuchMethod` -> `Object?`.
- avoid-redundant-async: drop the redundant async in a setUp.
Exclude prefer-match-file-name for test/**: test files must be named
`*_test.dart` and commonly hold several small fixture classes, so they
cannot match the rule's "file name == first class name" convention.
* Exclude avoid-late-keyword for tests instead of placeholder workaround
Address review feedback: rather than initializing tempDir fixtures to a
placeholder to satisfy avoid-late-keyword, exclude the rule for test/**
(as already done for prefer-match-file-name). `late` for fields assigned
in setUp is the idiomatic Dart test pattern. Reverts the createTempDir
helper and placeholder initializations; fixtures are plain `late` again.
The genuine, non-late fixes are kept: avoid-dynamic (Object? noSuchMethod)
and avoid-redundant-async (drop async from a sync setUp).
* Apply suggestion from @reidbaker
* Add CI line-coverage gate for dart_skills_lint
Collect coverage with `dart test --coverage`, convert to LCOV via the
already-transitive package:coverage, and enforce a minimum threshold in
CI with the VeryGoodOpenSource/very_good_coverage action (min 73%,
excluding *.g.dart). Adds contributor docs and a CHANGELOG entry. No new
pub dependencies and no custom coverage parsing to maintain.
* Document --ignore-files to exclude *.g.dart from local coverage
Adds a GitHub Actions workflow to automatically run CI checks for the skills CLI tool. Tests are run on both Ubuntu, Mac and Windows for the `stable` and `dev` Dart SDK channels. The workflow triggers on pushes and pull requests to the main branch that modify the `tool/` directory, and runs:
- `dart pub get`
- `dart analyze --fatal-infos`
- `dart format` (on the dev channel only)
- `dart test` - is currently omitted as the test suite needs to be refactored to work properly without relying on real API keys in the CI environment
https://github.com/flutter/flutter/issues/183124