Re: [fossil-users] diff after update

2015-09-13 Thread Kees Nuyt
[Default] On Sun, 13 Sep 2015 07:01:23 +0800, Barry Arthur
 wrote:

> The undo command has a   -n | --dry-run   option. We could add a sub-option
> of 'diff' :
>
>  fossil undo -n diff

+1

> I like that it's related to the --dry-run notion, but it breaks with every
> other implementation of --dry-run within fossil. So, we would need it
> nowhere or everywhere.

-- 
Regards,

Kees Nuyt
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-13 Thread Steve Stefanovich
‎This indeed looks the best way to go about it, on second thought.

From: Scott Robison


Here is the stash version of diff:

 fossil stash diff ?STASHID?
 fossil stash gdiff ?STASHID?

Why not do it the same way for undo?
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-12 Thread Barry Arthur
On 13 September 2015 at 02:21, Andy Bradford 
wrote:

> Thus said Warren Young on Fri, 11 Sep 2015 18:27:36 -0600:
>
> > Also, it implies  that you're asking Fossil to  undo changes, modified
> > in some way using diffs.
>
> Fair enough. I  only expressed my opinion about where  I thought it fit,
> with the  intention of  avoiding having  yet another  word or  name that
> people have to avoid in their repositories.
>
> I  can certainly  see how  it would  be confusing  as part  of the  undo
> command.
>
>
The undo command has a   -n | --dry-run   option. We could add a sub-option
of 'diff' :

  fossil undo -n diff

I like that it's related to the --dry-run notion, but it breaks with every
other implementation of --dry-run within fossil. So, we would need it
nowhere or everywhere.
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-12 Thread Andy Bradford
Thus said Warren Young on Fri, 11 Sep 2015 18:27:36 -0600:

> Also, it implies  that you're asking Fossil to  undo changes, modified
> in some way using diffs.

Fair enough. I  only expressed my opinion about where  I thought it fit,
with the  intention of  avoiding having  yet another  word or  name that
people have to avoid in their repositories.

I  can certainly  see how  it would  be confusing  as part  of the  undo
command.

Thanks,

Andy
-- 
TAI64 timestamp: 400055f46d34


___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-12 Thread Lonnie Abelbeck

On Sep 11, 2015, at 7:19 PM, Scott Robison  wrote:

> On Fri, Sep 11, 2015 at 6:07 PM, Steve Stefanovich  wrote:
> Clever, but awkward in my opinion; the first place to look for such a feature 
> would be under diff command. At least for me, that is.
> 
> My vote is for diff --from|--to undo, where 'undo' is a special tag, same as 
> 'ckout' in different context. I think it fits in such paradigm nicely.
> 
> The person who names branches 'undo' can be perhaps warned in the command 
> help to use the hash instead.
> 
> S.
> 
> Here is the stash version of diff:
>  fossil stash diff ?STASHID?
>  fossil stash gdiff ?STASHID?
> 
> Why not do it the same way for undo? It seems to be most in line with 
> precedent. Perhaps because undo doesn't currently have subcommands, just 
> options. Still, it would be the most intuitive thing based on existing 
> practice.
> 
> -- 
> Scott Robison

+1

Editing the "stash" help added to "undo" would look something like...

-- snippet --

 fossil undo diff ?DIFF-OPTIONS?
 fossil undo gdiff ?DIFF-OPTIONS?

Show diffs of the current working checkout and what that
checkout would be if "undo" were applied.

SUMMARY:
 fossil undo
 fossil undo [g]diff ?DIFF-OPTIONS?

--
Lonnie

___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-12 Thread Johan Kuuse
If I understand things right, this is a diff against the undo buffer, so I
suggest this alternative:

fossil diff --undo-buffer

BR,
Johan
El 13/9/2015 5:39, "Lonnie Abelbeck"  escribió:

>
> On Sep 11, 2015, at 7:19 PM, Scott Robison 
> wrote:
>
> > On Fri, Sep 11, 2015 at 6:07 PM, Steve Stefanovich  wrote:
> > Clever, but awkward in my opinion; the first place to look for such a
> feature would be under diff command. At least for me, that is.
> >
> > My vote is for diff --from|--to undo, where 'undo' is a special tag,
> same as 'ckout' in different context. I think it fits in such paradigm
> nicely.
> >
> > The person who names branches 'undo' can be perhaps warned in the
> command help to use the hash instead.
> >
> > S.
> >
> > Here is the stash version of diff:
> >  fossil stash diff ?STASHID?
> >  fossil stash gdiff ?STASHID?
> >
> > Why not do it the same way for undo? It seems to be most in line with
> precedent. Perhaps because undo doesn't currently have subcommands, just
> options. Still, it would be the most intuitive thing based on existing
> practice.
> >
> > --
> > Scott Robison
>
> +1
>
> Editing the "stash" help added to "undo" would look something like...
>
> -- snippet --
>
>  fossil undo diff ?DIFF-OPTIONS?
>  fossil undo gdiff ?DIFF-OPTIONS?
>
> Show diffs of the current working checkout and what that
> checkout would be if "undo" were applied.
>
> SUMMARY:
>  fossil undo
>  fossil undo [g]diff ?DIFF-OPTIONS?
>
> --
> Lonnie
>
> ___
> fossil-users mailing list
> fossil-users@lists.fossil-scm.org
> http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
>
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-12 Thread Stephan Beal
On Sat, Sep 12, 2015 at 2:04 AM, Scott Robison 
wrote:

> On Fri, Sep 11, 2015 at 5:14 PM, Andy Bradford 
> wrote:
>
>> Thus said Richard Hipp on Fri, 11 Sep 2015 10:11:30 -0400:
>>
>> > "fossil diff --versus-undo" maybe???
>>
>
i don't like 'versus' because diff already has 'from', and it seems strange
to split out a special case of it, but...


>
>> What if instead of making this a  feature of ``fossil diff'' it became a
>> feature of ``fossil undo?''
>>
>> fossil undo --diff
>>
>
> Ooh, I like this... +1
>

me, too.


-- 
- stephan beal
http://wanderinghorse.net/home/stephan/
http://gplus.to/sgbeal
"Freedom is sloppy. But since tyranny's the only guaranteed byproduct of
those who insist on a perfect world, freedom will have to do." -- Bigby Wolf
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-12 Thread j. van den hoff

On Sat, 12 Sep 2015 01:45:28 +0200, Johan Kuuse  wrote:


fossil diff -before

or

fossil diff -before-commit


typo... I just wanted to propose another name for the requested option,  
and actually I meant "call it `diff --before' or `diff --before-update'  
which I for one would be able to memorize as "compute diff of current  
state vs. state before the preceding update". actually, considering the  
original posters `subject' line, one might also look at it the other way  
round and call it `diff --after-update' ;-)


personally, I find reference to the undo buffer a long way from being  
obvious to someone just using fossil as DVCS (rather than someone  
interested in in the details/internals of `fossil').




?
El 12/9/2015 1:14, "Andy Bradford"  escribió:


Thus said Richard Hipp on Fri, 11 Sep 2015 10:11:30 -0400:

> "fossil diff --versus-undo" maybe???

What if instead of making this a  feature of ``fossil diff'' it became a
feature of ``fossil undo?''

fossil undo --diff

Andy
--
TAI64 timestamp: 400055f36093
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users




--
Using Opera's revolutionary email client: http://www.opera.com/mail/
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-12 Thread Stephan Beal
On Sat, Sep 12, 2015 at 1:10 PM, j. van den hoff 
wrote:

> personally, I find reference to the undo buffer a long way from being
> obvious to someone just using fossil as DVCS (rather than someone
> interested in in the details/internals of `fossil').


while i can agree with that, the whole feature is apparently non-obvious
(has never been suggested before).

-- 
- stephan beal
http://wanderinghorse.net/home/stephan/
http://gplus.to/sgbeal
"Freedom is sloppy. But since tyranny's the only guaranteed byproduct of
those who insist on a perfect world, freedom will have to do." -- Bigby Wolf
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-12 Thread Martin Gagnon
On Sat, Sep 12, 2015 at 01:10:28PM +0200, j. van den hoff wrote:
> On Sat, 12 Sep 2015 01:45:28 +0200, Johan Kuuse  wrote:
> 
> >fossil diff -before
> >
> >or
> >
> >fossil diff -before-commit
> 
> typo... I just wanted to propose another name for the requested
> option, and actually I meant "call it `diff --before' or `diff
> --before-update' which I for one would be able to memorize as
> "compute diff of current state vs. state before the preceding
> update". actually, considering the original posters `subject' line,
> one might also look at it the other way round and call it `diff
> --after-update' ;-)
> 
> personally, I find reference to the undo buffer a long way from
> being obvious to someone just using fossil as DVCS (rather than
> someone interested in in the details/internals of `fossil').

It depend what the feature really do. As it is implemented now (if I
understand it well) it make a diff against the undo buffer, doesn't
matter what was the previous command. 

So in that case, I think it should refer to the undo buffer somehow.

What if someone does :
--

  $ fossil update
 ...
  $ fossil stash 

# some hacking...
 
  $ fossil shash pop

  $ fossil diff --before-update(or fossil diff --undo)
--

In this case, it would be confusing if it doesn't really do the
diff with what was on disk before the update. Right now with the 
" fossil diff --undo" , it would make the diff from current file on disk with 
what it
was before the "fossil stash pop" command. 

> 
> >
> >?
> >El 12/9/2015 1:14, "Andy Bradford"  escribió:
> >
> >>Thus said Richard Hipp on Fri, 11 Sep 2015 10:11:30 -0400:
> >>
> >>> "fossil diff --versus-undo" maybe???
> >>
> >>What if instead of making this a  feature of ``fossil diff'' it became a
> >>feature of ``fossil undo?''
> >>
> >>fossil undo --diff


I think that "fossil diff --from undo" have the advantage to be clear
and represent what the command really does compare to let say:

  fossil undo --diff : might be interpret as it undo something

  fossil diff --undo : is less explicit than --from undo


-- 
Martin G.
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Scott Doctor

diff --erent

or

diff --erance


Scott Doctor
sc...@scottdoctor.com

On 9/11/2015 10:27 AM, Richard Hipp wrote:

On 9/11/15, Warren Young  wrote:

diff --undo sounds like you’re asking it to undo the diff, which makes no
sense.

I agree.  I'm just having trouble coming up with an alternative.


How does “fossil diff --last” strike you?

Still a little generic, I think, but moving in the right direction.


___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Richard Hipp
On 9/11/15, Warren Young  wrote:
>
> diff --undo sounds like you’re asking it to undo the diff, which makes no
> sense.

I agree.  I'm just having trouble coming up with an alternative.

>
> How does “fossil diff --last” strike you?

Still a little generic, I think, but moving in the right direction.
-- 
D. Richard Hipp
d...@sqlite.org
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Warren Young
On Sep 11, 2015, at 11:41 AM, Ron W  wrote:
> 
> On Fri, Sep 11, 2015 at 1:12 PM, Warren Young  wrote:
> 
> Though --from-undo is better in that it tells you what the option does, you 
> have to know that Fossil has an undo buffer to make sense of it.  That’s 
> exposing internal implementation details in the UI.
> 
> I disagree. The "fossil undo" command already tells you Fossil has an undo 
> buffer,

No, the undo command just tells you that Fossil has some unspecified way to 
achieve an undo.  It doesn’t tell you how it accomplishes that.

I don’t want Fossil users to be required to think about how undo is implemented 
when they ask Fossil, “What just happened?”

> How does “fossil diff --last” strike you?
> 
> I think "--last" would be interpreted as a short cut for "--to latest”

No, latest is “now.”  “Last” is “then”.  (“When will now, be then?”  “Soon.”)

If it’s the “L” that’s hanging you up, there are synonyms.  --prior and --prev 
come to mind.
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


[fossil-users] diff after update

2015-09-11 Thread Paolo Bolzoni
Dear list,

Is there a way to get a diff between what I had in the disk before
executing "fossil update" and after?
I'd be happy to read the (fine) manual, but I cannot find the place. Thanks!

Yours faithfully,
Paolo
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread tonyp
Although I think --undo is not too bad as it clearly does not make sense to 
'undo' a diff, another alternative that is less 'verbal' that might work is


diff --back  (as in "diff with what would be there if I were to go back, or 
back out the recent changes...")


-Original Message- 
From: Richard Hipp

Sent: Friday, September 11, 2015 8:27 PM
To: Fossil SCM user's discussion
Subject: Re: [fossil-users] diff after update

On 9/11/15, Warren Young <w...@etr-usa.com> wrote:


diff --undo sounds like you’re asking it to undo the diff, which makes no
sense.


I agree.  I'm just having trouble coming up with an alternative.



How does “fossil diff --last” strike you?


Still a little generic, I think, but moving in the right direction.
--
D. Richard Hipp
d...@sqlite.org
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users 


___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Ross Berteig


On 9/11/2015 7:11 AM, Richard Hipp wrote:

On 9/11/15, Stephan Beal  wrote:

On Fri, Sep 11, 2015 at 1:22 PM, Richard Hipp  wrote:

I'm not sure "--undo" is the right name for this option.  Other
suggestions?


--from-undo
or:
--from undo (special-case name)


Adding support for "undo" as a special-case name of "--from" seems
problematic since that would make it harder to do a diff against a
branch named "undo".


I like the special case named "undo". It fits neatly alongside "tip", 
"current", "next", "previous", "prev", and "ckout". Like all the other 
specials except "tip", it probably only has meaning if fossil is running 
in an open checkout.


There is already a mechanism to distinguish a branch (or tag) that 
matches a special name or hash. You would say "tag:current" to talk 
about the branch named "current", or "root:current" to name the checkin 
the branch is rooted on. So "tag:undo" would name the branch, as would 
plain "undo" if there is no current checkout.


This is documented here:
   http://fossil-scm.org/xfer/doc/trunk/www/checkin_names.wiki
but perhaps deserves some additional visibility somehow.

I guess the other question to ask is how many of us have a project with 
a branch named "undo"?


It appears that as of just now, there is no branch named undo in fossil 
itself. For the record, I don't recall ever using undo as a branch name 
in any of my personal repositories.


--
Ross Berteig   r...@cheshireeng.com
Cheshire Engineering Corp.   http://www.CheshireEng.com/

___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Richard Hipp
On 9/11/15, to...@acm.org <to...@acm.org> wrote:
> Although I think --undo is not too bad as it clearly does not make sense to
> 'undo' a diff, another alternative that is less 'verbal' that might work is
>
> diff --back  (as in "diff with what would be there if I were to go back, or
> back out the recent changes...")

+1


>
> -Original Message-
> From: Richard Hipp
> Sent: Friday, September 11, 2015 8:27 PM
> To: Fossil SCM user's discussion
> Subject: Re: [fossil-users] diff after update
>
> On 9/11/15, Warren Young <w...@etr-usa.com> wrote:
>>
>> diff --undo sounds like you’re asking it to undo the diff, which makes no
>> sense.
>
> I agree.  I'm just having trouble coming up with an alternative.
>
>>
>> How does “fossil diff --last” strike you?
>
> Still a little generic, I think, but moving in the right direction.
> --
> D. Richard Hipp
> d...@sqlite.org
> ___
> fossil-users mailing list
> fossil-users@lists.fossil-scm.org
> http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
>
> ___
> fossil-users mailing list
> fossil-users@lists.fossil-scm.org
> http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
>


-- 
D. Richard Hipp
d...@sqlite.org
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Warren Young
On Sep 11, 2015, at 2:33 PM, Ross Berteig  wrote:
> 
> I guess the other question to ask is how many of us have a project with a 
> branch named "undo”?

Branches don’t enter into it.  The proposal was for “diff --undo”, not “diff 
undo”.
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Ron W
On Fri, Sep 11, 2015 at 6:28 PM, Warren Young  wrote:
>
> Let me put it a bit differently than before, since I don’t seem to be
> getting my point across.  When you say “fossil up” and get a whole pile of
> changes, your next question is, “What exactly is the content of those
> changes?”  This feature answers that question, and although it *happens* to
> do so using the undo mechanism, the user isn’t thinking about undoing the
> changes here, so why make them give a command that exposes this detail?


I see what you mean. Also, I think you missed something. It will produce a
diff for any undo-able operation, not just update.

Making it produce a diff specifically for the most recent update, while a
useful feature, would likely be a lot more work.
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Ross Berteig



On 9/11/2015 2:10 PM, Warren Young wrote:

On Sep 11, 2015, at 2:33 PM, Ross Berteig 
wrote:


I guess the other question to ask is how many of us have a project
with a branch named "undo”?


Branches don’t enter into it.  The proposal was for “diff --undo”,
not “diff undo”.


An early suggestion from either Stephen or D.R. Hipp was to name the 
feature either "diff --from-undo" or "diff --from undo" as clearer than 
"diff --undo". Allowing "--from undo" implies treating "undo" in that 
context (and perhaps other commands too) as a special name, which would 
have the small downside of making access to a branch (or just a tagged 
checkin) named "undo" harder.


I personally think that "diff --from undo" is the best of all the 
proposals floated in this thread, and tend to assume that "undo" is an 
unlikely branch or tag name.


--
Ross Berteig   r...@cheshireeng.com
Cheshire Engineering Corp.   http://www.CheshireEng.com/
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Warren Young
On Sep 11, 2015, at 4:19 PM, Ross Berteig  wrote:
> 
> On 9/11/2015 2:10 PM, Warren Young wrote:
>> On Sep 11, 2015, at 2:33 PM, Ross Berteig 
>> wrote:
>>> 
>>> I guess the other question to ask is how many of us have a project
>>> with a branch named "undo”?
>> 
> An early suggestion from either Stephen

It was Stephan, and I do see it now, thanks.  I only took note of the 
--from-undo option, and didn’t realize that by “special-case name” he meant 
“tag-like entity.”

> I personally think that "diff --from undo" is the best of all the proposals 
> floated in this thread, and tend to assume that "undo" is an unlikely branch 
> or tag name.

I agree that it is unlikely to cause a conflict.  I just don’t like that it 
makes you think about undo, when that is an implementation detail here.

Let me put it a bit differently than before, since I don’t seem to be getting 
my point across.  When you say “fossil up” and get a whole pile of changes, 
your next question is, “What exactly is the content of those changes?”  This 
feature answers that question, and although it *happens* to do so using the 
undo mechanism, the user isn’t thinking about undoing the changes here, so why 
make them give a command that exposes this detail?

This is all very bikesheddy, though.
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Andy Bradford
Thus said Richard Hipp on Fri, 11 Sep 2015 10:11:30 -0400:

> "fossil diff --versus-undo" maybe???

What if instead of making this a  feature of ``fossil diff'' it became a
feature of ``fossil undo?''

fossil undo --diff

Andy
--
TAI64 timestamp: 400055f36093
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Richard Hipp
On 9/11/15, Stephan Beal  wrote:
> On Fri, Sep 11, 2015 at 1:22 PM, Richard Hipp  wrote:
>
>> I'm not sure "--undo" is the right name for this option.  Other
>> suggestions?
>>
>
> --from-undo
> or:
> --from undo (special-case name)
>

The code on trunk now does "fossil diff --undo".  I'm very open to
changes in the name of that option, though.  Maybe "--from-undo" is
slightly better, but not a great deal.

Adding support for "undo" as a special-case name of "--from" seems
problematic since that would make it harder to do a diff against a
branch named "undo".

"fossil diff --versus-undo" maybe???
-- 
D. Richard Hipp
d...@sqlite.org
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Ron W
On Fri, Sep 11, 2015 at 1:12 PM, Warren Young  wrote:

> On Sep 11, 2015, at 8:11 AM, Richard Hipp  wrote:
> > Maybe "--from-undo" is slightly better, but not a great deal.
>
> Though --from-undo is better in that it tells you what the option does,
> you have to know that Fossil has an undo buffer to make sense of it.
> That’s exposing internal implementation details in the UI.
>

I disagree. The "fossil undo" command already tells you Fossil has an undo
buffer,

So "diff --from-undo" and "diff --to-undo" would clearly indicate that they
show the difference between the current "state" and what the state was
before the most recent undo-able operation (or what the state would be
after "fossil undo").


> How does “fossil diff --last” strike you?


I think "--last" would be interpreted as a short cut for "--to latest"
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Richard Hipp
On 9/11/15, Paolo Bolzoni  wrote:
> Dear list,
>
> Is there a way to get a diff between what I had in the disk before
> executing "fossil update" and after?

No there isn't.  The question hasn't come up before.  But now that you
mention it, it seems like it might be a useful thing to have, no?

Perhaps the "fossil diff" command should be augmented with an --undo
option that causes it to show a diff between what is currently checked
out and whatever is contained in the "undo" buffer.  That would allow
you to quickly determine the details of what your most recent fossil
command just changed, be it "fossil update" or "fossil revert" or
"fossil merge".

I'm not sure "--undo" is the right name for this option.  Other suggestions?
-- 
D. Richard Hipp
d...@sqlite.org
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Stephan Beal
On Fri, Sep 11, 2015 at 1:22 PM, Richard Hipp  wrote:

> I'm not sure "--undo" is the right name for this option.  Other
> suggestions?
>

--from-undo
or:
--from undo (special-case name)

?

-- 
- stephan beal
http://wanderinghorse.net/home/stephan/
http://gplus.to/sgbeal
"Freedom is sloppy. But since tyranny's the only guaranteed byproduct of
those who insist on a perfect world, freedom will have to do." -- Bigby Wolf
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Steve Stefanovich
Clever, but awkward in my opinion; the first place to look for such a feature 
would be under diff command. At least for me, that is.

My vote is for diff --from|--to undo, where 'undo' is a special tag, same as 
'ckout' in different context. I think it fits in such paradigm nicely.

The person who names branches 'undo' can be perhaps warned in the command help 
to use the hash instead.

S.


  Original Message
From: Andy Bradford
Sent: Saturday, 12 September 2015 09:15
To: Richard Hipp
Reply To: Fossil SCM user's discussion
Cc: Fossil SCM user's discussion
Subject: Re: [fossil-users] diff after update


Thus said Richard Hipp on Fri, 11 Sep 2015 10:11:30 -0400:

> "fossil diff --versus-undo" maybe???

What if instead of making this a  feature of ``fossil diff'' it became a
feature of ``fossil undo?''

fossil undo --diff

Andy
--
TAI64 timestamp: 400055f36093
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Andy Bradford
Thus said Steve Stefanovich on Sat, 12 Sep 2015 00:07:54 -:

> The person  who names  branches 'undo'  can be  perhaps warned  in the
> command help to use the hash instead.

I think  Fossil should have as  few reserved words in  its interfaces as
possible. If  it must be part  of ``fossil diff'' then  a --option makes
more sense  in my opinion.  But given that after  I update, or  do other
operations,  I am  told  that I  can  use ``fossil  undo''  to undo  the
changes, it  seemed to make  sense to me  that viewing changes  based on
undo belonged with undo, not diff.

Andy
-- 
TAI64 timestamp: 400055f379d6


___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Scott Robison
On Fri, Sep 11, 2015 at 5:14 PM, Andy Bradford 
wrote:

> Thus said Richard Hipp on Fri, 11 Sep 2015 10:11:30 -0400:
>
> > "fossil diff --versus-undo" maybe???
>
> What if instead of making this a  feature of ``fossil diff'' it became a
> feature of ``fossil undo?''
>
> fossil undo --diff
>

Ooh, I like this... +1

I also like fossil diff --undo, but if that is too confusing, perhaps
fossil diff --undo-buffer

Or other word for buffer.

-- 
Scott Robison
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Scott Robison
On Fri, Sep 11, 2015 at 6:07 PM, Steve Stefanovich  wrote:

> Clever, but awkward in my opinion; the first place to look for such a
> feature would be under diff command. At least for me, that is.
>
> My vote is for diff --from|--to undo, where 'undo' is a special tag, same
> as 'ckout' in different context. I think it fits in such paradigm nicely.
>
> The person who names branches 'undo' can be perhaps warned in the command
> help to use the hash instead.
>
> S.
>

Here is the stash version of diff:

 fossil stash diff ?STASHID?
 fossil stash gdiff ?STASHID?

Why not do it the same way for undo? It seems to be most in line with
precedent. Perhaps because undo doesn't currently have subcommands, just
options. Still, it would be the most intuitive thing based on existing
practice.

-- 
Scott Robison
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Johan Kuuse
fossil diff -before

or

fossil diff -before-commit

?
El 12/9/2015 1:14, "Andy Bradford"  escribió:

> Thus said Richard Hipp on Fri, 11 Sep 2015 10:11:30 -0400:
>
> > "fossil diff --versus-undo" maybe???
>
> What if instead of making this a  feature of ``fossil diff'' it became a
> feature of ``fossil undo?''
>
> fossil undo --diff
>
> Andy
> --
> TAI64 timestamp: 400055f36093
> ___
> fossil-users mailing list
> fossil-users@lists.fossil-scm.org
> http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
>
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Warren Young
On Sep 11, 2015, at 5:14 PM, Andy Bradford  wrote:
> 
> fossil undo --diff

While I admire your judo skill, that’s even worse from an exposure of 
implementation detail standpoint.  Also, it implies that you’re asking Fossil 
to undo changes, modified in some way using diffs.  Knowing nothing else, you 
could imagine that this command implements “undo everything except what is in 
foo.patch,” for example.
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Ross Berteig

On 9/11/2015 3:28 PM, Warren Young wrote:

On Sep 11, 2015, at 4:19 PM, Ross Berteig 

I personally think that "diff --from undo" is the best of all the
proposals floated in this thread, and tend to assume that "undo" is
an unlikely branch or tag name.

I agree that it is unlikely to cause a conflict.  I just don’t like
that it makes you think about undo, when that is an implementation
detail here.


But you just did something, and it made a bigger splash than you 
expected. One reaction is to immediate undo it so you can research it 
better. The other is to ask, as the OP did, what just happened here.



Let me put it a bit differently than before, since I don’t seem to be
getting my point across.  When you say “fossil up” and get a whole
pile of changes, your next question is, “What exactly is the content
of those changes?”  This feature answers that question, and although
it *happens* to do so using the undo mechanism, the user isn’t
thinking about undoing the changes here, so why make them give a
command that exposes this detail?


One reason is that this implementation detail is prominently exposed 
already. That is, the output of "fossil update " ends with text like 
this:


   lots of files listed as the update churns 
  ---
  updated-to:   d43847c96809b76481c173b9e75dee771b5541a9 2015-08-27 
14:24:09 UTC

  tags: trunk
  comment:  Update change log. (user: mistachkin)
  changes:  9 files modified.
"fossil undo" is available to undo changes to the working checkout.

So the user is directly reminded that undo exists, and that using it 
would reverse the update actions, and that was important enough to show 
that it is the last thing printed so it is guaranteed not to have 
scrolled away in the noise.


Other commands populate the undo buffer too, and usually mention that to 
the user in a similar way.


It is possible that a better name for the undo buffer itself could be 
"undo-buffer", which is at least a noun and not a verb. A noun would be 
better. Other nouns that might fit the bill include "buffer" or "cache".


If we also allowed reference to the stash, then "--from stash" could be 
the most recent (or only?) thing in it, and --from stash-foo could be 
the item in the stash with STASHID foo. Of course, it might be better to 
use "stash:foo" by analogy with "tag:foo" and "root:foo".



This is all very bikesheddy, though.


The feature clearly has some value, especially after an update does more 
than you expected. Having lots of ways to recover one's context is a 
good thing.


And naming things is hard. And in my experience it is harder to get 
right the more fundamental the concept is. This case seems pretty 
typical to me: the need was easy to express and the feature easy to 
create, but finding the right name for it is trickier.


--
Ross Berteig   r...@cheshireeng.com
Cheshire Engineering Corp.   http://www.CheshireEng.com/
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Shal Farley

On 9/11/2015 7:11 AM, Richard Hipp wrote:
>
> "fossil diff --versus-undo" maybe???

Along the same lines, how about:

"fossil diff --updated"

The semantics being it is a diff of the things you just updated 
(implicitly with respect to what they were before the update command).


-- Shal


--
Shal Farley s...@cheshireeng.com
Cheshire Engineering Corporation  http://www.CheshireEng.com
120 West Olive Avenue+1 626 303 1602
Monrovia, CA 91016   FAX +1 626 303 1590
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread sky5walk
Cool, I've often wanted this feature.
fossil diff --whatif

On Fri, Sep 11, 2015 at 10:11 AM, Richard Hipp  wrote:

> On 9/11/15, Stephan Beal  wrote:
> > On Fri, Sep 11, 2015 at 1:22 PM, Richard Hipp  wrote:
> >
> >> I'm not sure "--undo" is the right name for this option.  Other
> >> suggestions?
> >>
> >
> > --from-undo
> > or:
> > --from undo (special-case name)
> >
>
> The code on trunk now does "fossil diff --undo".  I'm very open to
> changes in the name of that option, though.  Maybe "--from-undo" is
> slightly better, but not a great deal.
>
> Adding support for "undo" as a special-case name of "--from" seems
> problematic since that would make it harder to do a diff against a
> branch named "undo".
>
> "fossil diff --versus-undo" maybe???
> --
> D. Richard Hipp
> d...@sqlite.org
> ___
> fossil-users mailing list
> fossil-users@lists.fossil-scm.org
> http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
>
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Zakero
On Fri, Sep 11, 2015 at 9:11 AM, Richard Hipp  wrote:

> On 9/11/15, Stephan Beal  wrote:
> > On Fri, Sep 11, 2015 at 1:22 PM, Richard Hipp  wrote:
> >
> >> I'm not sure "--undo" is the right name for this option.  Other
> >> suggestions?
> >>
> >
> > --from-undo
> > or:
> > --from undo (special-case name)
> >
>
> The code on trunk now does "fossil diff --undo".  I'm very open to
> changes in the name of that option, though.  Maybe "--from-undo" is
> slightly better, but not a great deal.
>
> Adding support for "undo" as a special-case name of "--from" seems
> problematic since that would make it harder to do a diff against a
> branch named "undo".
>
> "fossil diff --versus-undo" maybe???
> --
> D. Richard Hipp
> d...@sqlite.org
> ___
> fossil-users mailing list
> fossil-users@lists.fossil-scm.org
> http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
>


Looking at the "fossil checkout" command, there is ?VERSION? parameter and
this parameter can be replaced with "--latest".   Since the "fossil diff"
command already has ?--from VERSION? and ?--to VERSION?, perhaps a similar
convention can be used:

"fossil diff --from --update"  or  "fossil diff --to --update"

Not sure which would be more appropriate...
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Warren Young
On Sep 11, 2015, at 8:11 AM, Richard Hipp  wrote:
> 
> On 9/11/15, Stephan Beal  wrote:
>> On Fri, Sep 11, 2015 at 1:22 PM, Richard Hipp  wrote:
>> 
>>> I'm not sure "--undo" is the right name for this option.  Other
>>> suggestions?
>>> 
>> 
>> --from-undo
>> or:
>> --from undo (special-case name)
> 
> I'm very open to
> changes in the name of that option, though.  Maybe "--from-undo" is
> slightly better, but not a great deal.

diff --undo sounds like you’re asking it to undo the diff, which makes no sense.

What I want is a shorter version of “fossil diff --what-just-happened”. :)

Though --from-undo is better in that it tells you what the option does, you 
have to know that Fossil has an undo buffer to make sense of it.  That’s 
exposing internal implementation details in the UI.

How does “fossil diff --last” strike you?
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread Scott Doctor

diff --erence

misspelled it


Scott Doctor
sc...@scottdoctor.com

On 9/11/2015 10:38 AM, Scott Doctor wrote:

diff --erent

or

diff --erance


Scott Doctor
sc...@scottdoctor.com

On 9/11/2015 10:27 AM, Richard Hipp wrote:

On 9/11/15, Warren Young  wrote:
diff --undo sounds like you’re asking it to undo the diff, which 
makes no

sense.

I agree.  I'm just having trouble coming up with an alternative.


How does “fossil diff --last” strike you?

Still a little generic, I think, but moving in the right direction.


___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users


Re: [fossil-users] diff after update

2015-09-11 Thread j. van den hoff

diff --before(-update)

On Fri, 11 Sep 2015 20:20:53 +0200, Warren Young  wrote:


On Sep 11, 2015, at 11:41 AM, Ron W  wrote:


On Fri, Sep 11, 2015 at 1:12 PM, Warren Young  wrote:

Though --from-undo is better in that it tells you what the option does,  
you have to know that Fossil has an undo buffer to make sense of it.   
That’s exposing internal implementation details in the UI.


I disagree. The "fossil undo" command already tells you Fossil has an  
undo buffer,


No, the undo command just tells you that Fossil has some unspecified way  
to achieve an undo.  It doesn’t tell you how it accomplishes that.


I don’t want Fossil users to be required to think about how undo is  
implemented when they ask Fossil, “What just happened?”



How does “fossil diff --last” strike you?

I think "--last" would be interpreted as a short cut for "--to latest”


No, latest is “now.”  “Last” is “then”.  (“When will now, be then?”   
“Soon.”)


If it’s the “L” that’s hanging you up, there are synonyms.  --prior and  
--prev come to mind.

___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users



--
Using Opera's revolutionary email client: http://www.opera.com/mail/
___
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users