gon publish
Promote an existing local module at src/{Name}/ to a full rozklad/gon-{kebab} package on GitHub. Complement to gon make:module — use it when a module was scaffolded without --no-repo earlier, or when it started as a draft in src/ and now deserves its own repo.
Usage
gon publish Admissions # Tag derived from module.json versiongon publish Admissions --tag=v1.2.0 # Explicit tag overridegon publish Admissions --commit-message="Initial extract" # Custom initial commit messagegon publish Admissions --public # Public GitHub repogon publish Admissions --org=rozklad # Under an orggon publish Admissions --use-existing # Reuse remote if it already existsgon publish Admissions --skip-push # Git init + attach remote, don't pushgon publish Admissions --skip-checksum # Don't baseline the module in .gon/module-checksums/
What happens
git init -b maininsrc/{Name}/.git add .+ initial commit.- Creates
rozklad/gon-{kebab}on GitHub (private by default). - Adds remote + pushes main.
- Tags
v{version-from-module.json}+ pushes tag. - Writes
.gon/module-checksums/{Name}.jsonbaseline.
Refuses to run if src/{Name}/.git already exists — won't overwrite history.
After publish
- Add the module to the project's
gon.jsonrequires:"{kebab}": "^{version}". - Refresh the registry cache:
gon search --refresh. - Bump + retag later: edit
src/{Name}/module.jsonversion, commit in the module repo,git -C src/{Name} tag vX.Y.Z && git -C src/{Name} push origin vX.Y.Z.