Advanced Operating Systems Control Versioning with GIT. Giuseppe Massari
|
|
- Patrick Ellis
- 5 years ago
- Views:
Transcription
1 Control Versioning with GIT Giuseppe Massari
2 Outline 2/54 Why using version control tools? Why Git? First steps Getting help and configuration Basic concepts Local repository management Initialization Change management Branches Conflicts management Shared remote repository management Pushing and pulling changes Giuseppe Massari
3 Why using version control tools? 3/54 Single developer Do we need to keep track of the history of changes in a software project? How to effectively keep track of / store such changes? Copying sources into new directories (e.g., MyProject_v _...)? What about disk occupancy? Multiple developers How to merge changes and additions coming from other developers? Manual copy and paste for each changed file? How to keep track of who's the author of a change? Mmm... maybe looking for mails with source code attached? Giuseppe Massari
4 Why Git? 4/54 Distributed approach The entire project history database is local Faster browsing among the changes No traffic generated on the network Changes can be committed locally before sharing Higher reliability: Central server DOWN is not an issue! Integrity mechanisms Every change is tracked SHA 1 checksum 40 character string composed of hexadecimal characters calculated based on the contents of a file or directory structure in Git. Giuseppe Massari
5 First steps 5/54 Help The command line usage of Git is based on commands To get help about a specific command syntax $ git git help help [command] If no command is given an overview of the most common Git commands is returned usage: usage: git git [--version] [--version] [--help] [--help] [-C [-C <path>] <path>] [-c [-c name=value] name=value] [--exec-path[=<path>]] [--exec-path[=<path>]] [--html-path] [--html-path] [--man-path] [--man-path] [--info-path] [--info-path] [-p --paginate --no-pager] [-p --paginate --no-pager] [--no-replace-objects] [--no-replace-objects] [--bare] [--bare] [--git-dir=<path>] [--git-dir=<path>] [--work-tree=<path>] [--work-tree=<path>] [--namespace=<name>] [--namespace=<name>] <command> <command> [<args>] [<args>] The The most most commonly commonly used used git git commands commands are: are: add add Add Add file file contents contents to to the the index index bisect bisect Find Find by by binary binary search search the the change change that that introduced introduced a a bug bug branch branch List, List, create, create, or or delete delete branches branches checkout checkout Checkout Checkout a a branch branch or or paths paths to to the the working working tree tree clone clone Clone Clone a a repository repository into into a a new new directory directory commit commit Record Record changes changes to to the the repository repository......
6 First steps 6/54 Configuration Setup user name, mail and preferences... $ git git config <level> <option> value Configuration levels reference three possible configuration files --system /etc/gitconfig System wide scope --global ~/.gitconfig ~/.config/git.git/config First configuration steps User scope Local project scope $ git git config --global user.name "Giuseppe Massari" $ git git config --global user. giuseppe.massari@polimi.it
7 First steps 7/54 Basic concepts Repository Concretely, (sub)directory where in Git stores metadata and object database for the project (.git) Repository (.git directory) Working directory A checkout of one version of the project The tracked files pulled out of the compressed database in the.git directory Working directory Staging area The set of selected changes, ready to be committed In practice, a file ( INDEX ) contained in.git directory, storing information about the changes to track in the forthcoming next commit Staging Area Giuseppe Massari
8 First steps 8/54 Basic workflow Working directory Staging Area Repository (.git directory) Checkout a project branch Stage changes Commit changes
9 Local repository management 9/54 Your first Git repository Enter the new project directory Initialize the Git repository $ $ cd cd ~/Development/MyProject ~/Development/MyProject $ $ git git init init Initialized Initialized empty empty Git Git repository repository in in ~/Development/MyProject/.git/ ~/Development/MyProject/.git/ This will create the.git directory. From now on, you can track changes in our project committing them in the Git repository ~/Development/MyProject/ ~/Development/MyProject/.git.git branches branches config config description description HEAD HEAD hooks hooks info info objects objects refs refs All the magics behind Git is here
10 Local repository management 10/54 Your first Git repository Create some files and do you first commit $ $ touch touch main.cpp main.cpp $ $ git git add add main.cpp main.cpp $ $ git git commit commit -s -s Now we have the very first step of our project history $ $ git git log log commit commit 8c837e5e223ee55bb9c9d1818fca67b8a365e94a 8c837e5e223ee55bb9c9d1818fca67b8a365e94a Author: Author: Giuseppe Giuseppe Massari Massari <joe.massanga@gmail.com> <joe.massanga@gmail.com> Date: Date: Fri Fri Oct Oct :59:53 13:59: Initial Initial commit commit Signed-off-by: Signed-off-by: Giuseppe Giuseppe Massari Massari <joe.massanga@gmail.com> <joe.massanga@gmail.com>
11 Local repository management 11/54 Diff As we continue introducing changes we can list them for each file If no files are specified all the changes for each file are shown $ $ git git diff diff [file-name] [file-name] diff diff --git --git a/main.cpp a/main.cpp b/main.cpp b/main.cpp index index e69de29..d9d9396 e69de29..d9d a/main.cpp a/main.cpp ,0-0,0 +#include +#include <iostream> <iostream> + + +int +int main(int main(int argc, argc, const const char char *argv[]) *argv[]) +{ +{ + + std::cout std::cout << << "Hello, "Hello, GIT GIT World!" World!" << << std::endl; std::endl; return return 0; 0; +} +} + +
12 Local repository management 12/54 Status After performing some changes we may want to have an overview of the project status The command status recaps the status of the working directory and the staging area $ $ git git status status On On branch branch master master Changes Changes to to be be committed: committed: (use (use "git "git reset reset HEAD HEAD <file>..." <file>..." to to unstage) unstage) new new file: file: main.h main.h Staging area Changes Changes not not staged staged for for commit: commit: (use (use "git "git add add <file>..." <file>..." to to update update what what will will be be committed) committed) (use (use "git "git checkout checkout <file>..." <file>..." to to discard discard changes changes in in working working directory) directory) modified: modified: main.cpp main.cpp Untracked Untracked files: files: (use (use "git "git add add <file>..." <file>..." to to include include in in what what will will be be committed) committed) README README
13 Local repository management 13/54 Commit What it is? A tracked change in the project: new files or changes in already existing files When to do it? Whenever we consider the changes introduced as a stable part of the project development What TO commit? Whatever can be considered a source file What TO DO NOT commit? Whatever is generated from source files How to commit? Add files or changes in files to staging area and then commit $ git git add add <files> <files> $ git git commit commit......
14 Local repository management 14/54 How to write a good commit? A tag/label to easily identify the project module touched A brief title to summarize the changes introduced [Model] [Model] Power-thermal models models support support The The purpose purpose of of this this support support is is to to providing providing a well-defined interface interface to to power/thermal resource resource allocation allocation policy, policy, hiding hiding platform platform specific specific details. details. A ModelManager allows allows the the registration registration of of platform-specific models, models, according according to to the the target target platform platform selected. selected. Such Such models models are are implemented as as derived derived classes classes of of the the base base class class Model. Model. Signed-off-by: Giuseppe Giuseppe Massari Massari <giuseppe.massari@polimi.it> Author's signature (git commit -s) An exhaustive explanation of what has been done and why
15 Local repository management 15/54 How to write a good commit? Include only consistent changes! A single source file can include changes having different goals Bug fixing Code refactoring New functionality implemented Use git gui to be more productive! $ git git gui gui Select lines (also from different files) changed for the same single specific purpose Right click on changed lines Select Stage lines for commit Giuseppe Massari
16 Local repository management 16/54 Log To recap the history of the project development $ git git log log commit commit 7bb21c be82d391ad9d03d5d bb21c be82d391ad9d03d5d Author: Author: Giuseppe Giuseppe Massari Massari <joe.massanga@gmail.com> <joe.massanga@gmail.com> Date: Date: Mon Mon Oct Oct :06:25 18:06: [Main] [Main] Using Using a a People People object object Added Added an an instance instance of of People People object object (joe), (joe), walking walking and and greeting. greeting. Signed-off-by: Signed-off-by: Giuseppe Giuseppe Massari Massari <joe.massanga@gmail.com> <joe.massanga@gmail.com> commit commit db36e150b2839fd923b3ca71186b22fe db36e150b2839fd923b3ca71186b22fe6 Author: Author: Giuseppe Giuseppe Massari Massari <joe.massanga@gmail.com> <joe.massanga@gmail.com> Date: Date: Mon Mon Oct Oct :03:08 18:03: [People] [People] Class Class first first version version Including Including member member functions functions Walk() Walk() and and Greet(). Greet(). Signed-off-by: Signed-off-by: Giuseppe Giuseppe Massari Massari <joe.massanga@gmail.com> <joe.massanga@gmail.com>
17 Local repository management 17/54 Show To show commit details (description + changes) $ git git show show [SHA1_number] giuseppe@plutone:~/development/test/gittutorial$ git show 5552cef giuseppe@plutone:~/development/test/gittutorial$ git show 5552cef commit 5552cefd12be253fd10c50cd03b64525eb0217f5 commit 5552cefd12be253fd10c50cd03b64525eb0217f5 Author: Giuseppe Massari <joe.massanga@gmail.com> Author: Giuseppe Massari <joe.massanga@gmail.com> Date: Mon Oct 19 17:20: Date: Mon Oct 19 17:20: [Main] First implementation [Main] First implementation The main function now prints a message. The main function now prints a message. Signed-off-by: Giuseppe Massari <joe.massanga@gmail.com> Signed-off-by: Giuseppe Massari <joe.massanga@gmail.com> diff --git a/main.cpp b/main.cpp diff --git a/main.cpp b/main.cpp index e69de29..d9d index e69de29..d9d a/main.cpp --- a/main.cpp +++ b/main.cpp ,0 +#include <iostream> +#include <iostream> + + +int main(int argc, const char *argv[]) +int main(int argc, const char *argv[]) +{ +{ + std::cout << "Hello, GIT World!" << std::endl; + std::cout << "Hello, GIT World!" << std::endl; return 0; + return 0; +} +} + +
18 Local repository management 18/54 Graphical front ends $ gitk gitk --all --all
19 Local repository management 19/54 Basic work flow in commands Working directory Staging Area Repository (.git directory) Do changes... git diff git status git show git add... git init git commit... Repeat...
20 Local repository management 20/54 Undo commands How to unstage changes already added to the staging area? $ git git checkout checkout filename filename Working directory Staging Area git add file git checkout file Just a step back, without cleaning the changes in the sources Giuseppe Massari
21 Local repository management 21/54 Undo commands How to clean out unstaged changes? Clean out all the (unstaged/uncommited) changes in the tracked files $ git git reset reset --hard --hard How to correct a commit? $ git git commit commit --amend --amend Open the current commit and allows us to add/remove files/lines or modify the commit message It overwrites the commit, creating a new one (with a different SHA 1) Not recommended if the commit has been already pushed on the remote repository $ git git revert revert SHA-1_number Revert the changes of the specified commit Added lines become removed lines and viceversa... Giuseppe Massari
22 Local repository management 22/54 Branches In real projects, the development history is far from progressing on a straight line Split developers to work in parallel, each focusing on specific features Software versions targeting different versions following different paths The concept of branch is all about this By default the Git repository initialization creates the master branch Giuseppe Massari
23 Local repository management 23/54 Branches Creating (and switching to) a new branch $ git git checkout checkout -b -b dev dev master ee2e90... HEAD HEAD is basically a d45e26... Initial commit reference to the topmost commit on the current branch master
24 Local repository management 24/54 Branches Creating (and switching to) a new branch $ git git checkout checkout -b -b dev dev Command checkout action is different in case the argument is a branch, instead of a file name master ee2e90... d45e26... dev The new dev branch points to the same topmost master commit Initial commit master dev Giuseppe Massari
25 Local repository management 25/54 Branches Committing on top of a new branch $ git git commit commit c82dda... dev master ee2e90... d45e26... The dev branch starts growing Initial commit master dev Giuseppe Massari
26 Local repository management 26/54 Branches Committing on top of a new branch $ git git commit commit a157dc... dev c82dda... master ee2e90... d45e26... Initial commit The project history is slowly starting to show a tree shape master dev Giuseppe Massari
27 Local repository management 27/54 Branches Switching back to master branch $ git git checkout checkout master master a157dc... dev c82dda... master ee2e90... d45e26... Initial commit Once back to master the changes introduced in the last dev commits apparently disappear master dev Giuseppe Massari
28 Local repository management 28/54 Branches Merging master and dev branches $ git git merge merge dev dev master a157dc... dev c82dda... ee2e90... d45e26... Initial commit Now, if we switch between master and dev we would not see changes in the project master dev Giuseppe Massari
29 Local repository management 29/54 Branches Labels on commits $ git git tag tag -a -a v0.1 v0.1 a157dc a157dc master a157dc... dev v0.1 c82dda... ee2e90... d45e26... Initial commit The tag can be thought as a label to mark our releases and improve the git tree readability master dev Giuseppe Massari
30 Local repository management 30/54 Conflicts In some cases, merging branches may lead to conflicts $ git git merge merge dev dev CONFLICT CONFLICT (content): (content): Merge Merge conflict conflict in in main.cpp main.cpp Automatic Automatic merge merge failed; failed; fix fix conflicts conflicts and and then then commit commit the the result. result. dev master 479b... ee2e90... d45e26... a157dc... c82dda... Master and dev branches include commits that touched the same lines of the same file Initial commit master dev
31 Local repository management 31/54 Conflicts The status command reports the conflict in this way $ git git status status dev dev On On branch branch master master You You have have unmerged unmerged paths. paths. (fix (fix conflicts conflicts and and run run "git "git commit") commit") Unmerged Unmerged paths: paths: (use (use "git "git add add <file>..." <file>..." to to mark mark resolution) resolution) both both modified: modified: main.cpp main.cpp To solve the conflict the conflict we need to open the files involved and check the content Git automatically add special lines into the file to identify the conflict and help us
32 Local repository management 32/54 Conflicts main.cpp is the file containing the conflict 7 7 <<<<<<< <<<<<<< HEAD HEAD 8 std::cout std::cout << << "Hello, "Hello, walking walking man!" man!" << << std::endl; std::endl; 9 ======= ======= >>>>>>> >>>>>>> dev dev Lines 7 9: HEAD status, changes in commit on top of current branch (master) Lines 9 10: changes coming from the merging branch (dev) Resolution Make a choice about the lines to keep or deleted, remove Delete special lines <<<<...===...>>> Add the files to the staging area (INDEX) Commit
33 Local repository management 33/54 Rebasing Move a branch on top of another May lead to conflicts Do it as long as your are moving a local branch $ $ git git rebase rebase master master dev dev dev a157dc... a157dc... dev c82dda... master ee2e90... c82dda... master ee2e90... d45e26... d45e Giuseppe Massari
34 Local repository management 34/54 Stashing Temporarily hide current (uncommited) changes on a stack Useful in case of switching on a branch already including changes on files we currently working on... $ $ git git stash stash save save Changes Changes about about feature1 feature1 implementation implementation I can stack multiple stashed changes $ $ git git stash stash list list To discard stashed changes: $ $ git git stash stash drop drop stash@{n} stash@{n} To resume the stashed changes: $ $ git git stash stash pop pop [stash@{n}] [stash@{n}] Giuseppe Massari
35 Local repository management 35/54 Basic work flow in commands Working directory Staging Area Repository (.git directory) git init Do changes... git diff git status git show git checkout <branch_name> git add... git commit...
36 Local repository management 36/54 Work flow example To manage the software release cycles, we can design a work flow, by splitting bug fixing, feature development and release candidate versions in dedicated branches Giuseppe Massari
37 Outline 37/54 Why using version control tools? Why Git? First steps Getting help and configuration Basic concepts Local repository management Initialization Change management Branches Conflicts management Shared remote repository management Pushing and pulling changes Giuseppe Massari
38 Remote repository management 38/54 Cooperative development Several developers working on the same project Project Joe Simon Fred Giuseppe Massari
39 Remote repository management 39/54 Remote repository work flow Working directory Staging Area Local repository Remote repository git clone... git checkout <branch_name> git add... git commit... git push... git fetch/pull...
40 Remote repository management 40/54 Basic commands To clone a project (remote repository) $ git git clone clone repository_path To download all the changes from the remote repository New commits, new branches, new tags... $ git git fetch fetch repository_name To download changes and merge it in the current local branch Fetch + merge $ git git pull pull repository_name [branch_name] To upload local changes to remote repository $ git git push push repository_name [branch_name] Giuseppe Massari
41 Remote repository management 41/54 Cooperative development Joe Simon Fred
42 Remote repository management 42/54 Cooperative development Joe starts a project tracking changes on a local repository Joe Simon Fred [Joe]$ [Joe]$ git git init init [Joe]$ [Joe]$ git git add add [Joe]$ [Joe]$ git git commit commit
43 Remote repository management 43/54 Cooperative development Joe adds a remote repository to the project Git server git@myserver.org:joe/myproj.git (origin) Joe Simon Fred [Joe]$ [Joe]$ git git remote remote add add origin origin git@myserver.org:joe/myproj.git
44 Remote repository management 44/54 Cooperative development Joe shares its work by uploading its current git tree to the remote repository Git server (origin) Joe Simon Fred [Joe]$ [Joe]$ git git push push -u -u --all --all origin origin Giuseppe Massari
45 Remote repository management 45/54 Cooperative development Simon and Fred clone the remote git repository, so that they can contribute to the project Git server (origin) Joe Simon Fred [Simon]$ [Simon]$ git git clone clone [Fred]$ [Fred]$ git git clone clone
46 Remote repository management 46/54 Cooperative development Simon fix bugs, committing changes on a new branch (hotfix) Git server git@myserver.org:joe/myproj.git (origin) HEAD HEAD HEAD Joe Simon Fred [Simon]$ [Simon]$ git git checkout checkout -b -b hotfix hotfix [Simon]$ [Simon]$ git git commit commit......
47 Remote repository management 47/54 Cooperative development Fred implements a new feature, committing changes on a new branch (feature1) Git server git@myserver.org:joe/myproj.git (origin) HEAD HEAD HEAD Joe Simon Fred [Fred]$ [Fred]$ git git checkout checkout -b -b feature1 feature1 [Fred]$ [Fred]$ git git commit commit......
48 Remote repository management 48/54 Cooperative development Fred and Simon upload their changes (branches) Git server (origin) HEAD HEAD HEAD Joe Simon Fred [Fred]$ [Fred]$ git git push push origin origin feature1 feature1 [Simon]$ [Simon]$ git git push push origin origin hotfix hotfix
49 Remote repository management 49/54 Cooperative development Joe updates its local repository Git server (origin) HEAD HEAD HEAD Joe Simon Fred [Joe]$ [Joe]$ git git fetch fetch origin origin Giuseppe Massari
50 Remote repository management 50/54 Cooperative development Joe merge the contributions in the project main line (i.e., master) Git server (origin) HEAD HEAD HEAD Joe Simon Fred [Joe]$ [Joe]$ git git merge merge origin/feature1 [Joe]$ [Joe]$ git git merge merge origin/hotfix
51 Remote repository management 51/54 Cooperative development Joe uploads the (updated) master branch to the remote repository Git server (origin) HEAD HEAD HEAD Joe Simon Fred [Joe]$ [Joe]$ git git push push origin origin master master Giuseppe Massari
52 Remote repository management 52/54 Cooperative development Simon and Fred synchronize their local repository with the remote Git server (origin) HEAD HEAD HEAD Joe Simon Fred [Fred]$ [Fred]$ git git fetch fetch origin origin [Simon]$ [Simon]$ git git fetch fetch origin origin
53 Remote repository management 53/54 Cooperative development Simon and Fred get the updated master Git server (origin) HEAD HEAD HEAD Joe Simon Fred [Fred/Simon]$ git git checkout master master [Fred/Simon]$ git git pull pull origin origin master master
54 Questions? 54/54
Git Magic: Versioning Files Like a Boss. Tommy MacWilliam
Git Magic: Versioning Files Like a Boss Tommy MacWilliam tmacwilliam@cs50.net Today setting up like a boss basic git like a boss using branches like a boss reverting changes like a boss collaborating like
More informationgit commit --amend git rebase <base> git reflog git checkout -b Create and check out a new branch named <branch>. Drop the -b
Git Cheat Sheet Git Basics Rewriting Git History git init Create empty Git repo in specified directory. Run with no arguments to initialize the current directory as a git repository. git commit
More informationGit. Presenter: Haotao (Eric) Lai Contact:
Git Presenter: Haotao (Eric) Lai Contact: haotao.lai@gmail.com 1 Acknowledge images with white background is from the following link: http://marklodato.github.io/visual-git-guide/index-en.html images with
More informationGIT Princípy tvorby softvéru, FMFI UK Jana Kostičová,
GIT Princípy tvorby softvéru, FMFI UK Jana Kostičová, 25.4.2016 Basic features Distributed version control Developed in 2005, originally for Linux kernel development Free, GNU General Public License version
More informationSubmitting your Work using GIT
Submitting your Work using GIT You will be using the git distributed source control system in order to manage and submit your assignments. Why? allows you to take snapshots of your project at safe points
More informationIntroduction to Supercomputing
Introduction to Supercomputing TMA4280 Introduction to development tools 0.1 Development tools During this course, only the make tool, compilers, and the GIT tool will be used for the sake of simplicity:
More informationCS 390 Software Engineering Lecture 4 - Git
CS 390 Software Engineering Lecture 4 - Git Reference: Scott Chacon and Ben Straub, Pro Git, published by Apress, available at https://git-scm.com/book/en/v2. Outline Git terminology Git configuration
More informationCS 390 Software Engineering Lecture 5 More Git
CS 390 Software Engineering Lecture 5 More Git Reference: Scott Chacon and Ben Straub, Pro Git, published by Apress, available at https://git-scm.com/book/en/v2. Outline Finish local repository Remote
More informationComputer Science Design I Version Control with Git
Computer Science Design I Version Control with Git Department of Electrical Engineering & Computer Science Information Technology & Telecommunications Research Center The University of Kansas annguyen@ittc.ku.edu
More informationIndex. Alias syntax, 31 Author and commit attributes, 334
Index A Alias syntax, 31 Author and commit attributes, 334 B Bare repository, 19 Binary conflict creating conflicting changes, 218 during merging, 219 during rebasing, 221 Branches backup, 140 clone-with-branches
More informationGIT DISTRIBUTED IS THE NEW CENTRALISED
GIT DISTRIBUTED IS THE NEW CENTRALISED BEGINNER WORKSHOP FETCH YOURSELF LAPTOP INSTALLING linux: sudo apt-get install git linux: sudo yum install git osx: brew install git osx: macports install git windows:
More informationVersion Control System - Git. zswu
Version Control System - Git zswu Overview Why VCS? Why Git? Using Git Personally Using Git with Others Etiquette Rules of Using Git Tools & Services Tips 2 Why VCS (1/3) How do you manage your homework?
More information1/20/13 Git tutorial. Git tutorial. Mike Nolta. file:///users/nolta/github/reveal.js/git.html?print-paper#/ 1/31
Git tutorial Mike Nolta file:///users/nolta/github/reveal.js/git.html?print-paper#/ 1/31 1. Basics file:///users/nolta/github/reveal.js/git.html?print-paper#/ 2/31 Tell git who you are $ git config --global
More informationIntroduction to distributed version control with git
Institut für theoretische Physik TU Clausthal 04.03.2013 Inhalt 1 Basics Differences to Subversion Translation of commands 2 Config Create and clone States and workflow Remote repos Branching and merging
More informationCommon Git Commands. Git Crash Course. Teon Banek April 7, Teon Banek (TakeLab) Common Git Commands TakeLab 1 / 18
Common Git Commands Git Crash Course Teon Banek theongugl@gmail.com April 7, 2016 Teon Banek (TakeLab) Common Git Commands TakeLab 1 / 18 Outline 1 Introduction About Git Setup 2 Basic Usage Trees Branches
More informationVersion Control with GIT
Version Control with GIT Benjamin Roth CIS LMU München Benjamin Roth (CIS LMU München) Version Control with GIT 1 / 30 Version Control Version control [...] is the management of changes to documents, computer
More informationGit Guide. Meher Krishna Patel. Created on : Octorber, 2017 Last updated : October, More documents are freely available at PythonDSP
Git Guide Meher Krishna Patel Created on : Octorber, 2017 Last updated : October, 2018 More documents are freely available at PythonDSP Table of contents Table of contents i 1 Commands Summary 1 2 Git
More information! #Running this command from the top directory of your project will add all your changes."! $ git add."
********************************* ********************************* ** ** ** Git Toolkit ** ** ** ********************************* ********************************* +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
More informationLPF Training Handbook!
LPF Training Handbook M Hewitson 2014-04-25 1. Introduction 1 2. Software setup 1 Accessing the relevant software repositories 2 Getting the software 3 Installing LTPDA 3 Installation of Extension modules
More informationDistributed Version Control (with Git)
Distributed Version Control (with Git) Introduction and Tutorial fhlug 24. 03. 2011 Why Distributed? No single point of failure Automatic backups Fast local operations (log, diff, checkout, ) Authenticity
More informationGit. A Distributed Version Control System. Carlos García Campos
Git A Distributed Version Control System Carlos García Campos carlosgc@gnome.org Carlos García Campos carlosgc@gnome.org - Git 1 A couple of Quotes For the first 10 years of kernel maintenance, we literally
More informationBeyond git add/commit/push
add Working dir commit Staging area push Local Remote Based on original version made by Alexis López @aa_lopez About us @tuxtor @edivargas jorgevargas.mx github.com/tuxtor Review traditionals commands
More informationOutline The three W s Overview of gits structure Using git Final stuff. Git. A fast distributed revision control system
Git A fast distributed revision control system Nils Moschüring PhD Student (LMU) 1 The three W s What? Why? Workflow and nomenclature 2 Overview of gits structure Structure Branches 3 Using git Setting
More informationFundamentals of Git 1
Fundamentals of Git 1 Outline History of Git Distributed V.S Centralized Version Control Getting started Branching and Merging Working with remote Summary 2 A Brief History of Git Linus uses BitKeeper
More information2 Initialize a git repository on your machine, add a README file, commit and push
BioHPC Git Training Demo Script First, ensure that git is installed on your machine, and you have configured an ssh key. See the main slides for instructions. To follow this demo script open a terminal
More informationgit Version: 2.0b Merge combines trees, and checks out the result Pull does a fetch, then a merge If you only can remember one command:
Merge combines trees, and checks out the result Pull does a fetch, then a merge If you only can remember one command: git --help Get common commands and help git --help How to use git
More informationGETTING TO KNOW GIT: PART II JUSTIN ELLIOTT PENN STATE UNIVERSITY
GETTING TO KNOW GIT: PART II JUSTIN ELLIOTT PENN STATE UNIVERSITY 1 REVERTING CHANGES 2 REVERTING CHANGES Change local files git reset git checkout Revert a commit in the branch history git revert Reset
More informationGit. A fast distributed revision control system. Nils Moschüring PhD Student (LMU)
Git A fast distributed revision control system Nils Moschüring PhD Student (LMU) Nils Moschüring PhD Student (LMU), Git 1 1 The three W s What? Why? Workflow and nomenclature 2 Overview of gits structure
More informationAbout SJTUG. SJTU *nix User Group SJTU Joyful Techie User Group
About SJTUG SJTU *nix User Group SJTU Joyful Techie User Group Homepage - https://sjtug.org/ SJTUG Mirrors - https://mirrors.sjtug.sjtu.edu.cn/ GitHub - https://github.com/sjtug Git Basic Tutorial Zhou
More informationIntroduction to GIT. Jordi Blasco 14 Oct 2011
Jordi Blasco (jblasco@xrqtc.com) 14 Oct 2011 Agenda 1 Project information Who is ussing GIT 2 Branch Tag Data Transport Workow 3 Congure 4 Working with remotes 5 Project information Who is ussing GIT Project
More informationGit(Lab) Tutorial and Hands-On
Git(Lab) Tutorial and Hands-On Analysis Workshop 34th KATRIN Collaboration Meeting Institut für Kernphysik WWU Münster 21.02.2018 Git(Lab) Tutorial and Hands-On Or: Why branches aren t homeomorphic endofunctors
More informationIntroduction, Instructions and Conventions
Encodo Systems AG Garnmarkt 1 8400 Winterthur Telephone +41 52 511 80 80 www.encodo.com Encodo GIT handbook Introduction, Instructions and Conventions Abstract This document is an introduction to using
More informationVersion Control: Gitting Started
ting Started Cai Li October 2014 What is Version Control? Version control is a system that records changes to a file or set of files over time so that you can recall specific versions later. Local Version
More informationGit for Subversion users
Git for Subversion users Zend webinar, 23-02-2012 Stefan who? Stefan who? Freelancer: Ingewikkeld Stefan who? Freelancer: Ingewikkeld Symfony Community Manager Stefan who? Freelancer: Ingewikkeld Symfony
More informationSource Code Management wih git
Source Code Management wih git Matthieu Herrb December 22 http://homepages.laas.fr/matthieu/cours/git.pdf Licence This work is licensed under a Creative Commons Attribution-ShareAlike 3. Unported License.
More informationgit the SCM system Jan-Simon Möller training.linuxfoundation.org
git the SCM system Jan-Simon Möller training.linuxfoundation.org Topics What is git (what is a SCM) How to install git How to personalize git How to use git for development What is git? What is a SCM System?
More informationGit, the magical version control
Git, the magical version control Git is an open-source version control system (meaning, it s free!) that allows developers to track changes made on their code files throughout the lifetime of a project.
More informationUsing Git to Manage Source RTL
Using Git to Manage Source RTL CS250 Tutorial 1 (Version 082311) August 24, 2011 Brian Zimmer How to use this tutorial This class will be using Git for all of the labs and projects. This will allow the
More informationSo#ware(Project. Lecture'4. Wouter'Swierstra. So#ware(project( (Lecture(4 1
So#ware(Project Lecture'4 Wouter'Swierstra So#ware(project( (Lecture(4 1 Last%&me Risks So(ware-architecture So#ware(project( (Lecture(4 2 Working(effec,vely(with(git(and(GitHub. So#ware(project( (Lecture(4
More informationVersion Control. Version Control
Version Control Prepared for CS 342 - Software Design by John Bell Based on slides prepared by Jason Leigh for CS 340 University of Illinois at Chicago Version Control Incredibly important when working
More informationVersioning with git. Moritz August Git/Bash/Python-Course for MPE. Moritz August Versioning with Git
Versioning with git Moritz August 13.03.2017 Git/Bash/Python-Course for MPE 1 Agenda What s git and why is it good? The general concept of git It s a graph! What is a commit? The different levels Remote
More informationGitting things done. Hands-on introduction to git niceties. Jan Urbański Ducksboard
Gitting things done Hands-on introduction to git niceties Jan Urbański jan@ducksboard.com Ducksboard Atlassian Git Party, Madrid, September 25, 2012 Jan Urbański (Ducksboard) Gitting things done Atlassian
More informationVCS VERSION CONTROL SYSTEMS
VCS VERSION CONTROL SYSTEMS http://goo.gl/1tc7oh http://waynelkh.github.io/sa-git 1 WHO AM I? NCTU-CSCC TA wnlee 2 WHAT IS "VERION CONTROL" Version control is a system that records changes to a file or
More informationGIT. CS 490MT/5555, Spring 2017, Yongjie Zheng
GIT CS 490MT/5555, Spring 2017, Yongjie Zheng GIT Overview GIT Basics Highlights: snapshot, the three states Working with the Private (Local) Repository Creating a repository and making changes to it Working
More information6 Git & Modularization
6 Git & Modularization Bálint Aradi Course: Scientific Programming / Wissenchaftliches Programmieren (Python) Prerequisites Additional programs needed: Spyder3, Pylint3 Git, Gitk KDiff3 (non-kde (qt-only)
More informationMOOSE-Based Application Development on GitLab
MOOSE-Based Application Development on GitLab MOOSE Team Idaho National Laboratory February 22, 2016 Introduction The intended audience for this talk is developers of INL-hosted, MOOSE-based applications.
More informationGit for Version Control
Git for Version Control These slides are heavily based on slides created by Ruth Anderson for CSE 390a. Thanks, Ruth! images taken from http://git-scm.com/book/en/ http://www.cs.washington.edu/403/ About
More informationGit tutorial. Katie Osterried C2SM. October 22, 2015
Git tutorial Katie Osterried C2SM October 22, 2015 Outline 1 What is Git and why are we switching? 2 Working with Git 3 Branching and Merging 4 Working with remote repositories 5 Recommendations Outline
More informationVersion Control with Git
Version Control with Git Xiaoxu Guan High Performance Computing, LSU November 11, 2015 (https://www.atlassian.com/git/tutorials) LSU HPC Training Series, Fall 2015 p. 1/52 Overview Why should we use a
More informationE, F. deleteall command, 352 directory structure, 350 export_data method, 353 inline_data method, 353 print_export method, 351 target directory, 351
Index A Access control list (ACL), 299 Ancestry references, 184 Attributes, 288 binary files, 289 export-ignore, 294 export-subst, 294 keyword expansion, 291 merge strategies, 294 Authorized_keys file,
More informationWhat is version control? (discuss) Who has used version control? Favorite VCS? Uses of version control (read)
1 For the remainder of the class today, I want to introduce you to a topic we will spend one or two more classes discussing and that is source code control or version control. What is version control?
More informationA BASIC UNDERSTANDING OF VERSION CONTROL
A BASIC UNDERSTANDING OF VERSION CONTROL DID YOU EVER DO THIS? DID YOU EVER DO THIS? DID YOU EVER DO THIS? DID YOU EVER DO THIS? DID YOU EVER DO THIS? DID YOU EVER DO THIS? DID YOU EVER DO THIS? DID YOU
More informationGit. SSE2034: System Software Experiment 3, Fall 2018, Jinkyu Jeong
Git Prof. Jinkyu Jeong (Jinkyu@skku.edu) TA -- Minwoo Ahn (minwoo.ahn@csl.skku.edu) TA -- Donghyun Kim (donghyun.kim@csl.skku.edu) Computer Systems Laboratory Sungkyunkwan University http://csl.skku.edu
More informationVersion control with Git.
1 Version control with Git http://git-scm.com/book/en/ Basic Intro to Git We will: Discuss how Git differs from Subversion Discuss the basic Git model Pull/clone files from a repository on github Edit
More informationWindows. Everywhere else
Git version control Enable native scrolling Git is a tool to manage sourcecode Never lose your coding progress again An empty folder 1/30 Windows Go to your programs overview and start Git Bash Everywhere
More informationGit Tutorial. André Sailer. ILD Technical Meeting April 24, 2017 CERN-EP-LCD. ILD Technical Meeting, Apr 24, 2017 A. Sailer: Git Tutorial 1/36
ILD Technical Meeting, Apr 24, 2017 A. Sailer: Git Tutorial 1/36 Git Tutorial André Sailer CERN-EP-LCD ILD Technical Meeting April 24, 2017 LD Technical Meeting, Apr 24, 2017 A. Sailer: Git Tutorial 2/36
More informationGit. It is easy to shoot your foot off with git, but also easy to revert to a previous foot and merge it with your current leg.
The ECE297 Quick Start Guide Series Git It is easy to shoot your foot off with git, but also easy to revert to a previous foot and merge it with your current leg. Jack William Bell I name all my projects
More informationAgenda. Several projects are using GIT Developer(s) Junio Hamano, Linus Torvalds. Qt Stable release (January 31, 2011)
Basic Agenda 1 Project information Who is ussing 2 14 Oct 2011 3 Basic Data Transport Work ow 4 Con gure 5 Basic Project information Who is ussing Project information Who is ussing Project information
More informationAssumptions. GIT Commands. OS Commands
Many of the world s largest dev teams have adopted Git and it s not hard to see why It can handle small and large projects easily It has a tiny footprint It outclasses other version control tools It s
More informationWorking with GIT. Florido Paganelli Lund University MNXB Florido Paganelli MNXB Working with git 1/47
Working with GIT MNXB01 2017 Florido Paganelli Lund University florido.paganelli@hep.lu.se Florido Paganelli MNXB01-2017 - Working with git 1/47 Required Software Git - a free and open source distributed
More informationSoftware Development. Using GIT. Pr. Olivier Gruber. Laboratoire d'informatique de Grenoble Université de Grenoble-Alpes
Software Development 1 Using GIT Pr. Olivier Gruber olivier.gruber@imag.fr Laboratoire d'informatique de Grenoble Université de Grenoble-Alpes Overview 2 What is GIT Keeping histories of the evolution
More informationTopics covered. Introduction to Git Git workflows Git key concepts Hands on session Branching models. Git 2
Git Git 1 Topics covered Introduction to Git Git workflows Git key concepts Hands on session Branching models Git 2 Introduction to Git Git 3 Version control systems The source files of a project changes
More informationVersion Control with Git
Version Control with Git Jon Loeliger O'REILLY Beijing Cambridge Farnham Köln Sebastopol Tokyo Table of Contents Preface... xi 1. Introduction... 1 Background 1 The Birth of Git 2 Precedents 4 Time Line
More informationImproving Your Life With Git
Improving Your Life With Git Lizzie Lundgren elundgren@seas.harvard.edu Graduate Student Forum 26 April 2018 Scenarios to Avoid My code was deleted from 90-day retention! Crap, I can t remember what I
More informationRevision control. INF5750/ Lecture 2 (Part I)
Revision control INF5750/9750 - Lecture 2 (Part I) Problem area Software projects with multiple developers need to coordinate and synchronize the source code Approaches to version control Work on same
More informationCS 520: VCS and Git. Intermediate Topics Ben Kushigian
CS 520: VCS and Git Intermediate Topics Ben Kushigian https://people.cs.umass.edu/~rjust/courses/2017fall/cs520/2017_09_19.zip Our Goal Our Goal (Overture) Overview the basics of Git w/ an eye towards
More informationGit Introduction CS 400. February 11, 2018
Git Introduction CS 400 February 11, 2018 1 Introduction Git is one of the most popular version control system. It is a mature, actively maintained open source project originally developed in 2005 by Linus
More informationGIT CHEAT SHEET. CONFIG --global => write to ~/.gitconfig, otherwise to.git/config. git config [--global] -l git config [--global] -e
A DIFF GET DISPLAY INFOS / INSPECTION / COMPARISON LIST WORK WH GUI LOG LOG HISTORIC STATUS ADD TRACK GET / CREATION CLONE INIT V1.2 esnault.jerome@gmail.com SET / UNSET git config [--global] section.item
More informationIntroduction to Version Control
Research Institute for Symbolic Computation Johannes Kepler University Linz, Austria 21-Nov-2013 Outline General Remarks about Version Control 1 General Remarks about Version Control 2 Outline General
More informationGit. (Why not CVS?... because Git.) Karel Zak Florian Festi Bart Trojanowski December 20, 2007
Git (Why not CVS?... because Git.) Karel Zak Florian Festi Bart Trojanowski December 20, 2007 Copyright 2007 Karel Zak Copyright 2007 Tomas Janousek (beamer template) Copyright 2007 Florian Festi Copyright
More informationCSE 391 Lecture 9. Version control with Git
CSE 391 Lecture 9 Version control with Git slides created by Ruth Anderson & Marty Stepp, images from http://git-scm.com/book/en/ http://www.cs.washington.edu/391/ 1 Problems Working Alone Ever done one
More informationSoftware Engineering
Software Engineering CSC 331/631 - Spring 2018 Version Control with Git Paul Pauca March 27 SE Theory: Version Control Systems Link to video lectures (Soft Dev Proc part 1 of 3) Watch these short videos
More informationConfiguring Git. Matthieu Moy. configuring-git-slides.
Configuring Git Matthieu Moy Matthieu.Moy@imag.fr http://www-verimag.imag.fr/~moy/cours/formation-git/ configuring-git-slides.pdf 2015 Matthieu Moy (Matthieu.Moy@imag.fr) Configuring Git 2015 < 1 / 14
More informationGit Workflows. Sylvain Bouveret, Grégory Mounié, Matthieu Moy
s Sylvain Bouveret, Grégory Mounié, Matthieu Moy 2017 [first].[last]@imag.fr http://recherche.noiraudes.net/resources/git/git-workflow-slides.pdf 1 / 16 Goals of the presentation Global history: multiple
More informationHow To Use Git. Advanced: Tags & Branches. Mary Kate Trost July 8, 2011
How To Use Git Advanced: Tags & Branches Mary Kate Trost July 8, 2011 Create a Version (Tags) When releasing, want to mark that version so you can go back to it Create a tag git tag -a tagname -m 'tag
More informationJohn DeDourek Professor Emeritus Faculty of Computer Science University of New Brunswick GIT
John DeDourek Professor Emeritus Faculty of Computer Science University of New Brunswick GIT What is Git? A source code control system Implies program code A version control system Implies any sort of
More informationGit. Charles J. Geyer School of Statistics University of Minnesota. Stat 8054 Lecture Notes
Git Charles J. Geyer School of Statistics University of Minnesota Stat 8054 Lecture Notes 1 Before Anything Else Tell git who you are. git config --global user.name "Charles J. Geyer" git config --global
More informationAdvanced Git. Luc Sarzyniec. Xilopix, February / 88
Advanced Git Luc Sarzyniec Xilopix, February 2015 1 / 88 About This slides are using resources from the Pro Git book [isbn:1430218339] which is licensed under the Creative Commons v3.0 (by-nc-sa) license.
More informationDEAD-SIMPLE VERSION CONTROL FOR YOUR TEAM GIT WITH MATTHEW REIDSMA GRAND VALLEY STATE UNIVERSITY
DEAD-SIMPLE VERSION CONTROL FOR YOUR TEAM WITH GIT MATTHEW REIDSMA GRAND VALLEY STATE UNIVERSITY WHO DOESN T USE VERSION CONTROL? VERSION CONTROL WHO? OH BOY. WHY YOU NEED VERSION CONTROL GIT GIT WHY GIT
More informationIntroduction to Git. Database Systems DataLab, CS, NTHU Spring, 2018
Introduction to Git Database Systems DataLab, CS, NTHU Spring, 2018 1 Outline Version control system Git basics Git branch Remote repository 2 Outline Version control system Git basics Git branch Remote
More informationHg Tutorial. For : COP Object oriented Programming (Using C++) Biswas Parajuli
Hg Tutorial For : COP 3330. Object oriented Programming (Using C++) http://www.compgeom.com/~piyush/teach/3330 Biswas Parajuli Need for Version Control http://hginit.com/01.html Repository Working directory:
More informationLab Exercise Git: A distributed version control system
Lunds tekniska högskola Datavetenskap, Nov 21, 2016 EDAF45 Programvaruutveckling i grupp projekt Labb 2 (Git): Labbhandledning Checked on Git versions: 2.7.4 Lab Exercise Git: A distributed version control
More informationFEEG Applied Programming 3 - Version Control and Git II
FEEG6002 - Applied Programming 3 - Version Control and Git II Richard Boardman, Sam Sinayoko 2016-10-19 Outline Learning outcomes Working with a single repository (review) Working with multiple versions
More informationChapter 5. Version Control: Git
Chapter 5 Version Control: Git The Replication Crisis continues to heat up discussion across social science. Hence principled researchers want to make their work easy to replicate and reputable journals
More informationDistributed Version Control Git
Distributed Version Control Git Jakob Lykke Andersen jlandersen@imada.sdu.dk Tuesday 10 th October, 2017 Contents 1 Introduction 1 1.1 Notation......................................... 2 1.2 Getting Help......................................
More informationCrash Course in C++ R F L Evans. www-users.york.ac.uk/~rfle500/
Crash Course in C++ R F L Evans www-users.york.ac.uk/~rfle500/ Course overview Lecture 1 - Introduction to C++ Lecture 2 - Functions and Data Lecture 3 - Namespaces and Files Lecture 4 - Code Organization
More informationRevision control Advanced git
Revision control Advanced git Waterford Institute of Technology April 30, 2016 John Fitzgerald Waterford Institute of Technology, Revision controladvanced git 1/35 Presentation outline Estimated duration
More informationHow to version control like a pro: a roadmap to your reproducible & collaborative research
How to version control like a pro: a roadmap to your reproducible & collaborative research The material in this tutorial is inspired by & adapted from the Software Carpentry lesson on version control &
More informationGit Like You Mean it. Alan Ott SCaLE 16x March 8-11, 2018
Git Like You Mean it Alan Ott SCaLE 16x March 8-11, 2018 About the Presenter Platform Software at SoftIron Data center appliances (storage, transcoding) Ceph-based storage appliances OverDrive 3000/1000
More informationRSARTE Git Integration
RSARTE Git Integration Anders Ek IBM INTRODUCTION...3 EGIT BRIEF OVERVIEW...3 GETTING STARTED...6 ECLIPSE PROJECTS AND GIT REPOSITORIES...6 ACCESSING A REMOTE GIT REPOSITORY...7 IMPORTING AN EXISTING REPOSITORY...8
More informationKTH Royal Institute of Technology SEMINAR 2-29 March Simone Stefani -
KTH Royal Institute of Technology SEMINAR 2-29 March 2017 Simone Stefani - sstefani@kth.se WHAT IS THIS SEMINAR ABOUT Branching Merging and rebasing Git team workflows Pull requests and forks WHAT IS THIS
More informationGUIDE TO MAKE A REAL CONTRIBUTION TO AN OPEN SOURCE PROJECT 1. 1
GUIDE TO MAKE A REAL CONTRIBUTION TO AN OPEN SOURCE PROJECT 1. 1 WHO AM I? @tushar_rishav GSoC'16 student contributing to coala - a static code analysis tool, under Python So ware Foundation. A senior
More informationSoftware Project (Lecture 4): Git & Github
Software Project (Lecture 4): Git & Github Wouter Swierstra, Atze Dijkstra Feb 2016 Wouter Swierstra, Atze Dijkstra Software Project (Lecture 4): Git & Github Feb 2016 1 / 45 Wouter Swierstra, Atze Dijkstra
More informationGIT tutorial. David Parsons, Soraya Arias, Thomas Calmant November, Preamble 2
GIT tutorial David Parsons, Soraya Arias, Thomas Calmant November, 2017 Contents 1 Preamble 2 2 First steps 2 2.1 Basic configuration.......................................... 2 2.2 Create your very first
More informationEECS 470 Lab 4. Version Control System. Friday, 31 st January, 2014
EECS 470 Lab 4 Version Control System Department of Electrical Engineering and Computer Science College of Engineering University of Michigan Friday, 31 st January, 2014 (University of Michigan) Lab 4:
More informationתוכנית יומית לכנס התכנסות וארוחת בוקר
תוכנית יומית לכנס התכנסות וארוחת בוקר 08:00-09:00 הרצאה הפסקה ראשונה הרצאה ארוחת צהריים הרצאה הפסקה מתוקה -09:00-10:30-10:30-10:45-10:45-12:30-12:30-13:30-13:30-15:00-15:00-15:15 הרצאה 15:15-16:30 לפרטים
More information1. Git. Robert Snapp
. Git Robert Snapp snapp@cs.uvm.edu Department of Computer Science University of Vermont CS 3 (UVM). Git Fall 0 / Git CS 3 (UVM). Git Fall 0 / Setting your defaults in /.git > git config --global user.name
More informationWorking in Teams CS 520 Theory and Practice of Software Engineering Fall 2018
Working in Teams CS 520 Theory and Practice of Software Engineering Fall 2018 Version Control September 18, 2018 Thursday (September 20) First in-class exercise On using git (today is a prelude with useful
More informationBarry Grant
Barry Grant bjgrant@umich.edu http://thegrantlab.org What is Git? (1) An unpleasant or contemptible person. Often incompetent, annoying, senile, elderly or childish in character. (2) A modern distributed
More informationVersion control with git and Rstudio. Remko Duursma
Version control with git and Rstudio Remko Duursma November 14, 2017 Contents 1 Version control with git 2 1.1 Should I learn version control?...................................... 2 1.2 Basics of git..................................................
More information