Add git alias gshn
(git show --name-only
)
#2219
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Adds a short Git alias for
git show --name-only
, which list the files affected by the changes only (instead of the full diff).Description
The Git command
git show --name-only
list only the files affected by the changes instead of showing the full diff, which comes in handy when you need to know which files were affected w/o being distracted by the full diff of the changes.The additional
git show --name-status
shows the current version control status of the listed files. (Maybe interesting to note, this is like a light version ofgit whatchanged -1
.)Motivation and Context
Just two convenient aliases in addition to
gsh
(git show
) to avoid the need for typing and remembering the lengthy--name-only
and--name-status
options.How Has This Been Tested?
I tried it out locally, applied the identical change to my local Bash-it setup.
Verified that there are no alias conflicts by grepping for "gsh" over the repository HEAD.
Types of changes
Checklist:
clean_files.txt
and formatted it usinglint_clean_files.sh
.