CPSC 491. Lecture 19 & 20: Source Code Version Control. VCS = Version Control Software SCM = Source Code Management

Size: px
Start display at page:

Download "CPSC 491. Lecture 19 & 20: Source Code Version Control. VCS = Version Control Software SCM = Source Code Management"

Transcription

1 CPSC 491 Lecture 19 & 20: Source Code Version Control VCS = Version Control Software SCM = Source Code Management Exercise: Source Code (Version) Control 1. Pretend like you don t have a version control system (e.g., no git, subversion, cvs, etc.) 2. How would you manage your source code as a team? imagine what this might be like, e.g.: editing different files editing different parts of the same file maintaining different versions of software 3. What might be some problems with this?

2 Version Control Examples of problems: could delete a file (or worse, many files) make changes but want to go back to an older version could overwrite other people s changes e.g., if 2 people work on same file, last one to save wins have to deal with a proliferation of files different versions of software (v1.0, v1.2, v1.4.6, v2.0, ) feature freeze and bug fix (merge back changes) In general, requires a lot of communication/coordination which will take up a lot of time... Version Control Version control software tries to alleviate this mess goes by many names version, revision, source (code) control configuration management A best (and now standard) practice in software eng. automates many otherwise tedious tasks manages versions efficiently (diffs) allows concurrent editing (some restrictions) many tools (git, svn, cvs, team foundation, etc.)

3 The plan Talk about basic concepts in version control 2. Talk about different workflows ( flows ) how to organize versions of software how to organize your development/deployment workflow 3. Go over (command-line) git What can be versioned? Usually any kind of file source code build scripts (make, ant, ) configuration files images libraries documentation and so on So, more general than just source code

4 Basic Concepts Configuration Item: An atomic object in the SCM system usually at the level of a file Configuration: Collection of specific configuration items all the objects (files) needed for the software product Basic Concepts Version: A snapshot of a file or configuration at some time a version is frozen can t be changed new versions can be created and saved Version id: unique identifier for the version of the item used to obtain or compare previous versions systems differ on how versions assigned (and to what)

5 Basic Concepts Branch: named stream of changes to the configuration branches form a tree (but with special merge edges) paths through the tree are the branches main branch sometimes called the master branch At the configuration level Basic Concepts Version 1 At the item level Version 3 Version 5 Version 2 Version 4 merge changes Version 6

6 Repository: where versions are stored Basic Concepts a central location (server) where files stored e.g., ada (used to) house a number of svn repos typically one repository per product (but not required) Basic Concepts Workspace: local system where modifications happen Check out: initial download of a repository to a workspace in git this is called a clone Commit: save local changes to the repository creates a new version id for item(s) being committed stores a copy of the item under the new id most SCM systems are smart about storage: e.g., store first version then just diffs called a push in git, check in in svn

7 Basic Concepts Update: get most recent versions of item(s) e.g., to get changes made by others in git this is called a pull Conflict: This can be bad! (sometimes) item changed and committed at the same time At the same time means... A & B update from same version Basic Concepts A checks in first (becomes upstream change for B) B now has an out-of-date version B checks in Most systems won t let you check in if there is a conflict! How could this have been avoided? Always update before checking in! Many systems will handle the conflicts automatically as long as different parts of the code were changed

8 Merge: incorporate changes into a revised item 1. Alice and Bob update to v10 2. Alice modifies v10 3. Alice updates & commits to v11 4. Bob modifies v10 5. Bob updates Basic Concepts 6. System tries to merge changes (if can t, a conflict exists) 7. Bob commits to v12 Fixing conflicts is done manually: e.g., using a text editor (on text files) or, by accepting yours or theirs (binary files) Optimistic vs. Pessimistic Concurrency Basic Concepts Most systems use optimistic concurrency by default allow parallel modifications (of files) handle conflicts as needed This works in practice since conflicts are rare people don t usually work on the same thing if they do, they work together (communicate!)

9 Basic Concepts Using pessimistic concurrency ensures sequential modifications using file locks default in rcs for modifying files (cvs, svn, git precursor) how it generally works check out file with a write lock (if not existing write locks) only person holding write lock can modify file after changes, check in and release write lock anyone can get a read lock Basic Concepts Tag: a named point in history (configuration snapshot) typically used to mark a release point e.g., rc1.0 or v2.0 once tagged, doesn t change (different than a branch) the tag only denotes the configuration at that point in time

10 Subversion & Git Both are open-source and free version control systems Subversion: Central repository, distributed clients Predates git, but after cvs (which was after rcs) local changes aren t versioned until checked in only the central repository has complete history Git: Fully distributed cloning a repository copies entire history allows for local versioning & faster ops (not over network) can control access by controlling pull requests branching is a core concept (e.g., local repos are branches) Workflows [Atlassian] Centralized Workflow essentially the subversion model only one master branch developers clone master make changes pull changes from master then push changes to master

11 Workflows [Atlassian] Feature Branch Workflow (aka GitHub Flow) still use a centralized master branch holds a stable / deployable version of the product all feature development done in a dedicated branch descriptively named according to the feature stored in the central repository so multiple people can work on a feature branch once a feature branch is ready to become part of master a pull request is issued (ask to be merged w/ master) team can review & discuss changes once accepted, the feature branch is pulled into master Git-Flow Workflow Workflows [Atlassian] stricter (& more complicated) version of GitHub Flow specific roles for different branches how and when they interact historical branches a master and a develop branch master stores official history develop is an integration branch for features commits tagged in master w/ version number (v0.1, v1.2)

12 Git-Flow Workflow (cont) Workflows [Atlassian] Feature branches each feature in a separate branch but off of develop (parent branch) instead of master when completed, feature merged back into develop Release branches once ready for a release fork (copy) a release branch off of develop can then continue adding new features to develop once ready to deploy, merge release with master (and tag) release also merged back with develop Workflows [Atlassian] Git-Flow Workflow (cont) Maintenance ( hotfix ) branches used to quickly patch production releases (e.g., bug fixes) these are the only branches off of master as soon as the fix is complete, merge into master & develop master tagged with updated version number

13 Workflows [Atlassian] Git-Flow Workflow (cont) Using Version Control Exercise: Within your team Determine the workflow you are currently using Determine what workflow you think will work best for your team and why consider: Centralized workflow Github-flow Git-flow Variants And Trade-offs of each for your project

14 Pre-Quiz Results... YES SORT OF NO Basic Terms 58% (21) 42% (15) 0 (yeah!) Basic Commands 50% (18) 17% (6) 33% (12) Branching 17% (6) 22% (8) 61% (22) Cloning a repository On your local machine, use the git clone command copies the repository (as a directory) onto your machine can locally version changes Using GitHub: git clone clones to a folder named REPOSITORY

15 Checking on the status of your workspace On your local machine, use the git status command status of files in repository (modified, etc) files that are not being tracked How to run: git status Adding new files to your workspace After adding file(s), use the git add command stages the file to be added (adds to the index) not yet committed to the workspace How to run: git add FILE For example: git add shawn.txt git add *.py git add dir/file1.txt

16 Committing Your Changes (* nice feature of git) Use git commit to commit changes to your workspace either after adding or modifying a file file becomes versioned in your workspace How to run: git commit -m MSG FILE For example: git commit -m my new file shawn.txt git commit -m useful msg *.py git commit -m useful msg dir/file1.txt Push Your Changes (to the mothership) Use git push to commit changes to original repository good practice: update first (pull) changes to workspace (master) merged with origin/master How to run: git push

17 Update your workspace Use git pull to merge changes to original repository changes to origin/master merged with workspace (master) note this is different than a pull request How to run: git pull Recovering files from your workspace Use git checkout to recover files in workspace e.g., if you accidentally delete a file or modify a file How to run: git checkout FILE

18 Removing files from your workspace Use git rm to remove files from workspace e.g., to get rid of unneeded files when you push to origin/master, removes file there as well How to run: git rm FILE Creating a branch You create a branch using git branch BNAME will want to branch from an up-to-date branch e.g., after pulling origin/master You switch to the branch using git checkout BNAME this sets your current workspace to the branch can switch back and forth between branches How to run: git branch BNAME git checkout BNAME Alternatively: git checkout -b BNAME

19 Exercise: Create a branch 1. In your project repo, create a new branch 2. create, add, and commit a file to the branch 3. switch to the master branch 4. what changed in your working directory (e.g., run ls)? Merging branches When you are in a branch, you can merge in another branch e.g., to update your branch, merge master into it or, switch to master, merge in your branch adds new files, merges changes to existing files Use the git merge BNAME to merge in changes How to run (e.g., from within your new branch): git merge master -m message git merge origin/master -m message

20 Exercise: merge a branch 1. switch to master (git checkout master) 2. create, add, and commit a file 3. switch to your branch 4. merge in master (git merge master -m... ) 5. what changed in your branch? 6. switch back to master and push your changes... Pushing your new branch So far, you only have your branch in your workspace Now we want to push it to the mothership e.g., so that others can work on it and so it is versioned in the central repository To push it (from within the branch), run: git push --set-upstream origin BNAME - or - git push -u origin BNAME

21 Exercise: push your branch 1. switch to your branch 2. push your branch 3. see if you can find your branch on GitHub Note: See remote branches: git branch -r Checkout remote branch: git checkout -b BNAME origin/bname To remove a branch Once you are done with a branch you can delete it either locally or from the repository To remove a branch locally run (from master): git branch -d BNAME To remove a branch from repository run (from master): git push origin --delete BNAME

22 Creating Tags Git supports 2 kinds of tags: lightweight vs annotated an annotated tag has additional information including a message and info on who created the tag To see the existing tags: git tag To create an annotated tag: git tag -a TAGNAME -m tag message To see information about a tag: git show TAGNAME Exercise: tag your branch 1. switch to your branch 2. create a tag with tag name v0.1 (or whatever you want) 3. verify that the tag was created and show the tag info

23 Pushing Tags to the Shared Server By default, git push doesn t push tag information instead, have to tell git to push the tag To push a tag: git push origin TAGNAME To branch from a tag: git checkout -b BRANCHNAME TAGNAME This only creates a branch, tagged configurations don t change Exercise: push your tag 1. push your tag to origin 2. go onto GitHub 3. select branch & look at releases (should see your branch)

24 Merge Conflicts Usually git can auto-merge just fine But sometimes there is a problem when it can t merge a conflict, it pauses the merge process and then you have to fix the conflict yourself You can run a mergetool to help fix the merge: git mergetool Once the merge is resolved, start the process again git status will tell you what to do Merge Conflicts Text-based conflicts are expressed as a diff File 1: 1 The quick brown fox jumps over the lazy dog File 2: 1 The lazy dog jumps over the quick brown fox 2 3 Hello World! What is different? (running diff file1 file2) 1c1 < The quick brown fox jumps over the lazy dog --- > The lazy dog jumps over the quick brown fox 2a3 > Hello World!

25 Merge Conflicts What is different? (running diff file1 file2) Diff output: 1c1 < The quick brown fox jumps over the lazy dog --- > The lazy dog jumps over the quick brown fox 2a3 > Hello World! xcy = line(s) x in file 1 changed to line(s) y in file 2 xay = line(s) y in file 2 added after line x in file 1 xdy = line(s) x in file 1 deleted in file 2 (at line y) Exercise: resolve a conflict 1. switch to your branch 2. modify your file 3. commit the file 4. switch to master 5. modify the file to create a conflict 6. commit the file 7. switch to your branch and merge in master 8. fix the merge and commit 9. what happens to master?

26 Pull Requests A feature of GitHub... request for a branch to be pulled into master UI for carrying out this process Try it out: 1. make sure your branch is pushed 2. log on to GitHub, select your branch 3. click on the pull request button 4. walk through the steps of performing a pull request

Use git rm to remove files from workspace

Use git rm to remove files from workspace More Git: Removing files from the repository Branches, tags, merge conflicts Pull requests CPSC 491 First: Get up to speed from last time Removing files from your workspace Use git rm to remove files from

More information

What is version control? (discuss) Who has used version control? Favorite VCS? Uses of version control (read)

What 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 information

KTH Royal Institute of Technology SEMINAR 2-29 March Simone Stefani -

KTH 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 information

CSC 2700: Scientific Computing

CSC 2700: Scientific Computing CSC 2700: Scientific Computing Record and share your work: revision control systems Dr Frank Löffler Center for Computation and Technology Louisiana State University, Baton Rouge, LA Feb 13 2014 Overview

More information

Github/Git Primer. Tyler Hague

Github/Git Primer. Tyler Hague Github/Git Primer Tyler Hague Why Use Github? Github keeps all of our code up to date in one place Github tracks changes so we can see what is being worked on Github has issue tracking for keeping up with

More information

Review Version Control Concepts

Review Version Control Concepts Review Version Control Concepts SWEN-261 Introduction to Software Engineering Department of Software Engineering Rochester Institute of Technology Managing change is a constant aspect of software development.

More information

[Software Development] Development Tools. Davide Balzarotti. Eurecom Sophia Antipolis, France

[Software Development] Development Tools. Davide Balzarotti. Eurecom Sophia Antipolis, France [Software Development] Development Tools Davide Balzarotti Eurecom Sophia Antipolis, France Version Control Version (revision) control is the process of tracking and recording changes to files Most commonly

More information

Git, the magical version control

Git, 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 information

Revision control. INF5750/ Lecture 2 (Part I)

Revision 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 information

Ingegneria del Software Corso di Laurea in Informatica per il Management (D)VCS. Davide Rossi Dipartimento di Informatica Università di Bologna

Ingegneria del Software Corso di Laurea in Informatica per il Management (D)VCS. Davide Rossi Dipartimento di Informatica Università di Bologna Ingegneria del Software Corso di Laurea in Informatica per il Management (D)VCS Davide Rossi Dipartimento di Informatica Università di Bologna Rationale for version control Control the revisions of artifacts

More information

Git tutorial. Katie Osterried C2SM. October 22, 2015

Git 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 information

Version Control Systems (Part 1)

Version Control Systems (Part 1) i i Systems and Internet Infrastructure Security Institute for Networking and Security Research Department of Computer Science and Engineering Pennsylvania State University, University Park, PA Version

More information

Working 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 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 information

Version Control Systems: Overview

Version Control Systems: Overview i i Systems and Internet Infrastructure Security Institute for Networking and Security Research Department of Computer Science and Engineering Pennsylvania State University, University Park, PA Version

More information

Git Workflows. Sylvain Bouveret, Grégory Mounié, Matthieu Moy

Git 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 information

Topics covered. Introduction to Git Git workflows Git key concepts Hands on session Branching models. Git 2

Topics 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 information

Revision Control. How can 4. Slides #4 CMPT 276 Dr. B. Fraser. Local Topology Simplified. Git Basics. Revision Control:

Revision Control. How can 4. Slides #4 CMPT 276 Dr. B. Fraser. Local Topology Simplified. Git Basics. Revision Control: How can 4 (or 4000) developers work on a product at once? Revision Control Revision Control Revision Control: Also called version control, source control, software configuration management. Motivation:

More information

Laboratorio di Programmazione. Prof. Marco Bertini

Laboratorio di Programmazione. Prof. Marco Bertini Laboratorio di Programmazione Prof. Marco Bertini marco.bertini@unifi.it http://www.micc.unifi.it/bertini/ Code versioning: techniques and tools Software versions All software has multiple versions: Each

More information

Version Control: Gitting Started

Version 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 information

b. Developing multiple versions of a software project in parallel

b. Developing multiple versions of a software project in parallel Multiple-Choice Questions: 1. Which of these terms best describes Git? a. Integrated Development Environment b. Distributed Version Control System c. Issue Tracking System d. Web-Based Repository Hosting

More information

Tools for software development:

Tools for software development: Tools for software development: Version Control System Source Control Management Repository commit An introduction push Data Processing Course, V. Lafage, IPN Orsay V. Lafage @ Data Processing Course 2019

More information

Version Control System - Git. zswu

Version 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 information

git commit --amend git rebase <base> git reflog git checkout -b Create and check out a new branch named <branch>. Drop the -b

git 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 information

Revision control systems (RCS) and. Subversion

Revision control systems (RCS) and. Subversion Revision control systems (RCS) and Subversion Problem area Software projects with multiple developers need to coordinate and synchronize the source code Approaches to version control Work on same computer

More information

GIT TUTORIAL. Creative Software Architectures for Collaborative Projects CS 130 Donald J. Patterson

GIT TUTORIAL. Creative Software Architectures for Collaborative Projects CS 130 Donald J. Patterson GIT TUTORIAL Creative Software Architectures for Collaborative Projects CS 130 Donald J. Patterson SCM SOFTWARE CONFIGURATION MANAGEMENT SOURCE CODE MANAGEMENT Generic term for the ability to manage multiple

More information

Revision Control. An Introduction Using Git 1/15

Revision Control. An Introduction Using Git 1/15 Revision Control An Introduction Using Git 1/15 Overview 1. What is revision control? 2. 30,000 foot view 3. Software - git and gitk 4. Setting up your own repository on onyx 2/15 What is version control?

More information

Tizen/Artik IoT Practice Part 4 Open Source Development

Tizen/Artik IoT Practice Part 4 Open Source Development 1 Tizen/Artik IoT Practice Part 4 Open Source Development Sungkyunkwan University Contents 2 SCM Tool: Git Version Management Local & Remote Repository Branch Management Github Contribution Process Issue

More information

Revision Control and GIT

Revision Control and GIT Revision Control and GIT On UD HPC Community Clusters William Totten Network & Systems Services Why use revision control You can go back in time It makes it easy to try things out which might not work

More information

1. Which of these Git client commands creates a copy of the repository and a working directory in the client s workspace. (Choose one.

1. Which of these Git client commands creates a copy of the repository and a working directory in the client s workspace. (Choose one. Multiple-Choice Questions: 1. Which of these Git client commands creates a copy of the repository and a working directory in the client s workspace. (Choose one.) a. update b. checkout c. clone d. import

More information

FAQ Q: Where/in which branch do I create new code/modify existing code? A: Q: How do I commit new changes? A:

FAQ Q: Where/in which branch do I create new code/modify existing code? A: Q: How do I commit new changes? A: FAQ Q: Where/in which branch do I create new code/modify existing code? A: We strongly recommend only modifying the source code within the local master branch: Git Repository View Woped repository Branches

More information

TDDC88 Lab 4 Software Configuration Management

TDDC88 Lab 4 Software Configuration Management TDDC88 Lab 4 Software Configuration Management Introduction "Version control is to programmers what the safety net is to a trapeze artist. Knowing the net is there to catch them if they fall, aerialists

More information

Version Control Systems. Copyright 2017 by Robert M. Dondero, Ph.D. Princeton University

Version Control Systems. Copyright 2017 by Robert M. Dondero, Ph.D. Princeton University Version Control Systems Copyright 2017 by Robert M. Dondero, Ph.D. Princeton University 1 Objectives You will learn/review: Version control systems (VCSs), as mechanisms for Maintaining file versions Safely

More information

What is git? Distributed Version Control System (VCS); Created by Linus Torvalds, to help with Linux development;

What is git? Distributed Version Control System (VCS); Created by Linus Torvalds, to help with Linux development; What is git? Distributed Version Control System (VCS); Created by Linus Torvalds, to help with Linux development; Why should I use a VCS? Repositories Types of repositories: Private - only you and the

More information

February 2 nd Jean Parpaillon

February 2 nd Jean Parpaillon Using GIT with Kerrighed project Kerrighed Summit '07 February 2 nd 2007 Jean Parpaillon Table of contents Kerrighed SCM Subversion GIT GIT with Kerrighed References 2 Kerrighed

More information

Version control CSE 403

Version control CSE 403 Version control CSE 403 Goals of a version control system Keep a history of your work Explain the purpose of each change Checkpoint specific versions (known good state) Recover specific state (fix bugs,

More information

CSCI 2132: Software Development. Norbert Zeh. Faculty of Computer Science Dalhousie University. Subversion (and Git) Winter 2019

CSCI 2132: Software Development. Norbert Zeh. Faculty of Computer Science Dalhousie University. Subversion (and Git) Winter 2019 CSCI 2132: Software Development Subversion (and Git) Norbert Zeh Faculty of Computer Science Dalhousie University Winter 2019 Version Control Systems A version control system allows us to Record the history

More information

Fundamentals of Git 1

Fundamentals 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 information

git 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:

git 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 information

Versioning with git. Moritz August Git/Bash/Python-Course for MPE. Moritz August Versioning with Git

Versioning 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 information

Introduction to Git and Github

Introduction to Git and Github Introduction to Git and Github Computing in Optimization and Statistics: Lecture 1 Jackie Baek MIT January 10, 2017 What is git and GitHub? git is a version control system. Other version control systems

More information

Visualizing Git Workflows. A visual guide to 539 workflows

Visualizing Git Workflows. A visual guide to 539 workflows Visualizing Git Workflows A visual guide to 539 workflows Table of Contents Notation Collaboration Without Review or Branches Merge Conflicts Requesting Code Review Collaboration with Multiple Branches

More information

Version control CSE 403

Version control CSE 403 Version control CSE 403 Goals of a version control system Keep a history of your work Explain the purpose of each change Checkpoint specific versions (known good state) Recover specific state (fix bugs,

More information

CSE 160: Introduction to Parallel Computation

CSE 160: Introduction to Parallel Computation CSE 160: Introduction to Parallel Computation Discussion Section SVN Tutorial Based primarily on material provided by Ingolf Krueger Contributions made by Jing Zheng, Yashodhan Karandikar, and Scott B.

More information

Software Engineering

Software 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 information

Overview. 1. Install git and create a Github account 2. What is git? 3. How does git work? 4. What is GitHub? 5. Quick example using git and GitHub

Overview. 1. Install git and create a Github account 2. What is git? 3. How does git work? 4. What is GitHub? 5. Quick example using git and GitHub Git 101: Overview 1. Install git and create a Github account 2. What is git? 3. How does git work? 4. What is GitHub? 5. Quick example using git and GitHub Github icon 1 Install git and a create GitHub

More information

API RI. Application Programming Interface Reference Implementation. Policies and Procedures Discussion

API RI. Application Programming Interface Reference Implementation. Policies and Procedures Discussion API Working Group Meeting, Harris County, TX March 22-23, 2016 Policies and Procedures Discussion Developing a Mission Statement What do we do? How do we do it? Whom do we do it for? What value are we

More information

Version Control for the 2- Pizza Team: Merge Conflicts (ELLS 9.5) Armando Fox

Version Control for the 2- Pizza Team: Merge Conflicts (ELLS 9.5) Armando Fox Version Control for the 2- Pizza Team: Merge Conflicts (ELLS 9.5) Armando Fox 2012 Armando Fox & David Patterson Licensed under Creative Commons Attribution- NonCommercial-ShareAlike 3.0 Unported License

More information

About CVS. 1 Version Control - what is it? why is it useful?

About CVS. 1 Version Control - what is it? why is it useful? About CVS CVS stands for Concurrent Version Control. It s free, open-source software used by multiple developers to share code, keep track of changes, and keep different versions of a project. it can be

More information

AIS Grid School 2015

AIS Grid School 2015 Getting distributed without losing your HEAD AIS Grid School 2015 Дубна, Россия 3 e Oктября 2015 Benjamin Wolff (CERN / GS-AIS) Logo source: http://git-scm.com/downloads/logos What is a Version Control

More information

Git. CSCI 5828: Foundations of Software Engineering Lecture 02a 08/27/2015

Git. CSCI 5828: Foundations of Software Engineering Lecture 02a 08/27/2015 Git CSCI 5828: Foundations of Software Engineering Lecture 02a 08/27/2015 1 Lecture Goals Present a brief introduction to git You will need to know git to work on your presentations this semester 2 Git

More information

Software configuration management

Software configuration management Software Engineering Theory Software configuration management Lena Buffoni/ Kristian Sandahl Department of Computer and Information Science 2017-03-27 2 Maintenance Requirements System Design (Architecture,

More information

Software Tools Subversion

Software Tools Subversion Software Tools Subversion Part II Lecture 4 1 Today s Outline Subversion (SVN) TortoiseSVN Client SVN Tips 2 Subversion (SVN) 3 Subversion (SVN) Centralized open-source VCS; started in 2000 Developed as

More information

Project Management. Overview

Project Management. Overview Project Management Overview How to manage a project? What is software configuration management? Version control systems Issue tracking systems N. Meng, L. Zhang 2 1 What is Project Management? Effective

More information

Object Oriented Programming. Week 1 Part 2 Git and egit

Object Oriented Programming. Week 1 Part 2 Git and egit Object Oriented Programming Part 2 Git and egit Lecture Review of Git Local Repository Remote Repository Using Git from Eclipse Review of Git 3 What is Git? Software Configuration Management (SCM) Supports

More information

Using Git to Manage Source RTL

Using 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 information

USPAS Simulation of Beam and Plasma Systems Steven M. Lund, Jean-Luc Vay, Remi Lehe, Daniel Winklehner and David L. Bruhwiler Lecture: Software Version Control Instructor: David L. Bruhwiler Contributors:

More information

A L A TEX-oriented intro to Git

A L A TEX-oriented intro to Git A L A TEX-oriented intro to Git the tex part is in the interactive demo not in the slides Danielle Amethyst Brake 22 October - 26 November, 2018 ICERM Semester on Nonlinear Algebra Inter-week collaboration

More information

Distributed Version Control

Distributed Version Control Distributed Version Control David Grellscheid 2014-03-17 Workshop on Advanced Techniques for Scientific Programming and Management of Open Source Software Packages 10 21 March 2014 Version management In

More information

Brief overview of the topic and myself the 7 VCS used so far (different one each time), still many unused Acts as a time-machine, and almost as

Brief overview of the topic and myself the 7 VCS used so far (different one each time), still many unused Acts as a time-machine, and almost as Brief overview of the topic and myself the 7 VCS used so far (different one each time), still many unused Acts as a time-machine, and almost as contentious as the text editor This talk tries to address

More information

2 Initialize a git repository on your machine, add a README file, commit and push

2 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 information

CS 320 Introduction to Software Engineering Spring February 06, 2017

CS 320 Introduction to Software Engineering Spring February 06, 2017 CS 320 Introduction to Software Engineering Spring 2017 February 06, 2017 Recap: Software development process models Traditional models Waterfall model Iterative and incremental Prototyping Spiral model

More information

Git(Lab) Tutorial and Hands-On

Git(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 information

Lab Objective. Lab Assignment. Downloads and Installation

Lab Objective. Lab Assignment. Downloads and Installation How I Start Working with Git: Git Lab 01 Adapted from: (1) https://github.com/quantstack/xeus-cling (2) https://code.visualstudio.com/docs/languages/cpp Lab Objective 1. Installing and using VS Code 2.

More information

Software Development I

Software Development I 6.148 Software Development I Two things How to write code for web apps. How to collaborate and keep track of your work. A text editor A text editor A text editor Anything that you re used to using Even

More information

Task-Oriented Solutions to Over 175 Common Problems. Covers. Eclipse 3.0. Eclipse CookbookTM. Steve Holzner

Task-Oriented Solutions to Over 175 Common Problems. Covers. Eclipse 3.0. Eclipse CookbookTM. Steve Holzner Task-Oriented Solutions to Over 175 Common Problems Covers Eclipse 3.0 Eclipse CookbookTM Steve Holzner Chapter CHAPTER 6 6 Using Eclipse in Teams 6.0 Introduction Professional developers frequently work

More information

FEEG Applied Programming 3 - Version Control and Git II

FEEG 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 information

CS 520: VCS and Git. Intermediate Topics Ben Kushigian

CS 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 information

Version Control. Version Control

Version 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 information

Git. Presenter: Haotao (Eric) Lai Contact:

Git. 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 information

EECS 470 Lab 4. Version Control System. Friday, 31 st January, 2014

EECS 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

Git AN INTRODUCTION. Introduction to Git as a version control system: concepts, main features and practical aspects.

Git AN INTRODUCTION. Introduction to Git as a version control system: concepts, main features and practical aspects. Git AN INTRODUCTION Introduction to Git as a version control system: concepts, main features and practical aspects. How do you share and save data? I m working solo and I only have one computer What I

More information

Lecture 6 Remotes. Sign in on the attendance sheet!

Lecture 6 Remotes. Sign in on the attendance sheet! Lecture 6 Remotes Sign in on the attendance sheet! Midterm Review Everyone did great! What We ve Learned So Far Creating and cloning repositories git init, git clone Linear commit histories and diffs git

More information

Version Control Systems

Version Control Systems Nothing to see here. Everything is under control! September 16, 2015 Change tracking File moving Teamwork Undo! Undo! UNDO!!! What strategies do you use for tracking changes to files? Change tracking File

More information

2/8/18. Overview. Project Management. The First Law. What is Project Management? What Are These Changes? Software Configuration Management (SCM)

2/8/18. Overview. Project Management. The First Law. What is Project Management? What Are These Changes? Software Configuration Management (SCM) Overview Project Management How to manage a project? What is software configuration management? Version control systems Issue tracking systems N. Meng, L. Zhang 2 What is Project Management? Effective

More information

Assumptions. GIT Commands. OS Commands

Assumptions. 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 information

Git for Subversion users

Git 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 information

Git. all meaningful operations can be expressed in terms of the rebase command. -Linus Torvalds, 2015

Git. all meaningful operations can be expressed in terms of the rebase command. -Linus Torvalds, 2015 Git all meaningful operations can be expressed in terms of the rebase command -Linus Torvalds, 2015 a talk by alum Ross Schlaikjer for the GNU/Linux Users Group Sound familiar? add commit diff init clone

More information

Software Project (Lecture 4): Git & Github

Software 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 information

Version Control. So#ware Quality Quality Audit and Cer2fica2on. Master in Computer Engineering. Roberto García

Version Control. So#ware Quality Quality Audit and Cer2fica2on. Master in Computer Engineering. Roberto García Version Control So#ware Quality Quality Audit and Cer2fica2on Master in Computer Engineering Roberto García (rgarcia@diei.udl.cat) Introduc2on Change- control procedures. Avoid uncontrolled changes, destabilize

More information

Outline. Introduction to Version Control Systems Origins of Git Git terminology & concepts Basic Git commands Branches in Git Git over the network

Outline. Introduction to Version Control Systems Origins of Git Git terminology & concepts Basic Git commands Branches in Git Git over the network Outline Introduction to Version Control Systems Origins of Git Git terminology & concepts Basic Git commands Branches in Git Git over the network Why do I need version control? How many lines of code was

More information

Systems Software. Recitation 1: Intro & Revision Control. Quite different from 213. Our Philosophy. Partly-free lunch

Systems Software. Recitation 1: Intro & Revision Control. Quite different from 213. Our Philosophy. Partly-free lunch Systems Software Recitation 1: Intro & Revision Control Dave Andersen CMU Computer Science Fall 2006 Low-level (projects in C) Designed to run forever Handle every possible error condition Manage resources

More information

Version (Source Code) Control SWEN-250

Version (Source Code) Control SWEN-250 Version (Source Code) Control SWEN-250 Overview Motivation why is version control useful? Key concepts Variations on the basic theme Example version control systems 1/10/2019 (c) 2013 RIT Dept. of Software

More information

Version Control. CSC207 Fall 2014

Version Control. CSC207 Fall 2014 Version Control CSC207 Fall 2014 Problem 1: Working Solo How do you keep track of changes to your program? Option 1: Don t bother Hope you get it right the first time Hope you can remember what changes

More information

Outline. Introduction to Version Control Systems Origins of Git Git terminology & concepts Basic Git commands Branches in Git Git over the network

Outline. Introduction to Version Control Systems Origins of Git Git terminology & concepts Basic Git commands Branches in Git Git over the network Outline Introduction to Version Control Systems Origins of Git Git terminology & concepts Basic Git commands Branches in Git Git over the network Why do I need version control? How many lines of code was

More information

Version Control System GIT

Version Control System GIT Version Control System GIT Version Contol System Version (revision) control systems are software that help you track changes you make in your code over time. As you edit to your code, you tell the version

More information

You Can t Move Forward Unless You Can Roll Back. By: Michael Black

You Can t Move Forward Unless You Can Roll Back. By: Michael Black You Can t Move Forward Unless You Can Roll Back By: Michael Black The VP of Sales walks in and tells you that your largest and oldest client wants to pay for a custom modification. But here s the clincher,

More information

The Old World. Have you ever had to collaborate on a project by

The Old World. Have you ever had to collaborate on a project by What the Git? The Old World Have you ever had to collaborate on a project by Shuttling a USB drive back and forth Using Dropbox E-mailing your document around Have you ever accidentally deleted someone

More information

Chapter 3. Revision Control

Chapter 3. Revision Control Chapter 3 Revision Control We begin our journey into software engineering before we write a single line of code. Revision control systems (RCSes) such as Subversion or CVS are astoundingly useful for single-developer

More information

Version Control. Version Control

Version Control. Version Control Version Control CS440 Introduction to Software Engineering John Bell Based on slides prepared by Jason Leigh for CS 340 University of Illinois at Chicago Version Control Incredibly important when working

More information

Git AN INTRODUCTION. Introduction to Git as a version control system: concepts, main features and practical aspects.

Git AN INTRODUCTION. Introduction to Git as a version control system: concepts, main features and practical aspects. Git AN INTRODUCTION Introduction to Git as a version control system: concepts, main features and practical aspects. How do you share and save data? I m working solo and I only have one computer What I

More information

Git Branching. Chapter What a Branch Is

Git Branching. Chapter What a Branch Is Chapter 3 Git Branching Nearly every VCS has some form of branching support. Branching means you diverge from the main line of development and continue to do work without messing with that main line. In

More information

Source control with Subversion A user perspective

Source control with Subversion A user perspective http://svnbook.red-bean.com/ Source control with Subversion A user perspective Aaron Ponti What is Subversion? } It is a free and open-source version control system } It manages files and directories,

More information

Git. Christoph Matthies Software Engineering II WS 2018/19. Enterprise Platform and Integration Concepts group

Git. Christoph Matthies Software Engineering II WS 2018/19. Enterprise Platform and Integration Concepts group Git Software Engineering II WS 2018/19 Christoph Matthies christoph.matthies@hpi.de Enterprise Platform and Integration Concepts group Outline 1. Basics 2. Local 3. Collaboration November 16, 2018 2 Centralized

More information

I m an egotistical bastard, and I name all my projects after myself. First Linux, now git. Linus Torvalds, creator of Linux and Git

I m an egotistical bastard, and I name all my projects after myself. First Linux, now git. Linus Torvalds, creator of Linux and Git I m an egotistical bastard, and I name all my projects after myself. First Linux, now git. Linus Torvalds, creator of Linux and Git Git Benedict R. Gaster University of West of England November 23, 2015

More information

CESSDA Expert Seminar 13 & 14 September 2016 Prague, Czech Republic

CESSDA Expert Seminar 13 & 14 September 2016 Prague, Czech Republic CESSDA Expert Seminar 13 & 14 September 2016 Prague, Czech Republic - basics Matthäus Zloch GESIS Outline for this session Git introduction and some theory Git command basics (plus some little advanced)

More information

Introduction to distributed version control with git

Introduction 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 information

Configuration Management

Configuration Management Configuration Management VIMIMA11 Design and integration of embedded systems Budapest University of Technology and Economics Department of Measurement and Information Systems BME-MIT 2017 Configuration

More information

M E R C U R I A L (The Source Control Management)

M E R C U R I A L (The Source Control Management) M E R C U R I A L (The Source Control Management) Jamshaid Iqbal Janjua, Shahid Awan jamshaid.janjua@kics.edu.pk shahidawan@kics.edu.pk Al-Khawarizmi Institute of Computer Science University of Engineering

More information

Getting the files for the first time...2. Making Changes, Commiting them and Pull Requests:...5. Update your repository from the upstream master...

Getting the files for the first time...2. Making Changes, Commiting them and Pull Requests:...5. Update your repository from the upstream master... Table of Contents Getting the files for the first time...2 Making Changes, Commiting them and Pull Requests:...5 Update your repository from the upstream master...8 Making a new branch (for leads, do this

More information

An Introduction to Subversion

An Introduction to Subversion 1 An Introduction to Subversion Flavio Stanchi August 15, 2017 2 Table of Contents 1. Introduction What is Subversion? How to get Subversion? 2. Concepts Centralized version control Repository structure

More information