Thanks for helping improve Pushman CLI. Bug reports, focused fixes, tests, documentation, and usability feedback are welcome.
- Search existing issues before opening a new one.
- Use GitHub Discussions for support and open an issue for reproducible bugs or concrete proposals.
- Never include credentials, tokens, private notification content, or unredacted logs.
- For vulnerabilities, follow SECURITY.md instead of opening a public issue.
For a substantial feature or public command change, open a proposal first in the Pushman product repository. The hosted API and product behavior are maintained outside this repository, so a CLI change may require an accepted contract change before implementation.
Pushman CLI requires Go 1.27 or newer.
git clone https://github.com/pushmanhq/pushman-cli.git
cd pushman-cli
go mod download
go generate ./internal/api
go test -p=1 -parallel=1 ./...
go vet ./...
make pdev ARGS=helpThe development target builds .bin/pushman-dev with a loopback API default, a separate Keychain namespace, PUSHMAN_DEV_TOKEN, and self-update disabled. It never replaces or reads credentials from an installed release command named pushman. make install-dev optionally installs the isolated shortcut as ~/.local/bin/pdev.
Go 1.27+ and Git are sufficient; Bash, GNU Make, and Homebrew are not required. In PowerShell, run native tests without the race flag unless the additional Windows race compiler/runtime prerequisites have been provisioned:
go mod download
if ($LASTEXITCODE -ne 0) { throw 'Dependency download failed' }
go generate ./internal/api
if ($LASTEXITCODE -ne 0) { throw 'Generation failed' }
git diff --exit-code -- internal/api/api.gen.go
if ($LASTEXITCODE -ne 0) { throw 'Generated API client changed' }
go test ./...
if ($LASTEXITCODE -ne 0) { throw 'Tests failed' }
go vet ./...
if ($LASTEXITCODE -ne 0) { throw 'Vet failed' }
$ldflags = '-X main.version=dev-local -X main.commit=working-tree -X main.date=local -X main.defaultBaseURL=http://127.0.0.1:8080/v1 -X main.credentialNamespace=dev -X main.automationTokenEnvironment=PUSHMAN_DEV_TOKEN'
go build -trimpath -ldflags $ldflags -o .bin/pushman-dev.exe ./cmd/pushman
if ($LASTEXITCODE -ne 0) { throw 'Development build failed' }
.\.bin\pushman-dev.exe help
if ($LASTEXITCODE -ne 0) { throw 'Development smoke failed' }This is the same isolated configuration as make build-dev. PUSHMAN_API_URL can override its loopback default; PUSHMAN_DEV_TOKEN is process-scoped and independent from release PUSHMAN_TOKEN. Self-update is disabled. Use the explicit development path instead of replacing a release installation or sharing its credential namespace.
go test -v ./internal/wincheck exercises Windows shells, real console/redirected handles, native console interruption, and an actual CLI stdio MCP process using only loopback services and synthetic values. Tests create hidden, owned console processes; they do not interrupt the user's console or open a browser.
Native Credential Manager tests are opt-in and live in a separate package/process from the mock-backed unit tests:
$previousNativeTest = $env:PUSHMAN_TEST_NATIVE_KEYRING
try {
$env:PUSHMAN_TEST_NATIVE_KEYRING = '1'
go test -v ./internal/credential/native
if ($LASTEXITCODE -ne 0) { throw 'Native credential test failed' }
} finally {
if ($null -eq $previousNativeTest) {
Remove-Item Env:PUSHMAN_TEST_NATIVE_KEYRING -ErrorAction SilentlyContinue
} else {
$env:PUSHMAN_TEST_NATIVE_KEYRING = $previousNativeTest
}
}The suite writes only a unique com.pushman.test.* entry with a synthetic value, registers cleanup before writing, and checks restart persistence/namespace isolation/deletion. A skipped suite is NOT RUN; an unavailable store in an opted-in run fails verification.
CI keeps Linux unit/core/generated-client/script/vulnerability checks, then a sequential macOS/native Windows x64/ARM64 matrix. Go package/test schedulers and matrix concurrency use one. Windows records its image/native architecture and runs credential/process tests, vet, an explicit .exe build and three-shell smoke. These native keyring, console, shell and MCP contracts protect OS behavior that mock/Linux checks cannot establish; they use bounded synthetic, loopback fixtures on standard hosted workers on every source PR. Published-ZIP/provenance, installer lifecycle and WinGet qualification remain in the existing exact-source release workflow-call profile. Use the verification record for release and desktop-host evidence. A PowerShell script policy may disallow a local .ps1 test wrapper; native Go tests and typed .exe commands do not require changing that policy.
Use PowerShell 7, native Go 1.27+, and pinned Inno Setup 6.7.3 to build an installer. The compiler bootstrap verifies the official download's SHA-256 and installs it for the current user. On a developer machine with Inno already installed, pass -Compiler to the builder. The installer source rejects other compiler versions.
go build -trimpath -ldflags '-s -w -X main.version=0.0.1-ci -X main.credentialNamespace=installer-test' -o .bin/pushman.exe ./cmd/pushman
if ($LASTEXITCODE -ne 0) { throw 'Build failed' }
$compiler = .\scripts\ensure-inno-setup.ps1
$candidate = .\scripts\build-windows-installer.ps1 -Version 0.0.1-ci -Architecture x86_64 -Executable .bin\pushman.exe -Compiler $compiler
.\scripts\test-windows-installer.ps1 -Installer $candidate.Installer -Executable .bin\pushman.exe -Version 0.0.1-ci -Architecture x86_64 -Compiler $compilerUse arm64 on native ARM64 Windows. Run lifecycle qualification on a disposable Windows account: it installs into an owned temporary directory, refuses an existing registered installation, and restores the exact user PATH value/type/existence in cleanup. It exercises real installation, repeat installation, update/rollback fixtures, PATH opt-out/preexisting entries, and removal while preserving unrelated files. It never logs in or sends a notification. The existing exact-source release CI profile runs both architectures and validates WinGet manifests. For related packaging changes, perform the same local qualification before submitting the PR and record native architecture, exact SHA/bytes, commands and results; unexecuted native/installer checks are explicit limits. See Windows distribution for release gates and catalog submission.
Before submitting a pull request:
test -z "$(gofmt -l .)"
go generate ./internal/api
git diff --exit-code -- internal/api/api.gen.go
go test -p=1 -parallel=1 ./...
go vet ./...Keep changes focused. Add or update tests for user-visible behavior, preserve the stdout/stderr contract, and do not hand-edit the generated API client. Commit messages use type: imperative summary, for example fix: reject an empty notification body.
By contributing, you agree that your contributions are licensed under the repository's MIT License. All participants must follow the Code of Conduct.
Basic CI uses normal unit/core checks. Any additional component/integration/race/
E2E needs a protected critical failure, why smaller checks cannot detect it, why
every relevant PR needs automation, and a stable isolated budget. No broad race
profile meets a separate per-PR need here; use make test-race locally for related
shared-memory changes and record exact SHA, environment, commands, scope, results
and skipped/untested boundaries in the PR body/comment. Runtime concurrency
assertions remain active. Packaging changes require the documented local native
ZIP/installer/WinGet contracts; release qualification still uses the original
automatic workflow call. Do not introduce manual Actions or nightly workflows
as a substitute. Diagnose setup, slow cases and resource pressure before adding
workers or sharding. Source CI never sends a notification or qualifies login.