Skip to content

Commit 7dcf10e

Browse files
committed
Update Vietnamese
1 parent bf04058 commit 7dcf10e

File tree

1 file changed

+248
-0
lines changed

1 file changed

+248
-0
lines changed

index_vi.html

Lines changed: 248 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,248 @@
1+
<!DOCTYPE html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="utf-8">
5+
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
6+
<title>git - the simple guide - no deep shit!</title>
7+
<link href='http://fonts.googleapis.com/css?family=Chelsea+Market' rel='stylesheet' type='text/css'>
8+
<link rel="stylesheet" href="css/normalize.css" type="text/css">
9+
<link rel="stylesheet" href="css/style.css" type="text/css">
10+
<script type="text/javascript">
11+
var _gaq = _gaq || [];
12+
_gaq.push(['_setAccount', 'UA-652147-13']);
13+
_gaq.push(['_trackPageview']);
14+
15+
(function() {
16+
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
17+
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
18+
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
19+
})();
20+
21+
function recordOutboundLink(link, category, action) {
22+
_gat._getTrackerByName()._trackEvent(category, action);
23+
setTimeout('document.location = "' + link.href + '"', 100);
24+
}
25+
</script>
26+
</head>
27+
<body>
28+
<div class="scrollblock block-title">
29+
<h1>git - the simple guide</h1>
30+
<p>just a simple guide for getting started with git. no deep shit ;)</p>
31+
<a href="https://twitter.com/share" class="twitter-share-button" data-via="rogerdudler" data-size="large" data-url="http://rogerdudler.github.com/git-guide" data-related="rogerdudler" data-hashtags="git">Tweet</a>
32+
<script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0];if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src="//platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");</script>
33+
<p class="meta">
34+
by <a href="http://www.twitter.com/rogerdudler">Roger Dudler</a>
35+
<br />credits to <a href="http://www.twitter.com/tfnico">@tfnico</a>, <a href="http://www.twitter.com/fhd">@fhd</a> and <a href="http://www.namics.com">Namics</a><br />
36+
this guide in
37+
<a href="index.de.html">deutsch</a>,
38+
<a href="index.es.html">español</a>,
39+
<a href="index.fr.html">français</a>,
40+
<a href="index.it.html">italiano</a>,
41+
<a href="index.nl.html">nederlands</a>,
42+
<a href="index.pt_BR.html">português</a>,
43+
<a href="index.ru.html">русский</a>,
44+
<a href="index.tr.html">türkçe</a>,
45+
<br/>
46+
<a href="index.my.html">မြန်မာ</a>,
47+
<a href="index.ja.html">日本語</a>,
48+
<a href="index.zh.html">中文</a>,
49+
<a href="index.ko.html">한국어</a>
50+
<br />
51+
please report issues on <a href="https://github.com/rogerdudler/git-guide/issues">github</a>
52+
</p>
53+
<div class="announcement">
54+
<a href="http://frontify.com/?utm_source=gitguide&amp;utm_campaign=founder_frontify">
55+
<img src="http://frontify.com/assets/img/frontify-announcement-git.png" width="960" height="100" alt="Frontify - Collaboration for Web Designers &amp; Front-End Developers" />
56+
</a>
57+
</div>
58+
<img src="img/arrow.png" alt="" />
59+
</div>
60+
<!-- setup -->
61+
<a name="setup"></a>
62+
<div class="scrollblock block-setup">
63+
<h2>setup</h2>
64+
<p>
65+
<a href="http://code.google.com/p/git-osx-installer/downloads/list?can=3">Download git for OSX</a>
66+
</p>
67+
<p>
68+
<a href="http://code.google.com/p/msysgit/downloads/list?can=3">Download git for Windows</a>
69+
</p>
70+
<p>
71+
<a href="http://book.git-scm.com/2_installing_git.html">Download git for Linux</a>
72+
</p>
73+
</div>
74+
<a name="create"></a>
75+
<div class="scrollblock block-create">
76+
<h2>create a new repository</h2>
77+
<p>
78+
create a new directory, open it and perform a <br />
79+
<code>git init</code><br />
80+
to create a new git repository.
81+
</p>
82+
</div>
83+
<a name="checkout"></a>
84+
<div class="scrollblock block-checkout">
85+
<h2>checkout a repository</h2>
86+
<p>
87+
create a working copy of a local repository by running the command<br />
88+
<code>git clone /path/to/repository</code><br />
89+
when using a remote server, your command will be<br />
90+
<code>git clone username@host:/path/to/repository</code>
91+
</p>
92+
</div>
93+
<a name="trees"></a>
94+
<div class="scrollblock block-trees">
95+
<h2>workflow</h2>
96+
<p>
97+
your local repository consists of three "trees" maintained by git.
98+
the first one is your <code>Working Directory</code> which holds the actual files.
99+
the second one is the <code>Index</code> which acts as a staging area and
100+
finally the <code>HEAD</code> which points to the last commit you've made.
101+
</p>
102+
<img src="img/trees.png" alt="" />
103+
</div>
104+
<a name="add"></a>
105+
<div class="scrollblock block-add">
106+
<h2>add &amp; commit</h2>
107+
<p>
108+
You can propose changes (add it to the <b>Index</b>) using<br />
109+
<code>git add &lt;filename&gt;</code><br />
110+
<code>git add *</code><br />
111+
This is the first step in the basic git workflow. To actually commit these changes use<br />
112+
<code>git commit -m "Commit message"</code><br />
113+
Now the file is committed to the <b>HEAD</b>, but not in your remote repository yet.
114+
</p>
115+
</div>
116+
<a name="push"></a>
117+
<div class="scrollblock block-remote">
118+
<h2>pushing changes</h2>
119+
<p>
120+
Your changes are now in the <b>HEAD</b> of your local working copy. To send those changes to your remote repository, execute <br />
121+
<code>git push origin master</code><br />
122+
Change <i>master</i> to whatever branch you want to push your changes to.
123+
<br /><br />
124+
If you have not cloned an existing repository and want to connect your repository to a remote server, you need to add it with<br />
125+
<code>git remote add origin &lt;server&gt;</code><br />
126+
Now you are able to push your changes to the selected remote server<br />
127+
128+
</p>
129+
</div>
130+
<a name="branching"></a>
131+
<div class="scrollblock block-branching">
132+
<h2>branching</h2>
133+
<p>
134+
Branches are used to develop features isolated from each other. The <i>master</i> branch is the "default" branch when you create a repository. Use other branches for development and merge them back to the master branch upon completion.
135+
</p>
136+
<img src="img/branches.png" alt="" />
137+
<p>
138+
create a new branch named "feature_x" and switch to it using<br />
139+
<code>git checkout -b feature_x</code><br />
140+
switch back to master<br />
141+
<code>git checkout master</code><br />
142+
and delete the branch again<br />
143+
<code>git branch -d feature_x</code><br />
144+
a branch is <i>not available to others</i> unless you push the branch to your remote repository<br />
145+
<code>git push origin &lt;branch&gt;</code>
146+
</p>
147+
</div>
148+
<a name="update"></a>
149+
<div class="scrollblock block-merging">
150+
<h2>update &amp; merge</h2>
151+
<p>
152+
to update your local repository to the newest commit, execute <br />
153+
<code>git pull</code><br />
154+
in your working directory to <i>fetch</i> and <i>merge</i> remote changes.<br />
155+
to merge another branch into your active branch (e.g. master), use<br />
156+
<code>git merge &lt;branch&gt;</code><br />
157+
in both cases git tries to auto-merge changes. Unfortunately, this is not always possible and results in <i>conflicts</i>.
158+
You are responsible to merge those <i>conflicts</i>
159+
manually by editing the files shown by git. After changing, you need to mark them as merged with<br />
160+
<code>git add &lt;filename&gt;</code><br />
161+
before merging changes, you can also preview them by using<br />
162+
<code>git diff &lt;source_branch&gt; &lt;target_branch&gt;</code>
163+
</p>
164+
</div>
165+
<a name="tagging"></a>
166+
<div class="scrollblock block-tagging">
167+
<h2>tagging</h2>
168+
<p>
169+
it's recommended to create tags for software releases. this is a known concept, which also exists in SVN. You can create a new tag named <i>1.0.0</i> by executing<br />
170+
<code>git tag 1.0.0 1b2e1d63ff</code><br />
171+
the <i>1b2e1d63ff</i> stands for the first 10 characters of the commit id you want to reference with your tag. You can get the commit id with <br />
172+
<code>git log</code><br />
173+
you can also use fewer characters of the commit id, it just has to be unique.
174+
</p>
175+
</div>
176+
<a name="checkout-replace"></a>
177+
<div class="scrollblock block-checkout-replace">
178+
<h2>replace local changes</h2>
179+
<p>
180+
In case you did something wrong (which for sure never happens ;) you can replace local changes using the command<br />
181+
<code>git checkout -- &lt;filename&gt;</code><br />
182+
this replaces the changes in your working tree with the last content in HEAD. Changes already added to the index, as well as new files, will be kept.
183+
</p>
184+
<p>
185+
If you instead want to drop all your local changes and commits, fetch the latest history from the server and point your local master branch at it like this<br />
186+
<code>git fetch origin</code><br />
187+
<code>git reset --hard origin/master</code>
188+
</p>
189+
</div>
190+
<a name="hints"></a>
191+
<div class="scrollblock block-hints">
192+
<h2>useful hints</h2>
193+
<p>
194+
built-in git GUI<br />
195+
<code>gitk</code><br />
196+
use colorful git output<br />
197+
<code>git config color.ui true</code><br />
198+
show log on just one line per commit<br />
199+
<code>git config format.pretty oneline</code><br />
200+
use interactive adding<br />
201+
<code>git add -i</code>
202+
</p>
203+
</div>
204+
<a name="resources"></a>
205+
<div class="scrollblock block-resources">
206+
<h2>links & resources</h2>
207+
<h3>graphical clients</h3>
208+
<p>
209+
<ul>
210+
<li><a href="http://gitx.laullon.com/">GitX (L) (OSX, open source)</a></li>
211+
<li><a href="http://www.git-tower.com/">Tower (OSX)</a></li>
212+
<li><a href="http://www.sourcetreeapp.com/">Source Tree (OSX, free)</a></li>
213+
<li><a href="http://mac.github.com/">GitHub for Mac (OSX, free)</a></li>
214+
<li><a href="https://itunes.apple.com/gb/app/gitbox/id403388357?mt=12">GitBox (OSX, App Store)</a></li>
215+
</ul>
216+
</p>
217+
<h3>guides</h3>
218+
<p>
219+
<ul>
220+
<li><a href="http://book.git-scm.com/">Git Community Book</a></li>
221+
<li><a href="http://progit.org/book/">Pro Git</a></li>
222+
<li><a href="http://think-like-a-git.net/">Think like a git</a></li>
223+
<li><a href="http://help.github.com/">GitHub Help</a></li>
224+
<li><a href="http://marklodato.github.com/visual-git-guide/index-en.html">A Visual Git Guide</a></li>
225+
</ul>
226+
</p>
227+
</div>
228+
<a name="comments"></a>
229+
<div class="scrollblock block-comments">
230+
<h2>comments</h2>
231+
<div id="disqus_thread"></div>
232+
<script type="text/javascript">
233+
/* * * CONFIGURATION VARIABLES: EDIT BEFORE PASTING INTO YOUR WEBPAGE * * */
234+
var disqus_shortname = 'git-the-simple-guide'; // required: replace example with your forum shortname
235+
236+
/* * * DON'T EDIT BELOW THIS LINE * * */
237+
(function() {
238+
var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
239+
dsq.src = 'http://' + disqus_shortname + '.disqus.com/embed.js';
240+
(document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
241+
})();
242+
</script>
243+
<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
244+
</div>
245+
<a href="http://www.git-tower.com/?source=rd" onClick="recordOutboundLink(this, 'Outbound Links', 'git-tower.com');return false;" class="tower"></a>
246+
<a href="files/git_cheat_sheet.pdf" onClick="recordOutboundLink(this, 'Cheat Sheet', 'git-guide');return false;" class="cheatsheet"></a>
247+
</body>
248+
</html>

0 commit comments

Comments
 (0)