Commits
Commits
3 min read
This area of the manual covers everything that happens between staging and the recorded commit:
the commit box in the changes panel, the message (summary and description), the commit options,
the rules the message has to follow, the trailers (Co-authored-by, Signed-off-by), amending
the last commit, and signing with GPG or SSH.
Choosing what goes into the commit (staging files, hunks and lines) and reading the diff are in the Changes area. Rewriting older commits (interactive rebase, commit surgery, squash) is in the History area.
- You select the // WIP row at the top of the graph. The right panel shows the changes and, below them, the commit box.
- You stage what goes into the commit (see Staging).
- You write the Commit summary and, if you want, the Description (optional). You can start from a template, use Conventional mode, add co-authors and include the issue reference.
- You click the commit button (or press Ctrl+Enter).
- Before recording, Versora checks the message and what is staged: team rules, commitlint, identity, secrets, large files, protected branch and other warnings. If something comes up, you fix it or go ahead anyway, depending on the case.
- Versora runs
git commitwith the message. If a hook rejects it, the output stays in the box. - The commit goes into the undo history: Ctrl+Z undoes it and puts the changes back in staging.
- The commit box: summary, description, automatic wrapping at
column 72, expanded editor, Commit options (skip hooks and push after committing), the
output of a hook that rejected the commit, the Ctrl+Enter,
Ctrl+Shift+Enter, Ctrl+Shift+M
and Alt+I shortcuts, the
.versora.ymlrules and the checks before committing. - Conventional Commits: Conventional mode (type, scope,
breaking change) and validation by the repository's commitlint, by the repository requirement
and by
.versora.yml. - Message templates: git's
commit.template, the team templates in.versora/commit-templates/and your own, with the{branch},{issue},{author},{email},{date}and{files}variables, which are also replaced whencommit.templatefills the empty box on its own. - Co-authors and Signed-off-by: adding other people as co-authors,
adding
Signed-off-byand the AI co-authorship trailer required by the team. - Spell checker: the underlined words, the suggestions on right-click and the dictionary language.
- Amend: amending the last commit: changing the message or adding changes to the last commit, and what to do if it has already been pushed.
- Commit signing: signing with GPG, SSH or X.509, for all repositories or just one.
Preferences open with Ctrl+, or from the gear on the tab bar. Several pages touch on commits:
| Preferences page | What it has about commits |
|---|---|
| Commit | Recommended summary limit, push after committing and signing (global and per repository) |
| Commit message | Message templates, spell checker and the repository's "don't commit" list |
| Operations | Automatic wrapping of the commit body and the wrap column |
| Versions and commits | Require Conventional Commits, block a message with errors, structured commit box and what the app understood from commitlint |
| Push rules | Add Signed-off-by to every commit in the repository and the push rules checked before committing |
| Policy and team | The .versora.yml and company policy rules that apply to the message |
| SSH and GPG keys | "Use to sign commits…" on an existing key |
For IT
The company policy can hide any of these pages or make it read-only, and can enforce a minimum
for the message rules (title length, Conventional Commits, allowed types, Signed-off-by and the
AI trailer). See Company policy and
The .versora.yml file.