Wiki source code of Git

Version 23.1 by msp on 2012/10/15 12:14

Show last authors
1 This tutorial will address the source code management (SCM) tool named [[Git>>url:http://git-scm.com/||shape="rect"]]. By following these steps you should learn about the basic usage of Git, which is required for the whole practical course. Furthermore, Git is a great SCM tool, and it's good to know how to use it. During this tutorial, we will follow Alan Turing's thoughts towards developing the [[Turing Machine>>url:http://en.wikipedia.org/wiki/Turing_machine||shape="rect"]].
2
3 More in-depth documentation can be found on the [[official home page>>url:http://git-scm.com/documentation||shape="rect"]], which mentions books, videos, and links to other tutorials and references.
4
5 = Repositories and Commits =
6
7 1. Read the [[Git for Computer Scientists>>url:http://eagain.net/articles/git-for-computer-scientists/||shape="rect"]] introduction (skip this if you are already familiar with Git).
8 1. For Linux, Git is available in its own package. Windows users can install [[msysGit>>url:http://msysgit.github.com/||shape="rect"]]. For MacOS, Git is available as part of [[Xcode>>url:https://developer.apple.com/xcode/||shape="rect"]]; if you cannot install that, use [[Git for OSX>>url:http://code.google.com/p/git-osx-installer/||shape="rect"]].
9 1. (((
10 Create a local repository for the "//Turing Project//":
11
12 {{noformat nopanel="true"}}
13 $ mkdir turing
14 $ cd turing
15 $ git init
16 Initialized empty Git repository in ~/turing/.git/
17 {{/noformat}}
18 )))
19 1. (((
20 Add some content: copy [[attach:notes.txt]] to your {{code language="none"}}turing{{/code}} directory.
21
22 {{noformat nopanel="true"}}
23 $ git add notes.txt
24 $ git commit -m "wrote some first notes"
25 [master (root-commit) 2e73b34] wrote some first notes
26 1 files changed, 5 insertions(+), 0 deletions(-)
27 create mode 100644 notes.txt
28 {{/noformat}}
29 )))