major pull, major push, major validate, and major publish work on whatever the current folder is linked to: an app, an agent, a skill, or a workflow. The link lives in .major/config.json, which major <kind> create and major <kind> clone write for you. You can run these commands from the folder or any subfolder.
If no .major/config.json is found, the commands fail and tell you to create or clone something first.
All four commands accept
--json to print one JSON result.
For an app,
major push and major publish require you to be checked out on the repository’s default branch. The CLI never switches branches or force-pushes.Files each kind uses
Symlinks are rejected. Other files in the folder are left alone.
major pull
Bring the folder up to date with Major.- Agent, skill, or workflow: downloads the latest saved version and replaces the kind’s files in the folder. Files the version no longer has are deleted. Local edits to those files are overwritten, so push first if you want to keep them.
- App: runs
git pull --no-rebase. On a conflict, git’s conflict markers are left in place for you to resolve.
major push
Save the folder as a new version.-
Agent, skill, or workflow: uploads the folder as a new unpublished version and prints its version number.
-msets the version notes (workflows do not store notes). Nothing changes for users until you runmajor publish. -
App: pushes local commits to the default branch.
- With uncommitted changes and
-m, push stages every change in the repository (git add -A), commits with-mas the message, then pushes. - With uncommitted changes and no
-m, push fails and commits nothing. - With a clean tree, push pushes
HEADand commits nothing.
major pushwith a clean tree. If the remote has commits you do not have, runmajor pull, resolve any conflicts, and push again. - With uncommitted changes and
major validate
Check the folder before you push or publish.- Agent, skill, or workflow: sends the local files to Major for validation. It reports that the bundle is valid, with any warnings, or fails with each error and the file it applies to. Validating does not save a version.
- App: runs
pnpm run lintin the app folder. The command fails ifpackage.jsonhas nolintscript, and exits with lint’s exit code if lint fails.
major publish
Release the latest saved version. You are asked to confirm unless you pass--yes.
- Agent, skill, or workflow: publishes the latest saved version on Major, not your local files. Run
major pushfirst to publish local edits. For a workflow, the output lists any triggers that failed to register. - App: deploys the latest commit on the default branch and waits for the deployment to finish. Your local
HEADmust already be on the remote: if it is not, runmajor pushfirst. If the remote is ahead, runmajor pullfirst. An app that has never been deployed needs--slugto choose its URL.