Remove Files From Staging Before CommittingShailesh Kumar Sundram·Jun 14, 2023·1 min readSay you have added main.js to the staging area but later you realised that you don't want to commit it. You have two ways to achieve it. The old way git reset HEAD main.js The new way git restore --staged main.js Gittips