2013-11-26 27 views
0

我想和git倉庫增量更新 服務器中保存的文件(回購提交 - version.txt)如何獲取提交更改文件列表之間的git repo?

!例如:(7ed656f60ae0bb2a55ed632d29999a3a45313deb)

現在要自動部署的最後回購版本服務器

如何獲取(在服務器repo-commit-version.txt中的最後一個回購版本)更改文件[modified/create/delete]列表?

git的日誌git的差異~~~

+0

你的解釋並不清楚。當你說「最後的回購」時,你的意思是「最後的承諾」嗎?你能否澄清這個問題? – lemiorhan

回答

0

目前還不清楚你問什麼,但它聽起來像你要麼想知道有哪些文件,提交更改:??

git diff --stat COMMIT_ID -- 

或者,什麼之間改變承諾:

git diff --stat SRC_COMMIT_ID DST_COMMIT_ID -- 

例如,Python的鼻子庫,我得到這個:

$ git diff --stat release_1.3.0 HEAD -- 

AUTHORS           | 1 + 
CHANGELOG          | 7 ++ 
doc/.templates/indexsidebar.html    | 18 +---- 
doc/usage.rst         | 5 ++ 
.../test_multiprocess/multiprocess.rst   | 2 +- 
functional_tests/support/issue649/test.py  | 9 +++ 
functional_tests/support/issue680/test.py  | 3 + 
functional_tests/support/issue700/test.py  | 4 + 
functional_tests/support/issue720/test.py  | 6 ++ 
functional_tests/test_failuredetail_plugin.py | 14 ++++ 
functional_tests/test_issue_649.py    | 18 +++++ 
functional_tests/test_xunit.py     | 32 ++++++++ 
nose/commands.py        | 11 ++- 
nose/config.py         | 5 +- 
nose/core.py         | 9 ++- 
nose/failure.py         | 3 +- 
nose/importer.py        | 2 +- 
nose/plugins/capture.py       | 22 +----- 
nose/plugins/debug.py       | 15 ++-- 
nose/plugins/doctests.py      | 2 + 
nose/plugins/failuredetail.py     | 8 +- 
nose/plugins/xunit.py       | 75 +++++++++---------- 
nose/pyversion.py        | 65 +++++++++++++++- 
nose/util.py         | 2 +- 
unit_tests/support/doctest/.gitignore   | 1 + 
.../support/doctest/noname_wrapped.not_py  | 6 ++ 
unit_tests/support/doctest/noname_wrapper.py | 12 +++ 
unit_tests/support/init_prefix_bug/__init__.py | 1 + 
.../support/init_prefix_bug/__init__not.py  | 1 + 
unit_tests/test_core.py       | 33 +++++++- 
unit_tests/test_doctest_no_name.py    | 34 +++++++++ 
unit_tests/test_importer.py      | 10 +++ 
unit_tests/test_xunit.py      | 34 --------- 
33 files changed, 344 insertions(+), 126 deletions(-) 

請注意,由於我的屏幕寬度,某些路徑已被截斷。您可以使用參數--stat選項來控制寬度。您可以運行git help diff或查看diff man page以獲取更多信息。

相關問題