makandra Curriculum

Understand the differences between git diff and git diff --staged (or git diff --cached) Understand the difference between git reset and git reset --hard Use git add -p

...git checkout -p Note you can also rollback partial changes from the line gutter in RubyMine. Use git rebase -i Understand what it means for pushing to a remote, and...

makandra Curriculum

Git is our version control system. Goals Understand why we use git. Learn how to work with your local repository: Create a local repository (git init) Commit changes (git add...

See the history (git log) See changes (git diff) Work with branches Create new ones: git switch --create or git checkout -b. Switch to existing branches: git switch...

makandra Curriculum

...code before committing. Never commit a debugging breakpoint. You can achieve this by using git add -p and following the guidelines from the referred card above. If you are debugging...

...should be in a habit of reviewing your code before committing (e.g. by using git add -p). Never commit a debugging breakpoint. Debugging in Cucumber scenarios If you haven't...

...RubyMine. Skip any instructions for cloud IDEs. We will not upload our code to GitHub. Push your code to our private GitLab instance instead. We are developing on Linux. Skip...

...When you're done with this exercises, discard all changes of the last exercise: git reset --hard

makandra Curriculum

...the purpose of: Feature branches Code reviews Commit squashing (and the resulting traceability through git blame) Our Merge request checklist Read the card Before you make a merge request: Checklist...

Tip If no merge request option can be found, check in your GitLab settings (general > visibility) if the slider "Merge requests" is activated. If not, do so.

makandra Curriculum

...Persist your choice in the $EDITOR variable. It defines the default for commands like git commit: # Example with vim # open the configuration file vim ~/.bashrc # navigate to the end of...

Best results in other decks

...pushed when saying git push. Our recommendation is to set it to current. From the git-config documentation: push.default Defines the action git push should take if no refspec is...

...check your setting, do the following. By default, it will return matching (see above). $ git config --global push.default matching So to change that to push only current branches, just go...

makandra dev

git checkout is the swiss army of git commands. If you prefer a semantically more meaningful command for restoring tasks, use git restore instead. With this command you...

Info For this use case you can also use git checkout. Sources Git - git-restore Documentation Also see Git commands to discard changes Git restore vs reset

Search in all decks