Skip to content
Versora

Manual

Changes

Changes

4 min read

On this page

Everything you changed in the repository and haven't committed yet appears in the changes panel, on the right, when the // WIP row is selected in the graph. That's where you check each file in the diff, choose what goes into the next commit (the stage), throw away what you no longer want, tell git to ignore files and exchange changes with colleagues in the form of a patch.

This section explains that work from start to finish, before the commit. The commit itself (summary, description, amend, signing) is in the Commits section.

Three places a change can be

git keeps your work in three places, and Versora shows each of them:

PlaceWhat it isWhere it appears in Versora
Working directoryThe files as they are on disk right now.The panel's Unstaged files section; diff in "unstaged" mode (or "new file", for untracked files).
Stage (index)What will go into the next commit.The Staged files section; diff in "staged" mode.
HEADThe last commit of the current branch.The commit right below the // WIP row in the graph.

To stage is to copy a change from the working directory to the stage. To unstage is the opposite: take it out of the stage, without touching the file on disk. To discard is to return the file on disk to what is in the stage (or in HEAD), and that does erase work, which is why Versora keeps a copy first.

A typical flow

  1. You edit the files in your editor. The panel updates on its own (see "Automatic refresh" in The changes panel).
  2. You click each file to read the diff (Reading the diff).
  3. You stage what goes into the commit: the whole file, a hunk or just a few lines (Staging).
  4. Whatever is left and is no good, you discard (Discarding changes).
  5. Files that should never go into the repository (logs, builds, .env) go into .gitignore (Ignoring files).
  6. You write the message and commit in the commit box.

Pages in this section

PageWhat you find
The changes panelThe panel's sections, the list as paths or as a tree, each file's menu, the // WIP row menu and the automatic refresh when something changes on disk.
Staging by file, hunk and lineStaging and unstaging a file, a folder, everything, a hunk or chosen lines, the S, U and Ctrl+Shift+S shortcuts and the "Stage all changes" warnings.
Reading the diffUnified or split, whole file or only the hunks, context lines, Ignore whitespace, wrapping lines, Markdown preview, image diff and Pixel mode.
Discarding changesDiscarding a file, a hunk, lines or everything, deleting a file, and the backup copy that lets you undo with Ctrl+Z.
Ignoring files and .gitignore templatesIgnoring a file, an extension or a folder from the file menu, and adding ready-made templates to .gitignore.
Creating and applying patchesSaving a commit or a file's changes as a .patch, applying a patch file and pasting a copied patch with Ctrl+V.

Most used shortcuts in this area

ShortcutWhat it doesWhere it works
SStages the selected file.Changes panel and diff.
UUnstages the selected file.Changes panel and diff.
Ctrl+Shift+SStages everything.Open repository.
Ctrl+Shift+UUnstages everything.Open repository.
Ctrl+Shift+EnterStages everything and commits.Open repository (in a text field, only in the commit message).
Ctrl+Shift+MGoes to the commit message.Open repository.
EscCloses the diff (or clears the selected lines).In the diff.
Ctrl+VWith a patch copied, opens "Apply patch from clipboard".Outside a text field.
F5Refreshes the repository.Anywhere.
Ctrl+ZUndoes the last operation (for example, a discard).Open repository, outside text fields.

The keys that aren't fixed can be changed in Preferences › Keyboard shortcuts (see Keyboard shortcuts).

What Ctrl+Z undoes in this area

OperationDoes Ctrl+Z undo it?
Stage and unstage (file, folder, everything, hunk, lines)No. Just do the reverse operation: nothing on disk changes.
Staging a conflicted file (marking it as resolved, including through Stage all changes)Yes. The file goes back to the conflict.
Discarding a file, a hunk, lines or everythingYes. The app keeps a copy first, even during a stopped merge or rebase.
Deleting a fileYes.
Ignoring from the file menuNo. Edit the .gitignore (it appears in the changes).
.gitignore templatesYes, when the .gitignore already existed.
Apply patch from clipboardYes, for the files that already existed before the patch.
Apply patch… (from a file)Yes. The files the patch created are deleted.

The details, and when undo refuses, are in Discarding changes and in Undo and redo.

See also

  • Commits: the commit box, Conventional Commits, amend.
  • Stash: saving changes for later, including just one hunk or a few lines.
  • "Don't commit" list: files that are left out of "Stage all changes".
  • Conflicts: what to do with the files in the "Conflicted" section.
  • Blame and File history.