[Feature request] File date and time check

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

[Feature request] File date and time check

Steven Pemberton-3
This is taken from how emacs works, and has saved my bacon a number of  
times there, and would have saved me a lot of work if Amaya also did it.  
It consists of two checks:

1) If the document is in 'unedited' state (i.e. where ^S has no effect),  
and I start to edit it, if it is possible to check the date and time of  
the original file, and the date and time of the file has changed since  
loading the document, warn "the document has changed on disk, are you sure  
you want to edit it?"

2) Similarly, just before saving a file, check that the date and time of  
the destination is still the same as it was, warning "The document has  
changed on disk, are you sure you want to save it?" if not.

Best wishes,

Steven Pemberton

Reply | Threaded
Open this post in threaded view
|

Re: [Feature request] File date and time check

Laurent Carcone
Hello Steven,

Steven Pemberton a écrit :
> This is taken from how emacs works, and has saved my bacon a number of
> times there, and would have saved me a lot of work if Amaya also did
> it. It consists of two checks:
>
> 1) If the document is in 'unedited' state (i.e. where ^S has no
> effect), and I start to edit it, if it is possible to check the date
> and time of the original file, and the date and time of the file has
> changed since loading the document, warn "the document has changed on
> disk, are you sure you want to edit it?"

We'll add this feature on our todo list.

>
> 2) Similarly, just before saving a file, check that the date and time
> of the destination is still the same as it was, warning "The document
> has changed on disk, are you sure you want to save it?" if not.

Amaya used to manage the http etags but there was some problems and some
users complained because they couldn't save their document, there was a
'conflict' message even when they were the only ones to modify the
document. so we disabled this option.

Regards,
Laurent Carcone
>
> Best wishes,
>
> Steven Pemberton
>
>


Reply | Threaded
Open this post in threaded view
|

Re: [Feature request] File date and time check

Keith Rubow-2
Please see my comment regarding request number 2 below.

Keith Rubow

Laurent Carcone wrote:

> Hello Steven,
>
> Steven Pemberton a écrit :
>> This is taken from how emacs works, and has saved my bacon a number
>> of times there, and would have saved me a lot of work if Amaya also
>> did it. It consists of two checks:
>>
>> 1) If the document is in 'unedited' state (i.e. where ^S has no
>> effect), and I start to edit it, if it is possible to check the date
>> and time of the original file, and the date and time of the file has
>> changed since loading the document, warn "the document has changed on
>> disk, are you sure you want to edit it?"
>
> We'll add this feature on our todo list.
>
>>
>> 2) Similarly, just before saving a file, check that the date and time
>> of the destination is still the same as it was, warning "The document
>> has changed on disk, are you sure you want to save it?" if not.
>
> Amaya used to manage the http etags but there was some problems and
> some users complained because they couldn't save their document, there
> was a 'conflict' message even when they were the only ones to modify
> the document. so we disabled this option.
However, Laurent Carcone is not asking for a "feature" that would
_prevent_ a user from saving the document if the original file had been
changed since being opened. The feature request is to simply warn the
user that the document has been changed, and give the user a choice of
saving the document or not. Presumably the user could also chose to do a
Save As to a new file name, and then then compare the two files to see
what other changes had been made to the document to see if the two sets
of changes need to be manually merged. I think this is an excellent
suggestion.

>
> Regards,
> Laurent Carcone
>>
>> Best wishes,
>>
>> Steven Pemberton
>>
>>
>
>
> .
>


Reply | Threaded
Open this post in threaded view
|

Re: [Feature request] File date and time check

Charles McCathieNevile-2
On Mon, 19 Jul 2010 18:03:49 +0200, Keith Rubow <[hidden email]>  
wrote:

> Laurent Carcone wrote:
>> Steven Pemberton a écrit :
>>> This is taken from how emacs works, and has saved my bacon a number of

>>> 2) Similarly, just before saving a file, check that the date and time  
>>> of the destination is still the same as it was, warning "The document  
>>> has changed on disk, are you sure you want to save it?" if not.
>>
>> Amaya used to manage the http etags but there was some problems and  
>> some users complained because they couldn't save their document, there  
>> was a 'conflict' message even when they were the only ones to modify  
>> the document. so we disabled this option.
> ... The feature request is to simply warn the user that the document has  
> been changed, and give the user a choice of saving the document or not.  
> Presumably the user could also chose to do a Save As to a new file name,  
> and then then compare the two files to see what other changes had been  
> made to the document to see if the two sets of changes need to be  
> manually merged. I think this is an excellent suggestion.

+1

cheers

Chaals (Who might write a patch before the heat death of the universe, but  
suspects he won't manage :( )

--
Charles McCathieNevile  Opera Software, Standards Group
     je parle français -- hablo español -- jeg lærer norsk
http://my.opera.com/chaals       Try Opera: http://www.opera.com

Reply | Threaded
Open this post in threaded view
|

Re: [Feature request] File date and time check

Leif Halvard Silli-4
Charles McCathieNevile, Thu, 22 Jul 2010 21:23:31 +0200:

> On Mon, 19 Jul 2010 18:03:49 +0200, Keith Rubow
> <[hidden email]> wrote:
>
>> Laurent Carcone wrote:
>>> Steven Pemberton a écrit :
>>>> This is taken from how emacs works, and has saved my bacon a number of
>
>>>> 2) Similarly, just before saving a file, check that the date and
>>>> time of the destination is still the same as it was, warning "The
>>>> document has changed on disk, are you sure you want to save it?"
>>>> if not.
>>>
>>> Amaya used to manage the http etags but there was some problems and
>>> some users complained because they couldn't save their document,
>>> there was a 'conflict' message even when they were the only ones to
>>> modify the document. so we disabled this option.
>> ... The feature request is to simply warn the user that the document
>> has been changed, and give the user a choice of saving the document
>> or not. Presumably the user could also chose to do a Save As to a
>> new file name, and then then compare the two files to see what other
>> changes had been made to the document to see if the two sets of
>> changes need to be manually merged. I think this is an excellent
>> suggestion.
>
> +1

I too think, that in principle, it is a good proposal. However ... it
also depend on the implementation. When I started to use VIM, it
irritated me a lot that it remembers security copies of documents it
has worked with - and offers to "recover/delete/whatnot" the document
based on those copies "all the time". Simply editing the document with
another editor will cause VIM to "scream" next time VIM opens that
file. The way I have learned to handle it, so far, is to simply delete
the things that VIM wants me to consider. (Of course, emacs is of
course so much better.) ;-)

So, with the mixed http etags story in memory, may be the feature
Steven asked for should be a pro option that users can enable. That, or
it has to be a really good implementation, which "screams" only when
necessary ...
--
leif halvard silli