Why git can’t do hard/soft resets by path?

Because there’s no point (other commands provide that functionality already), and it reduces the potential for doing the wrong thing by accident.

A “hard reset” for a path is just done with git checkout HEAD -- <path> (checking out the existing version of the file).

A soft reset for a path doesn’t make sense.

A mixed reset for a path is what git reset -- <path> does.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)