@phpstorm “Local History” saves my *ss for a second time after I “reset hard” my git repo in the wrong folder containing quite some uncommitted code.

  • Kissaki
    link
    fedilink
    English
    arrow-up
    1
    ·
    8 days ago

    How would you discard all/numerous changes without a hard reset?

    • FizzyOrange
      link
      fedilink
      arrow-up
      1
      ·
      8 days ago

      I normally click the “discard all changes” button in VSCode and it asks me if I am sure. That confirmation dialog has saved me a few times!

      From the command line I’d normally git checkout . and git clean -ffxd. I guess you could say it’s no different to git reset --head HEAD in a sense…