Git workflow improvement CLI tool inspired by Magit. This project is still under initial development, but I am actively dogfooding it and features should be added relatively quickly.
Primarily, this is a personal project since I recently switched to Neovim from Emacs and miss the simplicity and efficiency of using Magit. However, I do have some general aims, which are subject to change:
- Simple - uncluttered UI.
- Intuitive - it should be easy to learn to use gex.
- Cross platform - primary focus on Linux, but should work well on Windows and MacOS.
- Configurable - certain preferences in gex should be configurable to suit your own workflow.
- Comprehensive* - you should be able to use gex to do everything you can do in git.
* gex supports executing arbitrary git commands with : for when something is not yet available
- Magit port
While it serves as a major inspiration, I am not trying to 1:1 port the behaviour and functionality of Magit.
NOTE: You will need Rust on your system for this installation method.
$ cargo install gexGex packages are also maintained by the community in a handful of repositories.
To enter gex simply type gex in console, optionally providing a path.
$ gexFull usage:
$ gex --help
Git workflow improvement CLI tool inspired by Magit
Usage: gex [OPTIONS] [PATH]
Arguments:
[PATH] The path to the repository [default: .]
Options:
-c, --config-file <PATH> Path to a config file to use
-h, --help Print help
-V, --version Print version| Key | Action |
|---|---|
| j / Down | Move down |
| k / Up | Move up |
| J | Jump to next file |
| K | Jump to previous file |
| Tab / Space | Toggle expand |
| g | Go to top |
| G | Go to bottom |
| Key | Action |
|---|---|
| s | stage item |
| S | stage all items |
| u | unstage item |
| U | unstage all items |
| F | pull from remote |
| : | execute git command |
| r | refresh |
| Esc | cancel current |
| q | quit gex |
| Key | Action |
|---|---|
| c | commit |
| b | branch |
| p | push |
| z | stash |
Gex will look for a config file in the following places:
| OS | Path |
|---|---|
| Linux | $XDG_CONFIG_HOME/gex/config.toml |
| MacOS | $HOME/Library/Application Support/gex/config.toml |
| Windows | {FOLDERID_RoamingAppData}/gex/config.toml |
Here is an example config.toml:
[options]
auto_expand_files = false
auto_expand_hunks = true
lookahead_lines = 5
truncate_lines = true # `false` is not recommended - see #37This project is dual-licensed under either:
- MIT License (LICENSE-MIT or http://opensource.org/licenses/MIT)
- Apache License, Version 2.0 (LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0)
at your option.
See CONTRIBUTING.md.
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.