summaryrefslogtreecommitdiff
path: root/doc/source/tutorial.rst
diff options
context:
space:
mode:
authorSebastian Thiel <byronimo@gmail.com>2015-01-07 15:35:55 +0100
committerSebastian Thiel <byronimo@gmail.com>2015-01-07 15:35:55 +0100
commitf4a49ff2dddc66bbe25af554caba2351fbf21702 (patch)
tree54ba82b7490038b911fc46bc1407cd7955bd7edf /doc/source/tutorial.rst
parent45eb728554953fafcee2aab0f76ca65e005326b0 (diff)
parentc6ee00d0dadcd7b10d60a2985db4fe137ca7cfed (diff)
downloadgitpython-f4a49ff2dddc66bbe25af554caba2351fbf21702.tar.gz
Merge branch 'firm1-commit_by_actor'
Diffstat (limited to 'doc/source/tutorial.rst')
-rw-r--r--doc/source/tutorial.rst5
1 files changed, 4 insertions, 1 deletions
diff --git a/doc/source/tutorial.rst b/doc/source/tutorial.rst
index d9b35fda..3f45b70d 100644
--- a/doc/source/tutorial.rst
+++ b/doc/source/tutorial.rst
@@ -297,7 +297,10 @@ Access objects and add/remove entries. Commit the changes::
# Access the entries directly
index.add(['my_new_file']) # add a new file to the index
index.remove(['dir/existing_file'])
- new_commit = index.commit("my commit message")
+ new_commit = index.commit("my commit message") # commit by commit message first
+ my_author = Actor("An author", "author@example.com")
+ my_committer = Actor("A committer", "committer@example.com")
+ next_commit = index.commit("my commit message", author=my_author, commiter=my_committer) # commit by commit message and author and committer
Create new indices from other trees or as result of a merge. Write that result to a new index file::