commandlinefu.com

Ensure an EOF-newline for every git-tracked text file (that changed since the main branch), except for .meta files (opens in new tab)

git diff --diff-filter=ACMRTUX --name-only main -z | grep -zvE '(.meta)' | xargs -0 dos2unix --add-eol - (Ensure an EOF-newline for every git-tracked text file (that changed since the main branch), except for .meta files Ignores deleted files since main. dos2unix already skips binary files. Safely NUL-delimited. Add -i for a dry run.). The best command line collection on the internet, submit yours and save your favorites.

Read the original article
Sign in to keep reading the full article.

Keyboard Shortcuts

Navigation

Next / previous post
j/k
Open post
oorEnter
Preview post
v

Post Actions

Love post
a
Like post
l
Dislike post
d
Undo reaction
u
Save / unsave
s

Recommendations

Add interest / feed
Enter
Not interested
x

Go to

Home
gh
Interests
gi
Feeds
gf
Likes
gl
History
gy
Changelog
gc
Settings
gs
Discover
gb
Search
/

General

Show this help
?
Submit feedback
!
Close modal / unfocus
Esc

Press ? anytime to show this help