[darcs-users] [issue2011] refuse to pull/apply patches if you have unrecorded changes

Dan Pascu dan at ag-projects.com
Wed Dec 8 10:42:45 UTC 2010

On 7 Dec 2010, at 16:03, Florent Becker wrote:

> You'd still have to unrecord if you want to do that. The other  
> solution
> is to have darcs whatsnew take a --from-{p,m}atch argument, like darcs
> diff, so that you can say darcs whatsnew --from-patch "CONFLICT
> AUTO-BACKUP". Incident question: shouldn't we merge diff and whatsnew,
> with darcs whatsnew being an alias for "darcs diff --darcs-format"?

That can be fine, but IMO whatsnew should stay, even if an alias.  
People are used to it and typing
   darcs wh -sl
is definetly more convenient than
   darcs diff --darcs-format -sl
Plus I'm not sure you can aggregate the command line switches for the  
2 commands.

>> If this proposal goes through, then a --force option would  
>> definitely be
>> very useful, but it will also be a bit confusing from a UI  
>> perspective.
>> We already have --allow-conflicts, --dont-allow-conflicts and
>> --mark-conflicts
> [snip]
>> In other words the existing options that deal with
>> allowing/denying/marking conflicts have lost their original meaning  
>> as
>> they are now dependent on the --force option. Which takes 3 clear
>> options and makes them into a matrix of 6 option combinations that is
>> hard to comprehend.
> This means the force/no-force should be independant of conflicts.
> The way I see it (renaming --force into --allow-unrecorded-changes):
> - -with --allow-unrecorded-changes: current behaviour
> - -without it (ie, --no-allow-unrecorded-changes): if you have  
> unrecorded
> changes, stop before offering patches to pull, then proceed as  
> usual. Or
> offer to auto-record the changes, then proceed as usual, as above.

Indeed, having something like --allow-unrecorded-changes is a lot  
better than --force. Better semantics, better meaning and no conflict  
with the existing conflict handling options.
I would be perfectly happy with such an option.


More information about the darcs-users mailing list