Version Control with. Ben Morgan

Size: px
Start display at page:

Download "Version Control with. Ben Morgan"

Transcription

1 Version Control with Ben Morgan

2 Developer Workflow Log what we did: Add foo support Edit Sources Add Files Compile and Test

3 Logbook ======= 1. Initial version Logbook ======= 1. Initial version 2. Remove using directive, use std Logbook ======= 1. Initial version 2. Remove using directive, use std 3. Output command line arguments to stdout Logging via a text file?

4 «database» «commit» Repository Working Copy Files Changes Files +- main.cc +- README.txt State +- main.cc +- README.txt 1 2-> <-- 7 «update» Version Control Systems Managing change and logs

5 Centralized Version Control My Working Copy Files State Central Repository Examples Your Working Copy Subversion CVS Perforce Files State

6 Distributed Version Control My Working Copy Files Files State Repo Repo State Central Repository Examples Git Mercurial Bazaar Your Working Copy

7 A Version Control Walkthrough with Git We haven t actually written anything yet, and this is the perfect time to get pp6calculator under version control so you can use it through the whole course. We ll be using git as our version control system, with github.com acting as our central repository. Why not SVN? It s slightly more awkward to get this set up and using github.com allows all of you to see how a central repository works. Aims of the walkthough: Create a local repository, add files, commit changes and make tags Show diffs and logs for the commits we ve made Create a central repo on GitHub, push our local changes to the new central repository

8 Tools you ll need

9 1: Project Organization First of all, we want to create a suitable directory structure to hold our project. Open a terminal session and check that you re in the HOME directory and cd to it if not. For this project, we need a two level directory structure, the reason for which will become apparent next week. We simply create directories mpagspp6/pp6calculator.git under HOME and cd into the bottom level directory: If you want to keep the mpagspp6 directory somewhere other than in HOME, that s fine. Directories holding git repositories are often named with a.git extension. This is not required, but is helpful in noting the directory as a repository!

10 2: Creating the Repository As pp6calculator.git is our working copy, and git is a distributed version control system, we create the repository in our working copy. Git makes this very easy, and all we need to do is run the simple command (in the pp6calculator.git directory!): $ git init All that init does is create the.git directory in the directory where it s run. You can use ls to explore the contents of this directory, which is where git stores all you changes. For more details on the contents, see the O Reilly text Version Control with Git or git-scm.com

11 3: Getting Help Ask us! If we re not around though, then man git will provide plenty of useful information. Like Subversion, git also provides a fast command line help interface, so you can also just type $ git help As the output of git help notes, to get help on a specific command, simply append its name to git help. It will open a man style page for the command (simply use q to exit this). Of course, also refer to text books and online resources such as git-scm.com.

12 4: Viewing Repository Status As we add and edit files, it s useful to keep track of the repository status without changing anything. With git, simply use the status command to view the current repository status: $ git status Of course at the moment, there s not much to report as we just have an empty repository. Get into the habit of running git status regularly to see what you ve changed.

13 5: Adding a README file We re going to start our project by adding a README for pp6calculator. This is a file that sits in the top level of the project and provides some basic information about what the project is, plus other information like installation instructions, authors and copyright/license details. Our README will be in plain text, using Markdown formatting. We use Markdown because it is human readable but easily convertible to other formats. Open your favourite text editor and begin to write your README, saving it as README.md Tips The example on the left shows the most basic README structure, but you can change it as you wish. We ll be adding to it later! Underlines using = are major sections, and those with - are subsections. When we upload our project to github, we ll see how these are displayed.

14 6: Adding the README.md File Having saved README.md, if you run git status again, you can see that git recognises a new file exists. To add this to the repository, and make hit track it in the future we use git s add command and then the status command to see the changes $ git add README.md staged files - Ready to be commited unstaged files - Changed but not staged untracked files - Not tracked by git yet deleted files - Deleted by git and ready for removal No color? See later!

15 7: Committing You ll have noticed that when you ran git status after adding README.md it only says Changes to be committed. Git stages changes before committing them to the repository. To store the changes we use the commit command with a message describing the changes: $ git commit -m Add skeleton README.md The staging area is a place to queue up (or remove) changes before they are committed. This is useful when we start to deal with multiple files. A commit is a snapshot of the repository. After the commit, status shows WC and repo in sync

16 8: Making Changes Now we ve staged and committed README.md, we can make some further changes. So edit your README.md, for example, add an empty section Installation. Save the file and run git status again. You ll see that git recognises we ve made changes, but these are not yet staged. To actually update the repository, we run git add again to stage the change then git commit to update the repository. This cycle of staging and committing is the basic git workflow. Try This Make a few more edits to README.md and use git add and git commit for each to get into the feel of staging and committing. Remember to use git status regularly to see what s happening!

17 9: Unstaging Changes So you ve staged a change, and then you realise it either breaks something or you want to add something else. As you may have noticed, git status actually tells you what to do in this case, so make a change, stage it up and then use reset to unstage it: $ git reset HEAD README.md If you have a change staged and simply want to add to it, simply use git add. That works even if for changes to the same file.

18 10: Viewing Logs We ve now made a few commits to our repository, so how do we go back and see what we ve done and why? Just use the log command! $ git log Plain log displays everything! To get the N most recent commits, use git log -nn. You can also use git log --summary to get a more detailed overview, though it doesn t show much as we ve only worked with one file.

19 11: Viewing Changes The basic log command shows the timeline of changes, but not what changed. To see what actually changed between commits, we can use git log -p or the diff command. Without any arguments, it shows a diff between the last commit and any local changes: $ git diff Git shows difference using the standard diff format for additions/removals. On the left, additions are in green, removals in red. Depending on the default configuration, the diff may be output to a pager, in which case use q to quit. No color? See later!

20 12: Changes between Commits As you ll have seen in using git log, git labels commits using a 40 character hash code (cf subversion s revision numbers). You can use these labels to view differences between any two commits, though because hashes are unique, you don t have to type out 80 characters! $ git diff a567 40a2 Hints The commit specifier needs to contain enough characters to uniquely identify the commit. The arguments to git diff can take a variety of forms. See man gitrevisions for more details, or the more helpful Git SCM Book! Try some of these out.

21 13: Writing Good Commit Messages Our edits so far have been simple and confined to one file. In these cases, a single line commit message using git commit -m commit message is completely sufficient (e.g. Fixed typographic errors ). As we start to make more involved commits involving several files, then we need to provide more detail. Because of the way git works with patches and , it tends to recommend the specific style of commit message listed below. Why? There s a good example in the text on the left (taken from a post by Tim Pope). If you fixed a bug you should say which bug, and how it was fixed. You might also say (and include in the commit) that a test has been added to check for the bug in the future.

22 14: Configuring Git To write more involved messages, we clearly don t want to type them out on the command line! Thankfully git is aware of modern editors, so we just need to make it aware of the one we want to use. The config command allows us to do this, as well as configure color output and so on $ git config --global <key> <value> Hints Git can use the EDITOR environment variable rather than core.editor You can configure git options globally (-- global) or locally in a repository (--local) Also see the Git SCM Book and try out some options!

23 15: Getting Started on Github Our repository is completely isolated at present, so if you want to work with it later on another machine, you need some way of sharing it. Whilst git is completely distributed, we can create a repository to be an authoritative one. We ll use the GitHub hosting service to do this, so if you do not have an account already, sign up for one now using the link below. Similar hosting services exist for other VCS, so this is not unique to git.

24 16: Creating a Repository Use the create new repo tool (highlighted below), naming it as you wish and creating a useful description. Make sure it s public (otherwise you have to pay!) and that the Initialize this repository with a README is unticked and that no.gitignore or license file is selected. We ll add and see what these are for in a bit. When you re happy, click the Create Repository button. BE CAREFUL: DON T create the repository with a README! That will conflict with the README in your repository! We don t create a.gitignore file for the same reason. If we create it, then our github repo has an initial commit, and can get confused with that in our local repo.

25 16: Creating a Repository Use the create new repo tool (highlighted below), naming it as you wish and creating a useful description. Make sure it s public (otherwise you have to pay!) and that the Initialize this repository with a README is unticked and that no.gitignore file is selected. We ll add and see what this is for in a bit. When you re happy, click the Create Repository button. All being well, you should see the screen on the left, but we need to take a little detour before we can connect the repository we ve been working with to our freshly created github repository.

26 17: Github and SSH Keys Whilst your repository is public, this only means others can browse your repository, but not push to it. In fact at this point, neither can you! The best way to connect to git is via ssh, and to do this we need to create an ssh keypair and make github aware of this. Github provide a very useful help system which walks you through the steps needed to do this, and this is linked below. It benefits from a little adaption, which is described in the notes. Step A Whilst github recommend https, ssh is actually a bit easier to setup, and likely to be more familiar. As you may already have some keys present, you can skip straight to Step 4 on the github page

27 17: Github and SSH Keys Whilst your repository is public, this only means others can browse your repository, but not push to it. In fact at this point, neither can you! The best way to connect to git is via ssh, and to do this we need to create an ssh keypair and make github aware of this. Github provide a very useful help system which walks you through the steps needed to do this, and this is linked below. It benefits from a little adaption, which is described in the notes. Step B Step 3 can be followed as is, but, it s useful to create a unique key for github. To do this, use the -f argument to ssh-keygen with the filename you want, or change the output file interactively.

28 17: Github and SSH Keys Whilst your repository is public, this only means others can browse your repository, but not push to it. In fact at this point, neither can you! The best way to connect to git is via ssh, and to do this we need to create an ssh keypair and make github aware of this. Final Note: You will need to create a keypair on each machine you connect from, so Warwick users will need to repeat these steps back home! Step C Steps 4 and 5 should be followed as is. If you have issues with connecting, you can edit the ~/.ssh/config file and add the stanza Host github.com User git Hostname github.com PreferredAuthentications publickey IdentityFile ~/.ssh/github_rsa if github_rsa is your private key

29 18: Pushing your Repository to Github Will ssh keys set up, we can return to the repository creation page. Github has actually provided instructions on how to push our local repository to Github: Push and existing repository from the command line. We go through the two steps needed in the next couple of slides Of course, if we were starting from scratch again, it would be easier to create the repository on Github first! We ve done the walkthrough this way to show that you can use git without github!

30 18: Pushing your Repository to Github First of all we use remote to add our github repository as a remote our our local one. Of course, use the correct details after the git@github.com: to point to your repository! $ git remote add origin git@github.com:<> Use -v to list remotes. You can add as many remotes as you want. For example, you could add one of your colleagues repositories, whether local or on github. That would allow you to share changes and updates. Of course, sufficient permissions are needed!

31 18: Pushing your Repository to Github With a remote added, we simply push our changes to the origin using the push command. If your github repository was created with a README.md, then you should pull (see next slide!!) before doing the following push: $ git push -u origin master You must have a clean local repository first! So before you add the remote, commit any local changes first. Note that the commands on the left do everything in one step. If you ve already added the remote, you don t need to do it again. master is roughly equivalent to trunk in SVN.

32 18a: Fixing Errors when Pushing to Github If you accidentally created your github repo with a README file, you will see an error along the lines of error: failed to push some refs to.... This is due to the remote and local repository not being in sync. To resolve this, we need to pull upstream changes, resolve conflicts, then push back to github. (git pull origin master, fix conflicts, git add, git commit, git push origin master) In general, git will try to be helpful when problems arise by outputting hints on how to resolve issues. Even if you find these confusing, plugging the error message into Google or StackOverflow will provide helpful answers.

33 19: Pulling Remote Changes For today, we ll be only working with our local repository and pushing to github. If changes have happened upstream on the github (or other remote), we can update our local repository with this changes using the pull command $ git pull origin master The pull command takes the remote to pull from and the refspec of changes. Updates in git can also be done in two steps using the fetch and merge commands. These are good for cherry picking changes. pull will be important in coming weeks!

34 20: Viewing your Github Repository Github provides a nice web interface for viewing your repository, the files in it and the history of changes. Of course, the command line is usually the core way of interacting with your local and remote repositories, the web based viewer and other GUI tools are very helpful. Of course, similar tools exist for other version control systems! Now we can see the advantage of writing our README in Markdown - Github has rendered it nicely for us! There s plenty more you can do with Markdown,

35 21: The.gitignore File When you run git status, git will report any files it doesn t track ( untracked ). In some cases we ll have files that we don t want git to track, for example files generated by the build or text editor temporaries, but we may accidentally add them to the repository (e.g. by git add.). To make git ignore these, we ll add a file named.gitignore in our repository. This contains a list of filename patterns that git should ignore, so open your text editor and write: You can also have a global ignores file. You could have a file named.global_gitignores in your HOME directory. Git can be made aware of this file by setting the core.excludesfile variable to point to it in the global git config

36 21: The.gitignore File Just like any other file,.gitignore should be tracked by the repository, so add it, commit and push to the origin: Once you ve pushed to the origin, refresh the webview of the repository on github. You should see the file added! If there are extra patterns you want to ignore, simply treat.gitignore like any other file. For more information, see man gitignore

37 22: Tagging We ve seen that in git, commits are described by a 40 character hash. At certain points in development, we ll want to mark a commit as a usable, stable piece of work. The hashes aren t an easy way of marking these points, so instead we create a tag. Current tags are listed via: $ git tag Tags can have any name, but git convention is vmajor.minor.patch for version numbers. Annotated tags are the best to use to begin with, as they can take extra info about the tag. Use show to see this info.

38 22: Tagging Like any other repository entry, tags can be pushed to a remote repository. However, push does not push tags by default. To do this, we have to either specify the tag name or use the --tags argument: $ git push origin v0.1.0 You should always push tags so they appear when others pull from your remote repo (including you!). If you look on your github repository, you should see a 1 next to the Tags. Clicking on this will take you an interface where you can download a source archive for you code at the tag!

39 23: And we re done That about covers the basic usage of git and github. All of the techniques are applicable to other VCSs you may work with, of particular importance being the writing of good commit messages so you (and your collaborators) know not only what changes were done, but why! As we move through the course, remember to stage and commit your files regularly when you have got something working (you should never commit code that doesn t work for you!). Use tags at the end of each day to record your work at those points, again, the tag should work! Don t Forget Resources The Following Slides Describe how to Work With your Repository Outside of Birmingham!

40 I: Cloning Your Repository If you want to work with your repository outside of the Birmingham Workstations, e.g. at Warwick, or on a laptop, then you can simply clone it from github. You will first need to set up ssh keys just as we did earlier and upload the public key to github. The use clone: $ git clone <repo> <dir> If you see any problems here, check your local ssh settings and the public keys on github. You can make changes in your cloned repo without needing a network connection - pushing them to github later.

41 II: Homework and Future Weeks... Outside of the course, you can work with your repository as you wish. Birmingham people may just work locally, pushing their changes up to github. Warwick people, or anybody using a laptop can take a clone of your github repository, work on the clone and then push changes up to github. In any case, before next week, make sure you have pushed all your changes to github. Then to begin work again, simply pull the changes into your repository at Birmingham! Homework Whilst the homeworks will concentrate on coding, remember to keep your README file up to date, and make regular commits and pushes. When your homework on pp6calculator is complete, make a tag so we have a reference we can access!

Git Basics. Christopher Simpkins chris.simpkins@gatech.edu. Chris Simpkins (Georgia Tech) CS 2340 Objects and Design CS 1331 1 / 22

Git Basics. Christopher Simpkins chris.simpkins@gatech.edu. Chris Simpkins (Georgia Tech) CS 2340 Objects and Design CS 1331 1 / 22 Git Basics Christopher Simpkins chris.simpkins@gatech.edu Chris Simpkins (Georgia Tech) CS 2340 Objects and Design CS 1331 1 / 22 Version Control Systems Records changes to files over time Allows you to

More information

Version control. with git and GitHub. Karl Broman. Biostatistics & Medical Informatics, UW Madison

Version control. with git and GitHub. Karl Broman. Biostatistics & Medical Informatics, UW Madison Version control with git and GitHub Karl Broman Biostatistics & Medical Informatics, UW Madison kbroman.org github.com/kbroman @kwbroman Course web: kbroman.org/tools4rr Slides prepared with Sam Younkin

More information

Version Control with Svn, Git and git-svn. Kate Hedstrom ARSC, UAF

Version Control with Svn, Git and git-svn. Kate Hedstrom ARSC, UAF 1 Version Control with Svn, Git and git-svn Kate Hedstrom ARSC, UAF 2 Version Control Software System for managing source files For groups of people working on the same code When you need to get back last

More information

Introduction to Git. Markus Kötter koetter@rrzn.uni-hannover.de. Notes. Leinelab Workshop July 28, 2015

Introduction to Git. Markus Kötter koetter@rrzn.uni-hannover.de. Notes. Leinelab Workshop July 28, 2015 Introduction to Git Markus Kötter koetter@rrzn.uni-hannover.de Leinelab Workshop July 28, 2015 Motivation - Why use version control? Versions in file names: does this look familiar? $ ls file file.2 file.

More information

MATLAB & Git Versioning: The Very Basics

MATLAB & Git Versioning: The Very Basics 1 MATLAB & Git Versioning: The Very Basics basic guide for using git (command line) in the development of MATLAB code (windows) The information for this small guide was taken from the following websites:

More information

Version Control with Git. Kate Hedstrom ARSC, UAF

Version Control with Git. Kate Hedstrom ARSC, UAF 1 Version Control with Git Kate Hedstrom ARSC, UAF Linus Torvalds 3 Version Control Software System for managing source files For groups of people working on the same code When you need to get back last

More information

Using Git for Project Management with µvision

Using Git for Project Management with µvision MDK Version 5 Tutorial AN279, Spring 2015, V 1.0 Abstract Teamwork is the basis of many modern microcontroller development projects. Often teams are distributed all over the world and over various time

More information

Version Control! Scenarios, Working with Git!

Version Control! Scenarios, Working with Git! Version Control! Scenarios, Working with Git!! Scenario 1! You finished the assignment at home! VC 2 Scenario 1b! You finished the assignment at home! You get to York to submit and realize you did not

More information

Version Control Systems (Part 2)

Version Control Systems (Part 2) 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

Version Control with Git. Linux Users Group UT Arlington. Rohit Rawat rohitrawat@gmail.com

Version Control with Git. Linux Users Group UT Arlington. Rohit Rawat rohitrawat@gmail.com Version Control with Git Linux Users Group UT Arlington Rohit Rawat rohitrawat@gmail.com Need for Version Control Better than manually storing backups of older versions Easier to keep everyone updated

More information

Introduction to the Git Version Control System

Introduction to the Git Version Control System Introduction to the Sebastian Rockel rockel@informatik.uni-hamburg.de University of Hamburg Faculty of Mathematics, Informatics and Natural Sciences Department of Informatics Technical Aspects of Multimodal

More information

Introducing Xcode Source Control

Introducing Xcode Source Control APPENDIX A Introducing Xcode Source Control What You ll Learn in This Appendix: u The source control features offered in Xcode u The language of source control systems u How to connect to remote Subversion

More information

Two Best Practices for Scientific Computing

Two Best Practices for Scientific Computing Two Best Practices for Scientific Computing Version Control Systems & Automated Code Testing David Love Software Interest Group University of Arizona February 18, 2013 How This Talk Happened Applied alumnus,

More information

Version control with GIT

Version control with GIT AGV, IIT Kharagpur September 13, 2012 Outline 1 Version control system What is version control Why version control 2 Introducing GIT What is GIT? 3 Using GIT Using GIT for AGV at IIT KGP Help and Tips

More information

Version Control with Git. Dylan Nugent

Version Control with Git. Dylan Nugent Version Control with Git Dylan Nugent Agenda What is Version Control? (and why use it?) What is Git? (And why Git?) How Git Works (in theory) Setting up Git (surviving the CLI) The basics of Git (Just

More information

Version Control Systems

Version Control Systems Version Control Systems ESA 2015/2016 Adam Belloum a.s.z.belloum@uva.nl Material Prepared by Eelco Schatborn Today IntroducGon to Version Control Systems Centralized Version Control Systems RCS CVS SVN

More information

MOOSE-Based Application Development on GitLab

MOOSE-Based Application Development on GitLab MOOSE-Based Application Development on GitLab MOOSE Team Idaho National Laboratory September 9, 2014 Introduction The intended audience for this talk is developers of INL-hosted, MOOSE-based applications.

More information

The Hitchhiker s Guide to Github: SAS Programming Goes Social Jiangtang Hu d-wise Technologies, Inc., Morrisville, NC

The Hitchhiker s Guide to Github: SAS Programming Goes Social Jiangtang Hu d-wise Technologies, Inc., Morrisville, NC Paper PA-04 The Hitchhiker s Guide to Github: SAS Programming Goes Social Jiangtang Hu d-wise Technologies, Inc., Morrisville, NC ABSTRACT Don't Panic! Github is a fantastic way to host, share, and collaborate

More information

Version Control for Computational Economists: An Introduction

Version Control for Computational Economists: An Introduction Version Control for Computational Economists: An Introduction Jake C. Torcasso April 3, 2014 Starting Point A collection of files on your computer Changes to files and new files over time Interested in

More information

The Bazaar Version Control System. Michael Hudson, Canonical Ltd michael.hudson@canonical.com

The Bazaar Version Control System. Michael Hudson, Canonical Ltd michael.hudson@canonical.com The Bazaar Version Control System Michael Hudson, Canonical Ltd michael.hudson@canonical.com What is Bazaar? Bazaar is a Distributed Version Control System (DVCS) You probably know what a VCS is by now:

More information

Version Control using Git and Github. Joseph Rivera

Version Control using Git and Github. Joseph Rivera Version Control using Git and Github Joseph Rivera 1 What is Version Control? Powerful development tool! Management of additions, deletions, and modifications to software/source code or more generally

More information

Introduction to Version Control

Introduction to Version Control Research Institute for Symbolic Computation Johannes Kepler University Linz, Austria Winter semester 2014 Outline General Remarks about Version Control 1 General Remarks about Version Control 2 Outline

More information

Version control. HEAD is the name of the latest revision in the repository. It can be used in subversion rather than the latest revision number.

Version control. HEAD is the name of the latest revision in the repository. It can be used in subversion rather than the latest revision number. Version control Version control is a powerful tool for many kinds of work done over a period of time, including writing papers and theses as well as writing code. This session gives a introduction to a

More information

Git Basics. Christian Hanser. Institute for Applied Information Processing and Communications Graz University of Technology. 6.

Git Basics. Christian Hanser. Institute for Applied Information Processing and Communications Graz University of Technology. 6. Git Basics Christian Hanser Institute for Applied Information Processing and Communications Graz University of Technology 6. March 2013 Christian Hanser 6. March 2013 Seite 1/39 Outline Learning Targets

More information

CPSC 491. Today: Source code control. Source Code (Version) Control. Exercise: g., no git, subversion, cvs, etc.)

CPSC 491. Today: Source code control. Source Code (Version) Control. Exercise: g., no git, subversion, cvs, etc.) Today: Source code control CPSC 491 Source Code (Version) Control Exercise: 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

More information

FEEG6002 - Applied Programming 3 - Version Control and Git II

FEEG6002 - Applied Programming 3 - Version Control and Git II FEEG6002 - Applied Programming 3 - Version Control and Git II Sam Sinayoko 2015-10-16 1 / 26 Outline Learning outcomes Working with a single repository (review) Working with multiple versions of a repository

More information

Version Control with Subversion and Xcode

Version Control with Subversion and Xcode Version Control with Subversion and Xcode Author: Mark Szymczyk Last Update: June 21, 2006 This article shows you how to place your source code files under version control using Subversion and Xcode. By

More information

An Introduction to Mercurial Version Control Software

An Introduction to Mercurial Version Control Software An Introduction to Mercurial Version Control Software CS595, IIT [Doc Updated by H. Zhang] Oct, 2010 Satish Balay balay@mcs.anl.gov Outline Why use version control? Simple example of revisioning Mercurial

More information

Git - Working with Remote Repositories

Git - Working with Remote Repositories Git - Working with Remote Repositories Handout New Concepts Working with remote Git repositories including setting up remote repositories, cloning remote repositories, and keeping local repositories in-sync

More information

Lab Exercise Part II: Git: A distributed version control system

Lab Exercise Part II: Git: A distributed version control system Lunds tekniska högskola Datavetenskap, Nov 25, 2013 EDA260 Programvaruutveckling i grupp projekt Labb 2 (part II: Git): Labbhandledning Checked on Git versions: 1.8.1.2 Lab Exercise Part II: Git: A distributed

More information

Source Control Systems

Source Control Systems Source Control Systems SVN, Git, GitHub SoftUni Team Technical Trainers Software University http://softuni.bg Table of Contents 1. Software Configuration Management (SCM) 2. Version Control Systems: Philosophy

More information

Version Control with Git

Version Control with Git Version Control with Git Ben Wasserman (benjamin@cmu.edu) 15-441 Computer Networks Recitation 3 1/28 What is version control? Revisit previous code versions Backup projects Work with others Find where

More information

CSE 374 Programming Concepts & Tools. Laura Campbell (Thanks to Hal Perkins) Winter 2014 Lecture 16 Version control and svn

CSE 374 Programming Concepts & Tools. Laura Campbell (Thanks to Hal Perkins) Winter 2014 Lecture 16 Version control and svn CSE 374 Programming Concepts & Tools Laura Campbell (Thanks to Hal Perkins) Winter 2014 Lecture 16 Version control and svn Where we are Learning tools and concepts relevant to multi-file, multi-person,

More information

Version Control with Git

Version Control with Git Version Control with Git Claudius Coenen License: CC-BY-4.0 What We're Not Talking About Conceived by Linus Torvalds around 2005 Distributed Version Control vs. Central Version Control Why git is better

More information

Using GitHub for Rally Apps (Mac Version)

Using GitHub for Rally Apps (Mac Version) Using GitHub for Rally Apps (Mac Version) SOURCE DOCUMENT (must have a rallydev.com email address to access and edit) Introduction Rally has a working relationship with GitHub to enable customer collaboration

More information

Version Control with Subversion

Version Control with Subversion Version Control with Subversion Introduction Wouldn t you like to have a time machine? Software developers already have one! it is called version control Version control (aka Revision Control System or

More information

Xcode Source Management Guide. (Legacy)

Xcode Source Management Guide. (Legacy) Xcode Source Management Guide (Legacy) Contents Introduction 5 Organization of This Document 5 See Also 6 Source Management Overview 7 Source Control Essentials 7 Snapshots 8 Managing Source in Xcode 8

More information

An Introduction to Git Version Control for SAS Programmers

An Introduction to Git Version Control for SAS Programmers ABSTRACT An Introduction to Git Version Control for SAS Programmers Stephen Philp, Pelican Programming, Redondo Beach, CA Traditionally version control has been in the domain of the enterprise: either

More information

Content. Development Tools 2(63)

Content. Development Tools 2(63) Development Tools Content Project management and build, Maven Version control, Git Code coverage, JaCoCo Profiling, NetBeans Static Analyzer, NetBeans Continuous integration, Hudson Development Tools 2(63)

More information

MATLAB @ Work. MATLAB Source Control Using Git

MATLAB @ Work. MATLAB Source Control Using Git MATLAB @ Work MATLAB Source Control Using Git Richard Johnson Using source control is a key practice for professional programmers. If you have ever broken a program with a lot of editing changes, you can

More information

Version Control Tutorial using TortoiseSVN and. TortoiseGit

Version Control Tutorial using TortoiseSVN and. TortoiseGit Version Control Tutorial using TortoiseSVN and TortoiseGit Christopher J. Roy, Associate Professor Virginia Tech, cjroy@vt.edu This tutorial can be found at: www.aoe.vt.edu/people/webpages/cjroy/software-resources/tortoise-svn-git-tutorial.pdf

More information

Using Microsoft Azure for Students

Using Microsoft Azure for Students Using Microsoft Azure for Students Dive into Azure through Microsoft Imagine s free new offer and learn how to develop and deploy to the cloud, at no cost! To take advantage of Microsoft s cloud development

More information

Version Control. Version Control

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

More information

PKI, Git and SVN. Adam Young. Presented by. Senior Software Engineer, Red Hat. License Licensed under http://creativecommons.org/licenses/by/3.

PKI, Git and SVN. Adam Young. Presented by. Senior Software Engineer, Red Hat. License Licensed under http://creativecommons.org/licenses/by/3. PKI, Git and SVN Presented by Adam Young Senior Software Engineer, Red Hat License Licensed under http://creativecommons.org/licenses/by/3.0/ Agenda Why git Getting started Branches Commits Why? Saved

More information

Version Control Script

Version Control Script Version Control Script Mike Jackson, The Software Sustainability Institute Things you should do are written in bold. Suggested dialog is in normal text. Command- line excerpts and code fragments are in

More information

CS 2112 Lab: Version Control

CS 2112 Lab: Version Control 29 September 1 October, 2014 Version Control What is Version Control? You re emailing your project back and forth with your partner. An hour before the deadline, you and your partner both find different

More information

Version Control Systems: SVN and GIT. How do VCS support SW development teams?

Version Control Systems: SVN and GIT. How do VCS support SW development teams? Version Control Systems: SVN and GIT How do VCS support SW development teams? CS 435/535 The College of William and Mary Agile manifesto We are uncovering better ways of developing software by doing it

More information

Source Code Management for Continuous Integration and Deployment. Version 1.0 DO NOT DISTRIBUTE

Source Code Management for Continuous Integration and Deployment. Version 1.0 DO NOT DISTRIBUTE Source Code Management for Continuous Integration and Deployment Version 1.0 Copyright 2013, 2014 Amazon Web Services, Inc. and its affiliates. All rights reserved. This work may not be reproduced or redistributed,

More information

Data management on HPC platforms

Data management on HPC platforms Data management on HPC platforms Transferring data and handling code with Git scitas.epfl.ch September 10, 2015 http://bit.ly/1jkghz4 What kind of data Categorizing data to define a strategy Based on size?

More information

Git. A Distributed Version Control System. Carlos García Campos carlosgc@gsyc.es

Git. A Distributed Version Control System. Carlos García Campos carlosgc@gsyc.es Git A Distributed Version Control System Carlos García Campos carlosgc@gsyc.es Carlos García Campos carlosgc@gsyc.es - Git 1 A couple of Quotes For the first 10 years of kernel maintenance, we literally

More information

Using Subversion in Computer Science

Using Subversion in Computer Science School of Computer Science 1 Using Subversion in Computer Science Last modified July 28, 2006 Starting from semester two, the School is adopting the increasingly popular SVN system for management of student

More information

Annoyances with our current source control Can it get more comfortable? Git Appendix. Git vs Subversion. Andrey Kotlarski 13.XII.

Annoyances with our current source control Can it get more comfortable? Git Appendix. Git vs Subversion. Andrey Kotlarski 13.XII. Git vs Subversion Andrey Kotlarski 13.XII.2011 Outline Annoyances with our current source control Can it get more comfortable? Git Appendix Rant Network traffic Hopefully we have good repository backup

More information

An Introduction to Collaborating with Version Control

An Introduction to Collaborating with Version Control An Introduction to Collaborating with Version Control Created by Brennen Bearnes Last updated on 2015-07-21 12:20:13 PM EDT Guide Contents Guide Contents Overview Version Control? What? What's So Special

More information

Introduc)on to Version Control with Git. Pradeep Sivakumar, PhD Sr. Computa5onal Specialist Research Compu5ng, NUIT

Introduc)on to Version Control with Git. Pradeep Sivakumar, PhD Sr. Computa5onal Specialist Research Compu5ng, NUIT Introduc)on to Version Control with Git Pradeep Sivakumar, PhD Sr. Computa5onal Specialist Research Compu5ng, NUIT Contents 1. What is Version Control? 2. Why use Version control? 3. What is Git? 4. Create

More information

Git Branching for Continuous Delivery

Git Branching for Continuous Delivery Git Branching for Continuous Delivery Sarah Goff-Dupont Automation Enthusiast Hello everyone I ll be talking about how teams at Atlassian use Git branches for continuous delivery. My name is Sarah, and

More information

So you want to create an Email a Friend action

So you want to create an Email a Friend action So you want to create an Email a Friend action This help file will take you through all the steps on how to create a simple and effective email a friend action. It doesn t cover the advanced features;

More information

CSCB07 Software Design Version Control

CSCB07 Software Design Version Control CSCB07 Software Design Version Control Anya Tafliovich Fall 2015 Problem I: 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

More information

Version control systems. Lecture 2

Version control systems. Lecture 2 Version control systems Lecture 2 VCS Many people s version- control method of choice is to copy files into another directory (e.g. a @me- stamped directory). But this approach is error prone. Easy to

More information

How to set up SQL Source Control. The short guide for evaluators

How to set up SQL Source Control. The short guide for evaluators How to set up SQL Source Control The short guide for evaluators Content Introduction Team Foundation Server & Subversion setup Git setup Setup without a source control system Making your first commit Committing

More information

Pro Git. Scott Chacon * 2010-08-02

Pro Git. Scott Chacon * 2010-08-02 Pro Git Scott Chacon * 2010-08-02 * This is the PDF file for the Pro Git book contents. It is licensed under the Creative Commons Attribution-Non Commercial-Share Alike 3.0 license. I hope you enjoy it,

More information

Advanced Computing Tools for Applied Research Chapter 4. Version control

Advanced Computing Tools for Applied Research Chapter 4. Version control Advanced Computing Tools for Applied Research Jaime Boal Martín-Larrauri Rafael Palacios Hielscher Academic year 2014/2015 1 Version control fundamentals 2 What you probably do now Manually save copies

More information

CISC 275: Introduction to Software Engineering. Lab 5: Introduction to Revision Control with. Charlie Greenbacker University of Delaware Fall 2011

CISC 275: Introduction to Software Engineering. Lab 5: Introduction to Revision Control with. Charlie Greenbacker University of Delaware Fall 2011 CISC 275: Introduction to Software Engineering Lab 5: Introduction to Revision Control with Charlie Greenbacker University of Delaware Fall 2011 Overview Revision Control Systems in general Subversion

More information

UNIVERSITY OF CALIFORNIA Department of Electrical Engineering and Computer Sciences Computer Science Division. P. N. Hilfinger

UNIVERSITY OF CALIFORNIA Department of Electrical Engineering and Computer Sciences Computer Science Division. P. N. Hilfinger UNIVERSITY OF CALIFORNIA Department of Electrical Engineering and Computer Sciences Computer Science Division CS 61B Fall 2012 P. N. Hilfinger Version Control and Homework Submission 1 Introduction Your

More information

Version Control with Mercurial and SSH

Version Control with Mercurial and SSH Version Control with Mercurial and SSH Lasse Kliemann lki@informatik.uni-kiel.de Vorkurs Informatik 2010 Wishlist While working on a project, it is nice to... be able to switch back to older versions of

More information

Dalhousie University CSCI 2132 Software Development Winter 2015 Lab 7, March 11

Dalhousie University CSCI 2132 Software Development Winter 2015 Lab 7, March 11 Dalhousie University CSCI 2132 Software Development Winter 2015 Lab 7, March 11 In this lab, you will first learn how to use pointers to print memory addresses of variables. After that, you will learn

More information

An Introduction to Mercurial Version Control Software

An Introduction to Mercurial Version Control Software An Introduction to Mercurial Version Control Software LANS Weekly Seminar October 17, 2006 Satish Balay balay@mcs.anl.gov Outline Why use version control? Simple example of revisioning Mercurial introduction

More information

Unity Version Control

Unity Version Control Unity Version Control with BitBucket.org and SourceTree BLACKISH - last updated: April 2013 http://blog.blackish.at http://blackish-games.com! Table of Contents Setup! 3 Join an existing repository! 4

More information

Hypercosm. Studio. www.hypercosm.com

Hypercosm. Studio. www.hypercosm.com Hypercosm Studio www.hypercosm.com Hypercosm Studio Guide 3 Revision: November 2005 Copyright 2005 Hypercosm LLC All rights reserved. Hypercosm, OMAR, Hypercosm 3D Player, and Hypercosm Studio are trademarks

More information

BlueJ Teamwork Tutorial

BlueJ Teamwork Tutorial BlueJ Teamwork Tutorial Version 2.0 for BlueJ Version 2.5.0 (and 2.2.x) Bruce Quig, Davin McCall School of Engineering & IT, Deakin University Contents 1 OVERVIEW... 3 2 SETTING UP A REPOSITORY... 3 3

More information

Introduction to Version Control with Git

Introduction to Version Control with Git Introduction to Version Control with Git Dark Cosmology Centre Niels Bohr Institute License All images adapted from Pro Git by Scott Chacon and released under license Creative Commons BY-NC-SA 3.0. See

More information

Software Configuration Management and Continuous Integration

Software Configuration Management and Continuous Integration 1 Chapter 1 Software Configuration Management and Continuous Integration Matthias Molitor, 1856389 Reaching and maintaining a high quality level is essential for each today s software project. To accomplish

More information

Distributed Version Control with Mercurial and git

Distributed Version Control with Mercurial and git OpenStax-CNX module: m37404 1 Distributed Version Control with Mercurial and git Hannes Hirzel This work is produced by OpenStax-CNX and licensed under the Creative Commons Attribution License 3.0 Abstract

More information

Version control with Subversion

Version control with Subversion Version control with Subversion Davor Cubranic Grad Seminar October 6, 2011 With searching comes loss And the presence of absence: My Thesis not found. Version Control A tool for managing changes to a

More information

The Social Accelerator Setup Guide

The Social Accelerator Setup Guide The Social Accelerator Setup Guide Welcome! Welcome to the Social Accelerator setup guide. This guide covers 2 ways to setup SA. Most likely, you will want to use the easy setup wizard. In that case, you

More information

Putting It All Together. Vagrant Drush Version Control

Putting It All Together. Vagrant Drush Version Control Putting It All Together Vagrant Drush Version Control Vagrant Most Drupal developers now work on OSX. The Vagarant provisioning scripts may not work on Windows without subtle changes. If supplied, read

More information

Revision control systems (RCS) and

Revision control systems (RCS) and 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

Derived from Chris Cannam's original at, https://code.soundsoftware.ac.uk/projects/easyhg/wiki/sc2012bootcamppl an.

Derived from Chris Cannam's original at, https://code.soundsoftware.ac.uk/projects/easyhg/wiki/sc2012bootcamppl an. Version Control Key Points ========================== Mike Jackson, The Software Sustainability Institute. This work is licensed under the Creative Commons Attribution License. Copyright (c) Software Carpentry

More information

Mercurial. Why version control (Single users)

Mercurial. Why version control (Single users) Mercurial Author: Hans Fangohr Date: 2008-05-21 Version: 033c85b22987 Id: talk.txt,v 033c85b22987 2008/05/21 08:42:42 fangohr Series: SESA2006 2008, last lecture Hint Adjust font-size

More information

Introduction to Subversion

Introduction to Subversion Introduction to Subversion Getting started with svn Matteo Vescovi 19/02/2010 Agenda A little bit of theory Overview of Subversion Subversion approach to Version Control Using Subversion Typical subversion

More information

Continuous Integration. CSC 440: Software Engineering Slide #1

Continuous Integration. CSC 440: Software Engineering Slide #1 Continuous Integration CSC 440: Software Engineering Slide #1 Topics 1. Continuous integration 2. Configuration management 3. Types of version control 1. None 2. Lock-Modify-Unlock 3. Copy-Modify-Merge

More information

Software configuration management

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

More information

using version control in system administration

using version control in system administration LUKE KANIES using version control in system administration Luke Kanies runs Reductive Labs (http://reductivelabs.com), a startup producing OSS software for centralized, automated server administration.

More information

Palantir.net presents Git

Palantir.net presents Git Palantir.net presents Git Branching, Merging, Commits, and Tagging: Basics and Best Practices Git Started This assumes you already have a repo. Instructions for that are already on Github. Branching BRANCHING

More information

Introduction to Version Control with Git

Introduction to Version Control with Git Introduction to Version Control with Git Dark Cosmology Centre Niels Bohr Institute License Most images adapted from Pro Git by Scott Chacon and released under license Creative Commons BY-NC-SA 3.0. See

More information

Version Uncontrolled! : How to Manage Your Version Control

Version Uncontrolled! : How to Manage Your Version Control Version Uncontrolled! : How to Manage Your Version Control Harold Dost III, Raastech ABSTRACT Are you constantly wondering what is in your production environment? Do you have any doubts about what code

More information

Introduction to Source Control ---

Introduction to Source Control --- Introduction to Source Control --- Overview Whether your software project is large or small, it is highly recommended that you use source control as early as possible in the lifecycle of your project.

More information

Setting up a local working copy with SVN, MAMP and rsync. Agentic - 2009

Setting up a local working copy with SVN, MAMP and rsync. Agentic - 2009 Setting up a local working copy with SVN, MAMP and rsync Agentic - 2009 Get MAMP You can download MAMP for MAC at this address : http://www.mamp.info/en/downloads/index.html Install MAMP in your APPLICATION

More information

Jenkins on Windows with StreamBase

Jenkins on Windows with StreamBase Jenkins on Windows with StreamBase Using a Continuous Integration (CI) process and server to perform frequent application building, packaging, and automated testing is such a good idea that it s now a

More information

Using SVN to Manage Source RTL

Using SVN to Manage Source RTL Using SVN to Manage Source RTL CS250 Tutorial 1 (Version 092509a) September 25, 2009 Yunsup Lee In this tutorial you will gain experience using the Subversion (SVN) to manage your source RTL and code.

More information

Outlook 2010 and 2013

Outlook 2010 and 2013 Outlook 2010 and 2013 Email Setup Account Types 2 Exchange account 3 POP account 5 Maintenance Setting up an Email signature 7 Checking Email Storage 8 Archiving Emails 9 Sharing Calendars Giving Access

More information

CEFNS Web Hosting a Guide for CS212

CEFNS Web Hosting a Guide for CS212 CEFNS Web Hosting a Guide for CS212 INTRODUCTION: TOOLS: In CS212, you will be learning the basics of web development. Therefore, you want to keep your tools to a minimum so that you understand how things

More information

PLESK 7 NEW FEATURES HOW-TO RESOURCES

PLESK 7 NEW FEATURES HOW-TO RESOURCES PLESK 7 NEW FEATURES HOW-TO RESOURCES Copyright (C) 1999-2004 SWsoft, Inc. All rights reserved. Distribution of this work or derivative of this work in any form is prohibited unless prior written permission

More information

Version Control with Subversion

Version Control with Subversion Version Control with Subversion http://www.oit.duke.edu/scsc/ http://wiki.duke.edu/display/scsc scsc@duke.edu John Pormann, Ph.D. jbp1@duke.edu Software Carpentry Courseware This is a re-work from the

More information

To reduce or not to reduce, that is the question

To reduce or not to reduce, that is the question To reduce or not to reduce, that is the question 1 Running jobs on the Hadoop cluster For part 1 of assignment 8, you should have gotten the word counting example from class compiling. To start with, let

More information

Git in control of your Change Management

Git in control of your Change Management Synopsis Git in control of your Change Management Git is a free Version Control System. It is designed for use by software developers, and quite popular for that purpose. The essence of Version Control

More information

Yocto Project Eclipse plug-in and Developer Tools Hands-on Lab

Yocto Project Eclipse plug-in and Developer Tools Hands-on Lab Yocto Project Eclipse plug-in and Developer Tools Hands-on Lab Yocto Project Developer Day San Francisco, 2013 Jessica Zhang Introduction Welcome to the Yocto Project Eclipse plug-in

More information

VFP Version Control with Mercurial

VFP Version Control with Mercurial This paper was originally presented at the Southwest Fox conference in Gilbert, Arizona in October, 2011. http://www.swfox.net VFP Version Control with Mercurial Rick Borup Information Technology Associates

More information

STABLE & SECURE BANK lab writeup. Page 1 of 21

STABLE & SECURE BANK lab writeup. Page 1 of 21 STABLE & SECURE BANK lab writeup 1 of 21 Penetrating an imaginary bank through real present-date security vulnerabilities PENTESTIT, a Russian Information Security company has launched its new, eighth

More information

Using SVN to Manage Source RTL

Using SVN to Manage Source RTL Using SVN to Manage Source RTL CS250 Tutorial 1 (Version 083010a) August 30, 2010 Yunsup Lee In this tutorial you will gain experience using the Subversion (SVN) to manage your source RTL and code. You

More information

A Git Development Environment

A Git Development Environment A Git Development Environment Installing and using Git for Drupal and WordPress site development using Ubuntu/Mint and a Hostgator Reseller or VPS account. By: Andrew Tuline Date: February 7, 2014 Version:

More information