KIT – University of the State of Baden-Wuerttemberg and National Research Center of the Helmholtz Association STEINBUCH CENTRE FOR COMPUTING - SCC

Slides:



Advertisements
Similar presentations
Introduction To GIT Rob Di Marco Philly Linux Users Group July 14, 2008.
Advertisements

om om GIT - Tips & Tricks / git.dvcs git-tips.com
Patterns & practices Symposium 2013 Introducing Git version control into your team Mark
Version Control with git. Version Control Version control is a system that records changes to a file or set of files over time so that you can recall.
1 CSE 390 “Lecture 11” Version control with Git slides created by Ruth Anderson, images from
Introduction to Git and Github Joshua imtraum.com.
Git for Version Control These slides are heavily based on slides created by Ruth Anderson for CSE 390a. Thanks, Ruth! images taken from
Git. What’s Git? A British swear A Distributed Version Control System Developed in 2005 by Linus Torvalds for use on the Linux Kernel Git Logo by Jason.
علیرضا فراهانی استاد درس: جعفری نژاد مهر Version Control ▪Version control is a system that records changes to a file or set of files over time so.
Git – versioning and managing your software L. Grewe.
GIT An introduction to GIT Source Control. What is GIT (1 of 2) ▪ “Git is a free and open source distributed version control system designed to handle.
1 Introductory Notes on the Git Source Control Management Ric Holt, 8 Oct 2009.
Version control Using Git Version control, using Git1.
Version Control Systems academy.zariba.com 1. Lecture Content 1.What is Software Configuration Management? 2.Version Control Systems (VCS) 3.Basic Git.
…using Git/Tortoise Git
Git workflow and basic commands By: Anuj Sharma. Why git? Git is a distributed revision control system with an emphasis on speed, data integrity, and.
SWEN 302: AGILE METHODS Roma Klapaukh & Alex Potanin.
Team 708 – Hardwired Fusion Created by Nam Tran 2014.
1 GIT NOUN \’GIT\ A DISTRIBUTED REVISION CONTROL AND SOURCE CODE MANAGEMENT (SCM) SYSTEM WITH AN EMPHASIS ON SPEED. INITIALLY DESIGNED AND DEVELOPED BY.
Sofia Event Center May 2014 Martin Kulov Git For TFS Developers.
Version Control System Lisa Palathingal 03/04/2015.
GIT.
Intro to Git presented by Brian K. Vagnini Hosted by.
Introduction to Git Yonglei Tao GVSU. Version Control Systems  Also known as Source Code Management systems  Increase your productivity by allowing.
© 2015 by Herb Holyst Introduction to git Cytomics Workshop December, 2015.
It’s not just an insult from Harry Potter!. What is Git? Distributed Version Control System (DVCS) – Compared to a Centralized Version Control System.
Introduction to Git - Chirag Dani. Objectives Basics of Git Understanding different “Mindset of Git” Demo - Git with Visual Studio.
Git How to 1. Why Git To resolve problems in lab exams (accidental deletions) Use existing Libraries with ease (Statistics and Computer) Prepare undergraduates.
1. A new git is initialized as a remote repository JohnRemote repositoryPeter master C0 CodingWhileBlack.com PROPEL CODING
Getting Started with Git Presented by Jim Taylor Rooty Hollow, Owner Verizon Wireless, Senior Programmer/Analyst Git User for 6 years.
Jun-Ru Chang Introduction GIT Jun-Ru Chang
GIT Version control. Version Control Sharing code via a centralized DB Also provides for Backtracking (going back to a previous version of code), Branching.
Git Girish Git VCS that I have used ClearCase, cvs, svn Happy p4 user.
Backing up a machine with git
Introduction to Git and git-svn Paul Gier Red Hat Sept. 27, 2011.
CS5220 Advanced Topics in Web Programming Version Control with Git
M.Sc. Juan Carlos Olivares Rojas
4 Version control (part 1)
I Don’t Git It: A beginner’s guide to git Presented by Mathew Robinson
Primož Gabrijelčič Git for Programmers Primož Gabrijelčič
Version Control Systems
11 Version control (part 2)
CReSIS Git Tutorial.
LECTURE 2: Software Configuration Management
Git Practice walkthrough.
Version control, using Git
File Version Control System
Git for Visual Studio Developers MARTIN KULOV, ASE
Version Control System using Git
Software Engineering for Data Scientists
Macaualy2 Workshop Berkeley 2017
Storing, Sending, and Tracking Files Recitation 2
SU Development Forum Introduction to Git - Save your projects!
Git Workflows.
Distributed Version Control with git
Akshay Narayan git up to speed with RCS Akshay Narayan
LECTURE 3: Software Configuration Management
The Big Picture
SIG: Open Week 1: GitHub Tim Choh.
Source Code Repository
Using Github.
Version Control System - Git
Version control with Git
Version Control with Git and GitHub
GitHub 101 Using Github and Git for Source Control
Git Introduction.
Git GitHub.
Introduction to The Git Version Control System
Advanced Git for Beginners
Presentation transcript:

KIT – University of the State of Baden-Wuerttemberg and National Research Center of the Helmholtz Association STEINBUCH CENTRE FOR COMPUTING - SCC GIT INRODUCTION Pavel Weber Steinbuch Centre for Computing

2 What’s git Development started in 2005 Distributed Version Control System You don’t need to run server Initially written in C by Linus Torvalds Widely used nowadays Pavel Weber – Git Introduction …. The Linux philosophy is “laugh in the face of danger”. Oops. Wrong one. “Do it yourself”. That’s it.

Steinbuch Centre for Computing 3 What’s git for? Primarily for source code management Track changes Check the project history Compare versions Create branches and workflows Retrieve old versions Local version controlling No central repository needed Don’t need to wait for network presence to do a commit. Each developer has the full repo of the project Pavel Weber – Git Introduction

Steinbuch Centre for Computing 4 Why Git? Pavel Weber – Git Introduction Distributed source control Fast and efficient Scalable and extensible Multi-protocol support ( SSH, HTTP, Git) Different working scenarios: Single developer, central server, master, hierachy Subversion/CVS

Steinbuch Centre for Computing 5 Get started Goto wiki Exercise 1 Examine the config files Apply configuration Implement new aliases Pavel Weber – Git Introduction /etc/gitconfig1 Environments: git config …… /etc/gitconfig ~/.gitconfig ~/repo/.git/config --system --global

Steinbuch Centre for Computing 6 Central vs. Distributed Pavel Weber – Git Introduction

Steinbuch Centre for Computing 7 Git trees in local repository Each commit contains the full working tree Pavel Weber – Git Introduction Staging area/Index Local repo Working directory/tree

Steinbuch Centre for Computing 8 Git Add, Commit, Reset git add – add the file to staging area or index git reset – undo adding a file to index, move the file back to working tree Pavel Weber – Git Introduction Exercise 2 Create local repo Add file and commit Different add options: git add * git add. git add --all git add -u git add git add --all stages All git add. stages new and modified, without deleted git add -u stages modified and deleted, without new g Staging area/Index Local repo Working directory/tree Git local repo git add git commit git reset

Steinbuch Centre for Computing 9 Working Tree, Index, Head Working Tree - the state of files in checkout. BRANCH - line of commits HEAD - current branch or last committed state on current branch INDEX - place, where the files which will be committed are stored Pavel Weber – Git Introduction Commit Commit last HEAD Master git checkout id

Steinbuch Centre for Computing 10Pavel Weber – Git Introduction Staging area/Index Local repo Remote repo Working directory/tree git add git commit git push git reset git checkout HEAD git merge git fetch Pull or rebase Git Dataflows git commit - a

Steinbuch Centre for Computing 11 Remote repo Exercise 3: Add remote repository to your local repo with clone or with remote add Try push, pull Pavel Weber – Git Introduction Local repo 1 Local repo 2 Remote central repo

Steinbuch Centre for Computing 12 Git Fetch, Rebase, Pull git fetch - updates the local copy of remote repository git rebase undo the local changes -> apply the remote -> do the local on top of applied remote git pull - fetch + merge – applies the changes from remote on top of local Pavel Weber – Git Introduction Remote Local GIT REBASE GIT PULL After git rebase: After git pull:

Steinbuch Centre for Computing 13 Branches What is branch Why we need branches? How to make a branch How to switch between branches Pushing to branch Merging back to master Deleting a branch locally Deleting a branch remotely Pavel Weber – Git Introduction

Steinbuch Centre for Computing 14 Using branches: example Pavel Weber – Git Introduction Master Dev feature/issue Tests Merge request

Steinbuch Centre for Computing 15 Branches A branch is simply a pointer to a commit Create a new branch: git branch [ ] Delete a branch: git branch -d | -D (-D also deletes unmerged branches) Rename a branch: git branch -m Delete remote branch: Git push origin : List all branches git branch [-r|-a] Move into (checkout) a branch git checkout Create a branch and check it out git checkout -b Merge branches: git merge Pavel Weber – Git Introduction

Steinbuch Centre for Computing 16Pavel Weber – Git Introduction