Are you about to open-source a private repository? Do you want to squash all history into a single commit before making the code public? This one-liner takes care of it: git reset $(git commit-tree HEAD^{tree} -m 'Initial commit')
-
Show this thread
-
Replying to @mathias
Oh man that may win at golf but requires special syntax that my brain cannot handle maybe
1 reply 0 retweets 1 like -
Replying to @ndm
You don’t have to remember the exact incantation. I just search my shell history for “Initial” to find the command, i.e. Ctrl+R Initial
1 reply 0 retweets 2 likes -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.
JavaScript, HTML, CSS, HTTP, performance, security, Bash, Unicode, i18n, macOS.