class: center, middle # Collaboration with git & Gitlab --- # Why to use _git_
--- # How to use _git_ - installing - work local - change & track --- # Installing _git_ Download *git* for your operating system from [https://git-scm.com/downloads](https://git-scm.com/downloads) --- # Creating a local repository open your `Git-Bash` create a new directory ```bash mkdir mywebsite ``` change into that directory ```bash cd mywebsite ``` turn this folder into a git repository ```bash git init ``` --- # Checking your local repository you check the status of your repository using ```bash git status ``` which should give you ```bash On branch master No commits yet nothing to commit (create/copy files and use "git add" to track) ``` --- # Change something & commit it In your folder `mywebsite` create a file `helloworld.html` with the conent ```html
Hello World!
``` check how git sees that file ```bash git status ``` which tells you that there are ```bash No commits yet Untracked files: (use "git add
..." to include in what will be committed) helloworld.html nothing added to commit but untracked files present (use "git add" to track) ``` --- # Change something & commit it so let's follow the advice and do ```bash git add helloworld.html ``` and then **commit** this change ```bash git commit -m 'add my first file' ``` you can always check everything you did with ```bash git log ``` ```bash commit 3b5616d1ba962e7a2e4af1f1bdd54f5d65d4e22d (HEAD -> master) Author: Oscan Openness
Date: Sun Jan 12 12:20:28 2020 +0100 add my first file ``` --- # Agenda 1. Introduction 2. Deep-dive 3. ... [NOTE]: This file is portable; you don't need any other file, or an internet connection for this presentation. --- # Introduction