Thank you for contributing to compare-vi-cli-action!
- Self-hosted Windows runner with LabVIEW 2025 Q3 installed and licensed
- LVCompare must be installed at the canonical path:
C:\Program Files\National Instruments\Shared\LabVIEW Compare\LVCompare.exe;LVCOMPARE_PATHorlvComparePathmay be used only if they resolve to this canonical location (no alternative install paths supported)
- Fork and clone the repo
- Create a feature branch
- Run the staging smoke helper before pushing:
pwsh -File tools/Test-PRVIStagingSmoke.ps1 -DryRunto preview the plannode tools/npm/run-script.mjs smoke:vi-stageto run end-to-end using the baked-infixtures/vi-attrattribute diff All staging runs post a summary comment and uploadvi-compare-manifest/vi-staging-XX.zipartifacts; check the comment for links.
- The action is composite with
pwshsteps; prefer small changes and test incrementally - Exit code mapping: 0 = no diff, 1 = diff; any other exit code should fail fast (outputs preserved)
- Full CLI flags are passed through
lvCompareArgs(quotes supported) - You can set
working-directoryto control relative path resolution forbaseandhead
We use a multi-document strategy for comprehensive coverage:
- README.md - Quick start and basic usage (keep focused, ~600 lines max)
- docs/USAGE_GUIDE.md - Advanced configuration and recipes
- docs/DEVELOPER_GUIDE.md - Testing, building, and release process
- docs/TROUBLESHOOTING.md - Common issues and solutions
- docs/COMPARE_LOOP_MODULE.md - Loop mode details
- docs/INTEGRATION_TESTS.md - Test prerequisites and setup
- docs/TESTING_PATTERNS.md - Advanced test design patterns
- Keep README focused on getting started quickly; move details to topic-specific guides
- Cross-link between documents for easy navigation
- When adding new features, update relevant guide documents
- Keep examples copy-paste friendly and accurate
- Document breaking changes prominently in README and CHANGELOG
- PRs run markdownlint and actionlint via
.github/workflows/validate.yml - Run
.github/workflows/test-mock.ymlon PRs (windows-latest); use smoke on self-hosted for real LVCompare - Keep README examples accurate and executable
See the Developer Guide for comprehensive testing information including:
- Running unit tests
- Running integration tests
- Test dispatcher architecture
- Continuous development workflow
Quick commands:
# Unit tests only
./Invoke-PesterTests.ps1
# Integration tests (requires LVCompare)
$env:LV_BASE_VI = 'VI1.vi'
$env:LV_HEAD_VI = 'VI2.vi'
./Invoke-PesterTests.ps1 -IntegrationMode include- In repository settings → Branches → Add rule for
main - Require status checks to pass before merging:
ValidateTest (mock)
- Optionally require linear history and dismiss stale approvals
- Add topics for discoverability:
labview,lvcompare,vi,composite-action,windows,github-actions
- Ensure
action.ymlname,description, andbrandingare correct (icon:git-merge, color:blue) - Publish the repository to GitHub Marketplace
- Update
README.mdwith a Marketplace link after publication
- Tag semantic versions (e.g.,
v0.1.0); the release workflow readsCHANGELOG.mdto generate release notes - After tagging, ensure README examples reference the latest stable tag
- CODEOWNERS:
@svelderrainruiz
node tools/npm/run-script.mjs priority:bootstrap- detect the current plane, run hook preflight (and parity when--VerboseHooksis supplied), and refresh the standing-priority snapshot/router.node tools/npm/run-script.mjs priority:handoff- ingest the latest handoff artifacts (issue-summary.json,issue-router.json, hook and watcher summaries) into the session, hydrating$StandingPrioritySnapshot,$StandingPriorityRouter, etc.node tools/npm/run-script.mjs priority:handoff-tests- run the priority/hooks/semver checks and persist results totests/results/_agent/handoff/test-summary.jsonfor downstream agents.node tools/npm/run-script.mjs priority:release- simulate the release actions described by the router; pass--Executeto runBranch-Orchestrator.ps1 -Executeinstead of the default dry-run.node tools/npm/run-script.mjs handoff:schema— validate the hook handoff summary (tests/results/_agent/handoff/hook-summary.json) againstdocs/schemas/handoff-hook-summary-v1.schema.json.node tools/npm/run-script.mjs handoff:release-schema— validate the release summary (tests/results/_agent/handoff/release-summary.json) againstdocs/schemas/handoff-release-v1.schema.json.node tools/npm/run-script.mjs semver:check— assert the currentpackage.jsonversion complies with SemVer 2.0 viatools/priority/validate-semver.mjs.
These helpers make the sandbox feel pseudo-persistent: each agent self-injects the previous session’s state before starting work and leaves updated artifacts when finishing.
-
The repository pins
core.hooksPath=tools/hooks. Hooks are implemented as a Node core (tools/hooks/core/*.mjs) with thin shell/PowerShell shims so Linux, Windows, and CI all execute the same logic. -
Hook summaries are written to
tests/results/_hooks/<hook>.jsonand include exit codes, truncated stdout/stderr, and notes (e.g., when PowerShell is unavailable on Linux). -
Run hook logic manually before committing/pushing:
node tools/npm/run-script.mjs hooks:pre-commit node tools/npm/run-script.mjs hooks:pre-push
Passing
HOOKS_PWSH=/path/to/pwshorHOOKS_NODE=/path/to/nodeoverrides discovery if needed. -
Additional helpers:
node tools/npm/run-script.mjs hooks:plane # show detected plane + enforcement mode node tools/npm/run-script.mjs hooks:preflight # verify dependencies for the current plane node tools/npm/run-script.mjs hooks:multi # run shell + PowerShell wrappers and diff JSON node tools/npm/run-script.mjs hooks:schema # validate summaries against the v1 schema
-
Control behaviour via
HOOKS_ENFORCE=fail|warn|off(default:failin CI,warnlocally). Failures become warnings when enforcement iswarn, and are suppressed entirely when set tooff. -
PowerShell-specific lint (inline-if, dot-sourcing, PSScriptAnalyzer) only runs when
pwshis available; otherwise the hook marks those steps asskippedand records a note in the summary. -
The CI parity job ensures Windows and Linux shims stay in sync—if hook outputs drift, the workflow fails with a diff.
Markdown lint configuration intentionally disables the MD013 (line length) rule globally. Rationale:
- Technical tables, JSON fragments, and schema / command examples often exceed 160 chars and wrapping them reduces readability.
- Large refactor risk: historical sections (dispatcher notes, loop mode tuning) rely on long inline code spans.
Guidelines:
- Prefer wrapping narrative paragraphs to a reasonable width (~120–160) for new content, but do not hard-wrap within embedded JSON, PowerShell code fences, or tables.
- Break up extremely long explanatory list items (>220 chars) unless doing so fragments a schema or command.
- Use concise language; remove redundant qualifiers (e.g., "in order to" → "to").
- Keep bullet introductions on their own line before long wrapped sub-lines for scanability.
When a single long line is clearer (e.g., a one-line JSON example), keep it—no inline disable needed since MD013 is off.
If we later re-enable MD013:
- Reintroduce a
"MD013": { "line_length": 160 }block in.markdownlint.jsonc. - Add per-line opt-outs using
<!-- markdownlint-disable-next-line MD013 -->above intentional long lines. - Avoid splitting code spans across lines solely for lint; prefer disabling for that line.
Always ensure examples remain copy/paste friendly (avoid trailing spaces, stray prompts inside code blocks).