jed-users mailing list

[2005 Date Index] [2005 Thread Index] [Other years]
[Thread Prev] [Thread Next]      [Date Prev] [Date Next]

Re: unset the "changed on disk" flag


On 10.10.05, John E. Davis wrote:
> G. Milde <g.milde@xxxxxx> wrote:
> >I still did not find the right way to tell JED a file is no longer "changed
> >on disk" after relaoding it into the buffer. My function is
> [...]
> >What am I missing
> 
> Rather than trying to work around the problem, I would rather
> understand what it is and fix it.  

Exactly.

> When you say that the file is "no longer changed on disk", what exactly
> do you mean?  

I mean after relaoding a file (i.e. loading the version from disk into
the buffer) the changes of the file on disk are now updated in the buffer.

> Has the file really changed and you just want to "pretend" that it has
> not?  

If a file changed on disc, I sometimes want to load it with

   erase_buffer(whatbuf());
   () = insert_file(file);

so that I can revert the "reload" (or "update to disk") version with
undo and also keep buffer-local variables.

> If so, there is no bug to fix, but perhaps a new function can be added
> to tell jed not to check for such conditions for a specified buffer.

.. or a "reload_buffer" function that does this and resets the
changed-on-disk flag.

Guenter

-- 
G.Milde web.de

--------------------------
To unsubscribe send email to <jed-users-request@xxxxxxxxxxx> with
the word "unsubscribe" in the message body.
Need help? Email <jed-users-owner@xxxxxxxxxxx>.


[2005 date index] [2005 thread index]
[Thread Prev] [Thread Next]      [Date Prev] [Date Next]