Skip to content

Instantly share code, notes, and snippets.

@fitzy1321
Last active April 24, 2024 17:51
Show Gist options
  • Save fitzy1321/51a1670a64e4f4714ffcae00b54adafc to your computer and use it in GitHub Desktop.
Save fitzy1321/51a1670a64e4f4714ffcae00b54adafc to your computer and use it in GitHub Desktop.
Exclude files from git diff

How to exclude files from git diff

# fish shell
set _git_ignore_list "':!/*Cargo.lock' ':!/*deno.lock' ':!/*package-lock.json' ':!/*poetry.lock' ':!/*yarn.lock'"
# fish abbreviation gdnl, stands for "git diff no lock"
abbr -a gdnl git diff -- $_git_ignore_list
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment