Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

git-reset: add page #1088

Merged
merged 1 commit into from
Sep 26, 2016
Merged

git-reset: add page #1088

merged 1 commit into from
Sep 26, 2016

Conversation

eliotsykes
Copy link
Contributor

No description provided.

@CLAassistant
Copy link

CLAassistant commented Sep 24, 2016

CLA assistant check
All committers have signed the CLA.


`git reset HEAD~1`

- Undo last commit and permanently delete the changes:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe mention that staged changes are also discarded.


> Undo commits. Reset current HEAD to the specified state.

- Undo last commit, keep the changes:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just to be clearer about where the changes are kept, I'd be explicit and say "keep the changes in the filesystem".

@@ -0,0 +1,11 @@
# git reset

> Undo commits. Reset current HEAD to the specified state.
Copy link
Member

@waldyrious waldyrious Sep 24, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Git reset has two common uses: undoing commits, and unstaging changes. Both should be mentioned in the description.

I'd suggest "Undo commits or unstage changes, by resetting the current git HEAD to the specified state."

@waldyrious
Copy link
Member

Very nice and useful command :) please take a look at the inline comments.

I plan to make a PR adding the git-reset commands for unstaging changes, from notes I have collected elsewhere, so don't worry about adding those in :)

@waldyrious waldyrious added the new command Issues requesting creation of a new page. label Sep 24, 2016
@eliotsykes
Copy link
Contributor Author

Improvements made - really appreciate the feedback @waldyrious, thank you :-)

@waldyrious
Copy link
Member

waldyrious commented Sep 26, 2016

Happy to help, @eliotsykes :) I think the page is good to merge as-is :shipit:

I'll propose further changes soon, to incorporate the unstaging behavior.

@agnivade
Copy link
Member

👍

@agnivade agnivade merged commit 26700bf into tldr-pages:master Sep 26, 2016
@leostera leostera mentioned this pull request Oct 6, 2016
waldyrious added a commit that referenced this pull request Oct 24, 2016
waldyrious added a commit that referenced this pull request Oct 27, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
new command Issues requesting creation of a new page.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants