The command "git commit -a" do two thinks:
git add and git commit
And it will add all file that changed to stage then commit all of them. 

Vào 04:49:00 UTC+7 Thứ hai, ngày 14 tháng một năm 2013, python...@gmail.com 
đã viết:
> Thanks Thomas - whats the difference between git commit -a and git add?
> On Sunday, January 13, 2013 12:12:22 PM UTC-8, Thomas Ferris Nicolaisen 
> wrote:
>> On Sunday, January 13, 2013 8:54:38 PM UTC+1, python...@gmail.com wrote:
>>> Hi all-
>>> I am trying to revert one of the commits i made using the following 
>>> command and running into following error,are there ways to revert commits 
>>> that are already done?
>>> <cmd>git revert 565c775b3fe2b66c7ad4431ffde65fe73f0dbc5e
>>> error: could not revert 565c775... code: Fix the Max Tx power value in 
>>> 5G band and .ini support for 11h
>>> hint: after resolving the conflicts, mark the corrected paths
>>> hint: with 'git add <paths>' or 'git rm <paths>'
>>> hint: and commit the result with 'git commit'
>>> Recorded preimage for 'radio/CORE/MAC/inc/qcode_version.h'
>> Seems like a later commit changed some of the changes that you want to 
>> revert.
>> Say, if you create a file foo.txt in commit A, then someone modifies 
>> foo.txt in commit B, and then you want to revert commit A again to get rid 
>> of foo.txt, then you will get presented with a conflict, and you have to 
>> decide what to do with the changes that were made in commit B.
>> So, you have to edit the files till they are in a state you are happy 
>> with, and then follow the hints you got from Git there (git add filename, 
>> git commit).


Reply via email to