newdevs:git:commands
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
newdevs:git:commands [2023/06/01 11:57] – update branch name from master to main gmcharlton | newdevs:git:commands [2024/03/25 16:35] (current) – tmccanna | ||
---|---|---|---|
Line 1: | Line 1: | ||
**New Developers Working Group** | **New Developers Working Group** | ||
- | ====== Git for Windows ====== | + | ====== |
- | + | ||
- | ===== Useful | + | |
- | + | ||
- | ==== Git Commands | + | |
* '' | * '' | ||
Line 22: | Line 18: | ||
* '' | * '' | ||
* '' | * '' | ||
+ | * '' | ||
* '' | * '' | ||
* '' | * '' | ||
* '' | * '' | ||
* '' | * '' | ||
+ | * '' | ||
* '' | * '' | ||
* '' | * '' | ||
Line 31: | Line 29: | ||
* '' | * '' | ||
* '' | * '' | ||
+ | * '' | ||
+ | * '' | ||
* '' | * '' | ||
+ | * '' | ||
* '' | * '' | ||
* '' | * '' | ||
- | * '' | + | |
+ | * '' | ||
+ | | ||
* '' | * '' | ||
* '' | * '' | ||
Line 42: | Line 45: | ||
* '' | * '' | ||
* '' | * '' | ||
+ | * '' | ||
* '' | * '' | ||
* '' | * '' | ||
* '' | * '' | ||
* | * | ||
- | * '' | + | * '' |
+ | * '' | ||
* '' | * '' | ||
* '' | * '' | ||
Line 70: | Line 75: | ||
==== Squash Commits ==== | ==== Squash Commits ==== | ||
- | If you are in your local working | + | If you have multiple commits |
- | - Verify | + | - Use 'git log' to verify |
- | - Type: '' | + | - Type '' |
- | * Alternatively if your branch is already built on current main, you can use: '' | + | |
- Your text editor will open and should show both of the commits, for example: | - Your text editor will open and should show both of the commits, for example: | ||
* pick 014e59c579 LP#1839359 Select element on login not accessible | * pick 014e59c579 LP#1839359 Select element on login not accessible | ||
* pick 9de92lsi9a LP#1839359 Select element on login not accessible | * pick 9de92lsi9a LP#1839359 Select element on login not accessible | ||
- | - Change the word " | + | - Change the word " |
* squash --> merges commits, then allows amendment of commit message | * squash --> merges commits, then allows amendment of commit message | ||
* fixup --> merges commits like squash does, but discards previous commit message | * fixup --> merges commits like squash does, but discards previous commit message | ||
- | - Push the commit | + | - Use " |
- | * '' | + | - Push the changes up to your remote working directory as normal |
+ | * '' | ||
+ | |||
+ | If you've already pushed multiple | ||
+ | |||
+ | - Follow the steps above, but when pushing, use " | ||
+ | * '' | ||
newdevs/git/commands.txt · Last modified: 2024/03/25 16:35 by tmccanna