[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Commit mistake?
From: |
Stephen Berman |
Subject: |
Re: Commit mistake? |
Date: |
Sun, 25 Nov 2018 17:47:46 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) |
On Sun, 25 Nov 2018 18:34:50 +0200 Eli Zaretskii <address@hidden> wrote:
>> From: Stephen Berman <address@hidden>
>> Date: Sun, 25 Nov 2018 14:22:13 +0100
>>
>> I just committed a fix for bug#33423 to master (29ef7d1), and somehow
>> the commit included an entire unrelated file, nt/gnulib.mk. I don't
>> know how this happened, because that is a file I'm not aware of ever
>> having touched, let alone changed (it's a generated file). I don't know
>> if this is a problem but if it is, can someone who knows what to do
>> please take care of it, or tell me how to?
>
> Just delete that file, it should not be in the repository. "git rm"
> etc. (Let me know if you need more detailed instructions.)
Do you mean a new commit using "git rm" on my local branch and then
pushing it to master at Savannah, or will that file there be removed
otherwise?
>> And also tell me how to avoid a possible reoccurrence of in future
>> commits? Thanks and sorry for the nuisance.
>
> The only reliable way I know of is to say "git show" after committing
> and before pushing, and review the diffs carefully making sure the
> commit only includes what I meant it to.
Yes, I must have been careless and overlooked that file (though I don't
know how it got added to my local branch in the first place). Sorry
again, and thanks for the advice.
Steve Berman