:: Re: [DNG] Avoid 'git commit -m ...'…
Top Page
Delete this message
Reply to this message
Author: Adam Borowski
Date:  
To: dng
Subject: Re: [DNG] Avoid 'git commit -m ...' every time code is tested after editing.
On Mon, Feb 15, 2016 at 02:00:46PM +0000, KatolaZ wrote:
> Try to use git for what it was conceived: revision management. And a
> revision is not a release. The strategy suggested by Rainer,
> i.e. maintaining personal branches where every consistent set of
> changes is fixed into a commit, is usually the easiest way out.
>
> Commit often. Branch whenever needed needed. Merge when it
> works. Release when "perfect" (the last one should be really
> considered with a pinch of salt :P).


Commits can be massaged, rewritten, squashed, etc.
A very powerful yet convenient tool can be invoked with:
git rebase -i origin/master
(where "origin" is the remote you push to -- if you never named it yourself,
it's name is just "origin").

You should never edit commits that have been pushed to any public
repository, that's why the above command uses that as the base.

--
A tit a day keeps the vet away.