Skip to content

feat: modernize cli bootstrap and docs#2

Open
ss-o wants to merge 1 commit into
mainfrom
feature-modernize-cli-docs
Open

feat: modernize cli bootstrap and docs#2
ss-o wants to merge 1 commit into
mainfrom
feature-modernize-cli-docs

Conversation

@ss-o
Copy link
Copy Markdown
Member

@ss-o ss-o commented May 16, 2026

Summary

  • allow --help, --version, and init flows to run without revolver
  • add zunit init --github-actions bootstrap support
  • refresh repository docs and organization-owned links
  • correct stale CLI/reporting messages and add focused regression coverage

Verification

  • ./build.zsh
  • PATH="$tmpbin:$PATH" ./zunit --tap tests/cli.zunit tests/reports.zunit → 8/8 passing with a temporary stub revolver
  • zsh -n src/zunit.zsh src/commands/init.zsh src/commands/run.zsh src/reports/html.zsh
  • git diff --check

@ss-o ss-o marked this pull request as ready for review May 16, 2026 12:15
Copilot AI review requested due to automatic review settings May 16, 2026 12:15
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Modernizes the ZUnit CLI bootstrap path and refreshes the docs to point at the z-shell organization. Help/version/init flows can now run without revolver installed, zunit init --github-actions scaffolds a GitHub Actions workflow, and several stale URLs / messages are corrected. New focused tests cover the no-revolver flows and the new bootstrap output.

Changes:

  • Move --help, --version, and init handling above the revolver dependency check in src/zunit.zsh, and add a -g/--github-actions flag to _zunit_init that writes .github/workflows/zunit.yml.
  • Rewrite README.md, contributing.md, and code-of-conduct.md to point at the Z-Shell organization, drop outdated package-manager recipes, and delegate to org-wide policy docs.
  • Fix stale strings (Run \zulu init`zunit init, supresssuppress, HTML report link/documentation link to z-shell/zunit) and add tests/cli.zunit/tests/reports.zunit` regression coverage.

Reviewed changes

Copilot reviewed 10 out of 10 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
src/zunit.zsh Parse -h/-v and dispatch init before requiring revolver; update missing-dependency URL.
src/commands/init.zsh Add -g/--github-actions bootstrap, update Travis template's revolver/color URLs to zdharma.
src/commands/run.zsh Correct the missing-config error from zulu init to zunit init.
src/reports/html.zsh Update the documentation link in the HTML report header to z-shell/zunit.
zunit.zsh-completion Fix supresssuppress typos and advertise the new -g/--github-actions flag.
tests/cli.zunit New regression tests for the no-revolver CLI flows and GitHub Actions bootstrap.
tests/reports.zunit New test asserting the HTML report template links to the maintained repo.
README.md Rewrite for the Z-Shell org, drop unsupported install methods, refresh docs link.
contributing.md Slim down to org-wide contributing guidance and a focused development workflow.
code-of-conduct.md Replace the inlined Contributor Covenant with a pointer to the org-wide policy.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/commands/init.zsh
sudo apt-get update
sudo apt-get install -yq zsh
mkdir -p .bin
curl -fsSL 'https://github.com/zunit-zsh/zunit/releases/download/v${zunit_version}/zunit' > .bin/zunit
Comment thread src/commands/init.zsh
@@ -72,13 +75,43 @@ allow_risky: false"
install:
- mkdir .bin
- curl -L https://github.com/zunit-zsh/zunit/releases/download/v$(_zunit_version)/zunit > .bin/zunit
Comment thread src/commands/init.zsh
echo " -v, --version Output version information and exit"
echo " -t, --travis Generate .travis.yml in project"
echo " -h, --help Output help text and exit"
echo " -v, --version Output version information and exit"
Comment thread tests/cli.zunit
Comment on lines +12 to +16
PATH='/usr/bin:/bin'
run "$PWD/zunit" --version

assert "$state" equals 0
assert "$output" same_as '0.8.2'
Comment thread tests/cli.zunit
Comment on lines +27 to +36
@test 'report output without config points users to zunit init' {
local sandbox
sandbox="$(mktemp -d)"

cd "$sandbox"
run "$OLDPWD/zunit" --output-text

assert "$state" equals 1
assert "$output" contains '.zunit.yml could not be found. Run `zunit init`'
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants