Full stack developer building things to make life a little easier. Huge fan of JavaScript, React, Node.js, and testing my code. • twitter.com/ZakLaughton • zaklaughton.dev
Thanks for pointing this out! These tools are best used for resets to a recent state (within a few days at the most).
From my understanding, the default expiration is 90 days, but the impact is the same: if you have really old changes that you might want to use later, these should probably be reliably saved in a commit somewhere.
If you know ahead of time you want a reliable long-lasting backup of your branch state, you can create a backup branch before making changes.
git checkout my-new-branch
git branch my-new-branch-backup
# now reset, rebase, or otherwise destroy my-new-branch# checkout my-new-branch-backup later to restore
Currently developing futuristic smart-device, IoT connected, highway construction site safety system in EU.
Used to work on infrastructure, application architecture and cloud engineering.
The thing is some tools enable/update/run git GC automatically (and sometimes even without you knowing). That might kill your whole reflog history and any attempts to restore... :(
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Thanks for pointing this out! These tools are best used for resets to a recent state (within a few days at the most).
From my understanding, the default expiration is 90 days, but the impact is the same: if you have really old changes that you might want to use later, these should probably be reliably saved in a commit somewhere.
If you know ahead of time you want a reliable long-lasting backup of your branch state, you can create a backup branch before making changes.
The thing is some tools enable/update/run git GC automatically (and sometimes even without you knowing). That might kill your whole reflog history and any attempts to restore... :(