#git

bin+lib gitnu

gitnu indexes your git status so you can use numbers instead of filenames

24 releases (6 breaking)

0.6.0 Jan 25, 2023
0.5.1 Dec 20, 2022
0.5.0 Nov 25, 2022

#1138 in Command line utilities

Download history 28/week @ 2022-11-30 4/week @ 2022-12-07 38/week @ 2022-12-14 19/week @ 2022-12-21 9/week @ 2022-12-28 15/week @ 2023-01-04 15/week @ 2023-01-11 12/week @ 2023-01-18 41/week @ 2023-01-25 8/week @ 2023-02-01 49/week @ 2023-02-08 72/week @ 2023-02-15 35/week @ 2023-02-22 1/week @ 2023-03-01 50/week @ 2023-03-15

86 downloads per month

MIT license

53KB
1.5K SLoC

gitnu

gitnu adds numbers to git status.

build status crates.io

Install

gitnu can be installed by running cargo install gitnu.

Usage

$ gitnu status
# On branch master
# Untracked files:
# 1       .gitignore
# 2       README.md
# 3       doc/
# 4       src/
#
# nothing added to commit but untracked files present

Note the similarity of the output gitnu status to that of git status.
They are identical except for the numbers in front of filenames.

After gitnu status, you can now use numbers in place of filenames for git commands:

$ gitnu add 2
$ gitnu status
# On branch master
# Changes to be committed:
# 1       new file:   README.md
#
# Untracked files:
# 2       .gitignore
# 3       doc/
# 4       src/

In general, whenever you used to do

git <command> [filenames and arguments]

You can now use

gitnu <command> [file numbers and arguments]

gitnu will silently replace numbers with their filenames and pass everything else intact into git.

gitnu accepts multiple arguments and even number ranges:

$ gitnu add 2 5-7 # same as `gitnu add 2 5 6 7`

You can even mix file names with numbers.

Dependencies

~37KB