Skip to content

Instantly share code, notes, and snippets.

View facundop3's full-sized avatar
🚀
Learning ...

Facundo Petre facundop3

🚀
Learning ...
View GitHub Profile
@facundop3
facundop3 / media-query.css
Created June 21, 2018 14:14 — forked from gokulkrishh/media-query.css
CSS Media Queries for Desktop, Tablet, Mobile.
/*
##Device = Desktops
##Screen = 1281px to higher resolution desktops
*/
@media (min-width: 1281px) {
//CSS
@facundop3
facundop3 / gist:71a547feb243385a55adc125f8ff90c9
Created April 12, 2020 21:18 — forked from CrookedNumber/gist:8964442
git: Removing the last commit

Removing the last commit

To remove the last commit from git, you can simply run git reset --hard HEAD^ If you are removing multiple commits from the top, you can run git reset --hard HEAD~2 to remove the last two commits. You can increase the number to remove even more commits.

If you want to "uncommit" the commits, but keep the changes around for reworking, remove the "--hard": git reset HEAD^ which will evict the commits from the branch and from the index, but leave the working tree around.

If you want to save the commits on a new branch name, then run git branch newbranchname before doing the git reset.