Skip to content

johnwesley/thimble

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

thimble

CI

A minimal terminal IDE in Rust. Open a directory, navigate the tree, preview files, see git status at a glance, fuzzy-filter to jump around, press e to drop into $EDITOR on any file.

Roughly the experience of tree + git status + fzf + a lightweight file browser, all in one TUI, in about 1500 lines of Rust.

Install

cargo install --path .

Or, from source:

cargo build --release
./target/release/thimble [PATH]

If PATH is omitted, thimble opens the current directory.

Features

  • Tree navigation, .gitignore aware, with per-file git status glyphs and directory rollups. Drift against main/master is shown live.
  • Preview pane with syntect syntax highlighting, binary detection, and a 2000-line / 512 KB cap on large files.
  • Fuzzy filter (/) and branch picker (b) — both type-to-narrow overlays.
  • Branch checkout uses libgit2's safe strategy, so uncommitted changes are never overwritten; pull (p) shells out to your real git binary, so credential helpers, hooks, pull.rebase, and merge tools all behave exactly as configured.
  • Editor launch (e or Enter) suspends the TUI, runs $EDITOR (falling back to $VISUAL, then vi), and resumes on exit.
  • Delete (d) with confirmation. The overlay surfaces the file's git status, so "tracked — recoverable via git restore" vs. "untracked — gone for good" is visible before you confirm. Symlinks remove the link, never the target.

Keybindings

Normal mode

Key Action
/ k Move selection up
/ j Move selection down
PgUp / PgDn Page up / down
Home / g Jump to top
End / G Jump to bottom
Enter / / l Expand directory, or open file in $EDITOR
/ h Collapse directory, or jump to parent
e Open selected file in $EDITOR
/ Enter filter mode
b Open branch picker (local branches)
d Delete selected file or directory (with confirmation)
p Pull current branch from upstream (git repos only)
i Toggle visibility of gitignored entries (off by default)
r Refresh tree and git status
q / Ctrl+C Quit

Filter mode

Key Action
(type) Append to filter query
Backspace Remove last character
/ Move selection within matches
Enter Open selected file in $EDITOR
Esc Clear filter and return to normal mode

Branch picker

Key Action
(type) Fuzzy-filter branches
Backspace Remove last character
/ Move selection
Enter Checkout selected branch
Esc Close picker without switching

Delete confirmation

Key Action
y / Enter Confirm and delete
n / Esc Cancel

Status glyphs

Glyph Meaning Color
M Modified, unstaged yellow
M Modified, staged green
M (bold) Modified both staged and unstaged yellow-bold
A Added (new, staged) green
? Untracked magenta
D Deleted red
R Renamed blue
I Ignored dim gray
! Conflicted red-bold

Directories show the most severe status of any descendant.

Scope

Read-only browse + preview + $EDITOR shell-out, plus a small set of explicit mutations: branch checkout (libgit2), pull (shells out to git), and single-path delete (file or directory).

Out of scope: in-place editing of file contents, all other git operations (stage, commit, diff, log, stash, push, merge, rebase), filesystem mutations beyond delete (create, rename, move, copy), filesystem watching, and Windows support. Press r after external changes.

License

MIT

About

Terminal IDE written in Rust

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages