Skip to content

Repository files navigation

Izar

Pure Ruby Git staging workspace for safe status, diff, and staging operations.

Gem version Gem downloads CI Ruby 3.2 or newer MIT license

Features · Installation · Quick start · Interactive mode · Configuration · Ruby API


Izar is a pure Ruby Git staging workspace for safe status, diff, and staging operations. It builds on Thuban and Porrima without invoking the git executable.

Features

  • Clear status groups — staged, unstaged, and untracked files stay separate.
  • File and hunk staging — stage or unstage a whole path or the selected hunk.
  • Safe destructive actions — discard requires explicit confirmation.
  • Interactive workspace — terminal and native GUI views share the same model.
  • Fast filtering — narrow large change sets while reviewing.
  • Readable diffs — syntax highlighting with bounded, virtualized rendering.
  • Small Ruby API — inspect and update a repository without shelling out.

Installation

gem install izar

Izar requires Ruby 3.2 or newer.

Quick start

Run Izar inside a Git repository:

izar status
izar stage lib/example.rb
izar unstage lib/example.rb
izar commit -m "Describe the change"

Discard is intentionally gated:

izar discard tmp.txt --yes

Use -C to target another repository and --filter to narrow status output:

izar status -C ../project --filter README

Interactive mode

Launch the terminal workspace or native GUI:

izar status --tui
izar status --gui
Key Action
j / k Move between files
space Toggle the selected file
a Stage all changes
s Toggle the selected hunk
c Commit staged changes
X Confirm and discard the selected file
/ Filter paths
r Reload
? Show help
q Quit

Configuration

Create .izar.jsonc in the repository root:

{
  "theme": "dark",
  "split_ratio": 0.35,
  "keymap": {
    "stage": "space",
    "commit": "c"
  },
  "diff": {
    "context": 3,
    "highlight": true
  }
}

Unknown keys and invalid values fail before input is dispatched.

Ruby API

require "izar"

repository = Izar::Repository.new
repository.status
repository.diff("README.md").staged_to_worktree
repository.stage("README.md")

Development

bundle install
bundle exec rake
bundle exec rbs -I sig validate
gem build --strict izar.gemspec

Contributing

Bug reports and pull requests are welcome on GitHub.

License

Izar is available under the MIT License.

About

Pure Ruby Git staging workspace for safe status, diff, and staging operations

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Sponsor this project

Packages

Contributors

Languages