summaryrefslogtreecommitdiffstats
path: root/workshop.tex
blob: f661c35bff12dbc50a3dc526a8495bd001f385d6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
\documentclass[14pt]{beamer}
\usepackage[utf8x]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{hyperref}
\usepackage{algorithmic}
\usepackage{algorithm}
\usepackage{graphicx}

\usepackage{helvet}
%\setbeamercovered{transparent}
\usetheme{Boadilla}
\usecolortheme{beaver}
\setbeamercovered{transparent}
\AtBeginSection[]
{
\begin{frame}<beamer>
\frametitle{Outline}
\tableofcontents[currentsection]
\end{frame}
}

\author[SC \& TH]{Thibaut Horel \and Stéphane Caron}
\institute{Technicolor, Palo Alto}
\date{\today}
\title[Git workshop]{A Git approach to collaborative work in research}

\begin{document}

\begin{frame}
\titlepage
\end{frame}

\begin{frame}{Problem}
\alert{Goal:} 2 or more people want to:
\begin{itemize}
\item easily share files
\item work concurrently on these files
\item keep track of what everybody is doing
\end{itemize}
\pause
\vspace{2em}
Examples:
\begin{itemize}
\item writing a paper
\item writing code
\item \ldots
\end{itemize}
\end{frame}

\begin{frame}{Bad solutions}
\begin{itemize}
\item Email attachments\visible<2->{: nobody in their right mind wants to do that}
\vspace{2em}
\item Dropbox\visible<3->{: Good for file sharing, terrible at handling concurrency}
\end{itemize}
\end{frame}

\begin{frame}{Version Control Systems}
\begin{itemize}
\item designed exactly for this purpose
\vspace{2em}
\item several flavors:
\begin{itemize}
\item centralized (ex: Subversion)
\item decentralized (ex: Git)
\end{itemize}
\end{itemize}
\end{frame}

\begin{frame}{Overview}
\includegraphics[width=\textwidth]{figures/commits.pdf}
\end{frame}

\begin{frame}{Local vs. distant history}
Everything can be done locally:
\begin{center}
\includegraphics[scale=.9]{figures/overview.pdf}
\end{center}
\end{frame}

\begin{frame}{Initialising}
Existing repository:

\begin{block}{}
{\tt \$ git clone <user>@palosgit01:/git/<project>}
\end{block}

\vspace{2em}

Non-existing repository:
\begin{itemize}
\item Ask Umar to create a project for your team
\item Repeat previous step
\end{itemize}
\end{frame}

\begin{frame}{Local editing}
\begin{itemize}
\item Edit a few files
\vspace{2em}
\item When you are happy with the state of the project:
\begin{block}{}
{\tt \$ git commit -a -m "Proof of the uniqueness theorem"}
\end{block}
\end{itemize}
\end{frame}

\begin{frame}{File tracking}

\begin{itemize}
\item By default Git does not track new files
\item Adding a new file:
\begin{block}{}
{\tt \$ git add <filename>}
\end{block}
\end{itemize}
\vspace{2em}
Which file should you add to the project?
\end{frame}

\begin{frame}{Synchronizing with other people}
\includegraphics[width=\textwidth]{figures/git-push.pdf}
\end{frame}

\begin{frame}
\includegraphics[width=\textwidth]{figures/git-pull.pdf}
\end{frame}

\begin{frame}
\includegraphics[width=\textwidth]{figures/git-pull-2.pdf}
\end{frame}

\begin{frame}
\includegraphics[width=\textwidth]{figures/git-merge-ok.pdf}
\end{frame}



\begin{frame}
\begin{center}
\includegraphics[scale=.9]{figures/git-merge-conflict.pdf}
\end{center}
\end{frame}

\end{document}