3 ms·
For me "Local History" feature in WebStorm solves the issue. https://www.jetbrains.com/help/webstorm/local-history.html https://www.jetbrains.com/help/webstorm
by ankit_mishra 6y ago
For me "Local History" feature in WebStorm solves the issue.
https://www.jetbrains.com/help/webstorm/local-history.html https://www.jetbrains.com/help/webstorm/local-history.html
- jansan 6y agoThis feature is absolutely outstanding, I use it all the time. Unfortunately they buried it in the "File" menu recently. It was so much easier to reach when it was unter "Version Control".
- electrum 6y agoThis is part of the IntelliJ IDEA platform, so all of the JetBrains IDE products have it. I don’t use it often, since I normally rely on Git, but it’s saved me several times after I accidentally deleted a file or made a mistake with Git.
- logicslave 6y agoThis is my most used IntelliJ feature
- wwn_se 6y agoYes love this feature! I also try to get the habit to put in labels more often, it really helps to have some landmarks to navigate from.
- shinycode 6y agoIndeed it’s one of the reasons why I’m staying with JetBrains products. It’s really efficient, we can compare side by side the local history to understand where it went wrong all while keeping the git history clean. Because while I could do the same manually with git, when I’m in the flow thinking about/building/debugging a particular piece of code, moving out to select files to add to git and then filling a message for that piece of code that isn’t working and doing that every few minutes to preserve intermediate state is a nightmare for my productivity. It can and should be done automatically by the IDE to enhance developper productivity by getting out of its mind. There is no reason why I should be thinking about that, isn’t that all the point of using IDE and tools to develop ? Seems like using git for that is still re-inventing the wheel
- timrichard 6y agoI've found Local History on these JetBrains IDEs to be really helpful too. Particularly when combined with "Put Label" command (which I assign to a keyboard shortcut). This lets you insert a descriptive label info the stream of your local history snapshots (such as before you attempt something), so you can go straight to one of those labels and diff against current. Useful when you're trying out an approach with parts that may be discarded, as it's handy for reverting lines of current or overwriting and inserting blocks back from the snapshots. You automatically get a label after certain events, like a test fail or VCS commit. I think there's a snapshot after every save too, and you can configure autosave to happen whenever the editor pane loses focus of you want to. The only things to watch out for with local history in these IDEs is that the snapshots are deleted after five days by default, and all are wiped if you need to delete your IDE cache for any reason.
- matsemann 6y agoIt has even saved me when I managed to delete a file not checked in yet. Just recreate the file with the same name, and then local history is available (or possibly local history on the parent folder would find it as well)
- bennyp101 6y agoI've only recently started using JetBrains tools - and I did not know this feature existed! Thanks for mentioning it - absolutely perfect!