Re: edx :: adding Backup, Restore, and purge to the top-line menu
- Posted by K_D_R
Apr 10, 2013
-- modified "mods" routine: If the current file is a
-- backup file with one or more "~" appended to the file_name,
-- this routine will compare the current file with the base
-- file which is the file which would be overwritten, with
-- the restore command, "ESCAPE & "R". For example, if the
-- current file is "edx.ex~~", this routine will execute:
-- shell(compare_cmd edx.ex edx.ex~~ | more)
-- If the current file does not have a "~" in the extension,
-- it will perform as before.
elsif command[1] = 'm' then
save_file(TEMPFILE)
if stop then
stop = FALSE
if match("~", file_name) then
-- show differences between original source file and the current file, if
-- current file is a backup file with one or more "~" appended to the extension
command = compare_cmd & file_name[1..match("~", file_name)-1]
else
-- show differences between the current file buffer and file on disk
command = compare_cmd & file_name
end if
shell(command & " " & TEMPFILE & " | more")
normal_video()
goto_line(0, b_col)
editbuff = TRUE
end if
|
Not Categorized, Please Help
|
|