Mooring docs

Files and git

Browse a project's files with their git status, see what you've changed, push and pull, and review what a branch changes against its base.

The files pane sits beside the terminal. It shows the files of whatever is selected in the sidebar, the project folder or one of its worktrees, along with their git status. Mooring's tooltips also call it the file viewer.

Show or hide the files pane

Choose View ▸ Show Files, press ⌥⌘1, or click the folder button in the project strip. Do the same again to hide it.

From top to bottom, the pane has:

  • a header with the git counts and the ⋯ menu,
  • the file tree,
  • the Branch section,
  • file info for the selected file.

The file tree

A file with uncommitted changes shows a letter at the end of its row. Point at the letter to see what it means.

  • M modified
  • A added
  • R renamed
  • ? untracked (new, and not yet in git)
  • C in conflict

A file you've deleted isn't on disk, so the tree can't show it. Deleted files are listed in a Changes section above the tree instead.

To work with files:

  • Double-click a folder to open or close it.
  • Double-click a file to open it. Markdown and HTML files can open in a Mooring tab, depending on Settings ▸ Links. Other files open in their usual app. Hold ⌘ as you double-click to always use the usual app.
  • Press Space on a selected file to see it in Quick Look.
  • Drag a file into a terminal tab to insert its path.
  • Show hidden files with View ▸ Show Hidden Files (⇧⌘.) or from the pane's ⋯ menu.

Right-click a file for more:

  • Open in Mooring and Open in Default App, for Markdown and HTML files. Other files and folders have Open.
  • Reveal in Finder
  • Copy Path
  • Quick Look

File info

The bottom of the pane shows the selected file's kind, Size, Created, Modified and Where. To hide it, open the ⋯ menu in the pane's header and turn off Show File Info.

See what you've changed

When there are uncommitted changes, a yellow count shows at the right of the pane's header. Click it to see them:

  • Changes lists the files you've edited, with lines added and removed. Click a file to open its changes in a tab, old and new side by side.
  • Untracked lists new files git doesn't track yet, grouped by folder. Click .gitignore on a row to have git ignore it, or Add all to .gitignore to ignore them all. Press ⌘Z to undo.

Push and pull

The left of the pane's header shows how this branch compares with its remote branch:

  • ↑ and a number: commits you haven't pushed yet.
  • ↓ and a number: commits on the remote that you don't have yet.

Point at a count to see which remote branch it compares with.

To push or pull, open the ⋯ menu in the pane's header:

  • Push sends your commits. It's available when you have commits to push.
  • Pull fetches from the remote and moves your branch forward. It never makes a merge commit. If your branch and the remote have both moved on, the header says Diverged — pull in Terminal, so you can sort it out there.

A short note in the header says how it went, such as Pushed, Pulled or Up to date.

If a push or pull fails, an alert says why and what to do next. For example, there's no saved login, the server refused the login or couldn't be reached, the remote has work you need to pull first, or a pre-push hook stopped the push.

Mooring runs the git on your Mac, so your ~/.gitconfig, hooks and logins all apply. HTTPS remotes use the login your git already has, such as the macOS Keychain or gh auth login. Mooring never asks for your password and never stores one.

The Branch section

The Branch section, below the tree, shows what the selected branch changes compared with its base branch, usually main. It's most useful for a worktree. See Worktrees for how worktrees and their branches work.

To show or hide it, click the panel button in the pane's header (Show Branch pane or Hide Branch pane). Drag its top edge to make it taller or shorter.

When the branch has commits of its own, the section shows:

  • A summary line, for example vs main · 3 ahead · +120 −14 · 6 files. If main has moved on since the branch started, it says by how many commits.
  • A verdict: No conflicts with main, or Would conflict with main and the first file that would conflict. This checks git only. It doesn't run tests or builds.
  • Files and Commits. Files lists each file the branch changes, with lines added and removed. Click one to select it in the tree and open its changes against the base branch in a tab. Commits lists the branch's commits.

To see only the branch's files in the tree, click the filter button in the pane's header (Filter tree to changed-in-branch files). Click it again to show all files.

Where there's no branch to review, for example in the project folder on main, the section lists recent commits instead. Set how many in Settings ▸ Git ▸ Recent commits, from 5 to 100. It is 20 at first.

In any commit list:

  • Point at a commit to see its full message, author and date.
  • Right-click a commit and choose Copy SHA to copy its ID.

If git isn't installed

The files pane still shows your files. Where the Branch section would be, it says what's missing and offers Install Command-Line Tools…, which runs Apple's installer. Mooring carries on by itself when the install finishes.

Settings ▸ Git shows which git Mooring uses, lets you choose another, and has a Test button that checks a project can fetch from and push to its remote. See Settings.