Skip to content

Source Control / Git

Gridmux includes a built-in Source Control panel backed by the git command-line tool. It gives you the everyday Git workflow — review changes, stage, commit, branch, push/pull, browse history and diffs, and resolve merge conflicts — without leaving the app. It works on the project folder you have open. Local Git is free on every edition; the remote operations (push, pull, fetch, clone, and token storage) are part of Extended.

The Source Control panel is a collapsible section in Gridmux’s side panel. It tracks the project folder you currently have open (the project root): if that folder is a Git repository, its status shows up there. A Source Control indicator in the menu bar opens the related settings (Settings → Source Control), where cloning and token management live.

  • Git must be installed and available on your PATH — Gridmux drives the git CLI under the hood.
  • Remotes must use HTTPS. SSH remotes are not supported (see Limitations).

The panel shows your working tree grouped into staged, unstaged, and untracked files, plus any merge conflicts. It refreshes automatically (polling every few seconds), so it stays current as you work in the terminal.

The header shows the current branch and an ahead/behind indicator relative to the upstream — for commits you have that the remote doesn’t, for commits on the remote you haven’t pulled. Gridmux also fetches in the background (auto-fetch) so the behind count reflects the remote without a manual fetch.

  • Stage or unstage individual files, or discard a file’s changes.
  • Type a message in the commit box and commit your staged changes.

A branch selector shows the current branch and lets you switch to another one. You can also create a new branch and check it out in a single step.

  • Push, pull, and fetch directly from the panel.
  • On your first push of a new branch, Gridmux sets its upstream automatically (origin/<branch>).
  • If your branch is behind the remote when you push, Gridmux warns you and lets you pull first, push anyway, or cancel.
  • A log viewer lists the most recent commits (the last 50). Click a commit to see its diff.
  • Diffs are shown as a color-coded unified diff (added and removed lines) — both for a file’s working changes and for a selected commit. The diff view is read-only.

When a merge leaves conflicts, the panel flags the conflicted files. Opening one shows a side-by-side view of ours and theirs, where you can:

  • Accept Ours, Accept Theirs, or Mark Resolved.
  • Use Manage all when there’s more than one conflict, to work through them in a single overlay (accept ours/theirs for everything, mark all resolved, or abort the merge).

The conflict view is read-only. To merge by hand, edit the file in your editor, then Mark Resolved.

When a repository has many untracked files, you can stage them in bulk instead of one by one — by extension, by glob pattern, by folder, or all except a selection — and add selected files or extensions to .gitignore.

Cloning is done from Settings → Source Control. Paste a repository’s HTTPS URL, choose a parent folder (and, for a private repo, optionally a token), and Gridmux clones it and sets it as your project root. Only HTTPS URLs are supported.

For private repositories over HTTPS, Gridmux uses a Personal Access Token (PAT):

  • A token is stored per repository in your operating system’s keychain (its secure credential store).
  • It is injected only for the individual git command that needs it (through an environment variable) and is never written to your repo’s .git/config.
  • Push and pull prompt for a token when one isn’t stored yet. Pull can also proceed without a token — anonymously, or using your OS credential helper.
  • No SSH remotes — HTTPS only.
  • No graph view — history is shown as a list, not a commit graph.
  • No syntax-highlighted diff — diffs are color-coded unified diffs (added / removed lines).
  • No in-editor conflict resolution — the conflict view is read-only; merge manually in your editor, then mark the file resolved.

A typical end-to-end pass through the panel:

  1. Clone — In Settings → Source Control, paste your repo’s HTTPS URL, pick a parent folder, and clone. Gridmux opens it as your project.
  2. Edit — Make changes in your editor and run commands in the terminal. The Source Control panel updates as files change.
  3. Stage — Stage the files you want to include (individually, or in bulk for untracked files).
  4. Commit — Type a message in the commit box and commit your staged changes.
  5. Push — Push to the remote. The first push on a new branch sets its upstream; if you’re behind, Gridmux offers to pull first.
  6. Conflict — If a pull or merge causes conflicts, the panel flags the affected files.
  7. Resolve — Open a conflict and choose Accept Ours / Accept Theirs, or edit the file in your editor and Mark Resolved. With several conflicts, use Manage all. Then commit the resolution.