Everywhere All articles Download

Command line and power tools

Locating all your repos

Updated 2026-07-31 · 4 min read

A working developer machine has repos everywhere. Finding the one with uncommitted work before wiping a folder is worth a command.

Find them all

find ~ -type d -name .git -prune 2>/dev/null | sed 's|/.git$||'

-prune stops descent into a repo once found — fast, and it avoids matching nested .git inside dependencies.

With fd:

fd -H -t d '^\.git$' ~ | sed 's|/.git$||'

Bulk status: find the dirty ones

The genuinely useful query — repos with uncommitted or unpushed work, before you delete or archive anything:

find ~ -type d -name .git -prune 2>/dev/null | while read g; do
  d=$(dirname "$g")
  s=$(git -C "$d" status --porcelain)
  [ -n "$s" ] && echo "DIRTY: $d"
done

Extend it to catch unpushed commits:

git -C "$d" log --branches --not --remotes --oneline | grep -q . && echo "UNPUSHED: $d"

Size audit

Repos accumulate — .git history plus build output:

find ~ -type d -name .git -prune 2>/dev/null | while read g; do
  du -sh "$(dirname "$g")"
done | sort -hr | head -20

Abandoned repos

find ~ -type d -name .git -prune 2>/dev/null | while read g; do
  d=$(dirname "$g")
  last=$(git -C "$d" log -1 --format=%cr 2>/dev/null)
  echo "$last -- $d"
done

The "2 years ago" entries are archive-or-delete candidates — after the dirty/unpushed check clears them.

Why search tools miss repos

.git internals are on Spotlight's exclusion list (thousands of objects that would swamp results), which is correct — but it means locating repos is a Terminal job, or a job for an index that includes them but demotes them below your actual source.

Common questions

How do I find all Git repositories on my Mac?

find ~ -type d -name .git -prune then strip the /.git suffix. -prune keeps it fast and avoids nested matches.

How do I find repos with uncommitted changes?

Loop the found repos through git status --porcelain; non-empty output means dirty.

Find any file before you finish typing

Everywhere keeps track of every file on your Mac — including the folders Spotlight hides and drives you have unplugged. Free for a day, then $19 once.

Download for Mac

Related

© 2026 Caretopia Network Private Limited Everywhere for Mac Articles Privacy Support