diff --git a/git_gitlab_course/course.html b/git_gitlab_course/course.html index 25c898fad8bb38af2d446bf8883fe32e7b3fefa6..2e9e38735da488e49d014ab4fa89857f3104b88b 100644 --- a/git_gitlab_course/course.html +++ b/git_gitlab_course/course.html @@ -265,11 +265,68 @@ in 30 Minutes we will start with advanced topics. # Advanced topics +best-practices for commits create branch & merge request create issue & mention it in commit +use SSH key fork & merge back into origin add different remotes -use SSH key + +--- + +# Best practices for commits + +- single purpose +```bash +Improve best practice slide +``` +- short, imperative subject line +```bash +Add best practice slide +``` +- tell why not how +```bash +Make wording on slides consistent +``` + +--- + +# Create branch & merge request + +- create branch +```bash +git checkout -b new-branch +``` +- push +```bash +git push --set-upstream origin new-branch +``` +- merge (on gitlab) + +--- + +# Create issue & mention it in commit + +- create issue on gitlab +- commit local change with `#1` for `1` the issue number +```bash +git commit -m "resolve #1" +``` +- push +- go to the issue on gitlab.com and observe + +--- + +# Use SSH key + +- create SSH key +```bash +ssh-keygen -t rsa -b 4096 -C "florian.moser3@uzh.ch" && eval $(ssh-agent -s) && ssh-add ~/.ssh/id_rsa +``` +- copy `~/.ssh/id_rsa.pub` +- add the public key on gitlab.com +- push/pull to see it works + </textarea> <script type="text/javascript">