diff --git a/source/snippets/git/index.md b/source/snippets/git/index.md index 994df76..f83076a 100644 --- a/source/snippets/git/index.md +++ b/source/snippets/git/index.md @@ -48,12 +48,21 @@ A stands for All ### Record changes to the repository -Use the given as the commit message. If multiple -m options are given, their values are concatenated as separate paragraphs. +Use the given `` as the commit message. If multiple -m options are given, their values are concatenated as separate paragraphs. ```bash -git commit -m"your commit message" +git commit -m "your commit message" ``` +### Rewrite the most recent commit message + +Did you mess up with your `` and need to update it before pushing it upstream? +```bash +git commit --amend +``` + +Then press **Enter** -> this will open your old message in your default text editor, edit the message, and save the commit. + --- ## Repositories