summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 2eff142)
raw | patch | inline | side by side (parent: 2eff142)
author | J. Bruce Fields <bfields@fieldses.org> | |
Sun, 7 Jan 2007 03:38:38 +0000 (22:38 -0500) | ||
committer | Junio C Hamano <junkio@cox.net> | |
Sun, 7 Jan 2007 06:48:41 +0000 (22:48 -0800) |
Edit for conciseness.
Add a "Making changes" section header.
When possible, make sure that stuff in text boxes could be entered literally.
(Don't use "..." unless we want a user to type that.)
Move 'commit -a' example into a literal code section, clarify that it finds
modified files automatically.
Signed-off-by: "J. Bruce Fields" <bfields@citi.umich.edu>
Signed-off-by: Junio C Hamano <junkio@cox.net>
Add a "Making changes" section header.
When possible, make sure that stuff in text boxes could be entered literally.
(Don't use "..." unless we want a user to type that.)
Move 'commit -a' example into a literal code section, clarify that it finds
modified files automatically.
Signed-off-by: "J. Bruce Fields" <bfields@citi.umich.edu>
Signed-off-by: Junio C Hamano <junkio@cox.net>
Documentation/tutorial.txt | patch | blob | history |
index 79884d9c74d3175e179dc5a83e9163908242d6ca..01d4a47a97fa864c6948b8ae98ece1f00b1003da 100644 (file)
You've now initialized the working directory--you may notice a new
directory created, named ".git". Tell git that you want it to track
-every file under the current directory with (notice the dot '.'
-that means the current directory):
+every file under the current directory (note the '.') with:
------------------------------------------------
$ git add .
will prompt you for a commit message, then record the current state
of all the files to the repository.
+Making changes
+--------------
+
Try modifying some files, then run
------------------------------------------------
make a commit, like this:
------------------------------------------------
-$ git add file1 file...
+$ git add file1 file2 file3
$ git commit
------------------------------------------------
This will again prompt your for a message describing the change, and then
-record the new versions of the files you listed. It is cumbersome
-to list all files and you can say `git commit -a` (which stands for 'all')
-instead of running `git add` beforehand.
+record the new versions of the files you listed.
+
+Alternatively, instead of running `git add` beforehand, you can use
------------------------------------------------
$ git commit -a
------------------------------------------------
+which will automatically notice modified (but not new) files.
+
A note on commit messages: Though not required, it's a good idea to
begin the commit message with a single short (less than 50 character)
line summarizing the change, followed by a blank line and then a more