[Coco] 248 errors in NitrOS-9 repository

Tormod Volden lists.tormod at gmail.com
Tue Jul 23 15:32:40 EDT 2013


On Tue, Jul 23, 2013 at 8:55 PM, Gene Heskett wrote:
> Thanks Tormod.  But I am still green at hg.
>
> I have a commit to push but the error I get isn't making sense.
>
> gene at coyote:/opt/nitros9$ hg log
> changeset:   2862:d9bb08593856
> branch:      lwtools-port
> tag:         tip
> user:        Gene Heskett <gheskett at wdtv.com>
> date:        Tue Jul 23 10:13:36 2013 -0400
> summary:     Updating some defs and makefiles
>
> gene at coyote:/opt/nitros9$ hg push
> pushing to http://hg.code.sf.net/p/nitros9/code
> searching for changes
> abort: push creates new remote heads!
> (did you forget to merge? use push -f to force)
>
>
> I did an "hg merge" because I wanted to be in step before I added 2 or 3 of
> my utilities to the repo and build.
>
> If I do a make hgupdate, will that cancel the changes I've made locally?

I recommend avoiding "make hgupdate" but using the hg commands
normally. These "helpful" scripts or make targets get in the way of
learning mercurial and cause confusion.

I think "hg update" will even refuse to update your tree if you have
local changes. I am not sure what hg merge does in different cases, I
am not so familiar with mercurial and generally use git. I have
learned to use the mercurial mq extension to keep track of
non-committed local changes and that seems to work nicely and if you
have used quilt you'll feel at home.

For simpler storing away of local changes you can do "hg diff >
my-patch" to store your changes in a file, then "hg revert -a" to
revert them from your tree. You can also use "hg diff file1  >
my-patch1" to separate changes from different files into different
patches.

Both in git and mercurial I prefer to avoid merges, and rather do
rebasing of patch series (mq on mercurial, topic branches in git) so
that they can be cleanly applied on top of the latest repo pull.
Merges can sometimes sneak in reverts or unintended changes if you are
not careful and have everything under control.

> I hate losing my work everytime I move these repos aside and re-pull all 3
> of them.
>
> So what do I do next?

If you already committed changes locally, they won't show up in "hg
diff". You may use "hg log -r my-revision-x -p >
my-commit-revision-x.patch" to save them in files. There is a "hg
export" command for doing this also.

Or you learn the proper hg merge procedures :)


On Tue, Jul 23, 2013 at 8:56 PM, Gene Heskett wrote:
>> I have added a check for power of two to the toolshed os9format.
>>
>> Tormod
>>
> Thanks.  Pushed?

Note that this was in toolshed, not nitros9. hg pull && hg log|less
will tell. Or click the History button in the web interface at
https://sourceforge.net/p/toolshed/code/ci/default/tree/

Tormod



More information about the Coco mailing list