help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: md5 checksum of a img file, or get the value of 100th byte


From: Ted Zlatanov
Subject: Re: md5 checksum of a img file, or get the value of 100th byte
Date: Mon, 09 Jun 2008 10:04:45 -0500
User-agent: Gnus/5.110011 (No Gnus v0.11) Emacs/23.0.60 (gnu/linux)

On Sat, 07 Jun 2008 09:34:01 +0300 Eli Zaretskii <address@hidden> wrote: 

>> From: Ted Zlatanov <address@hidden>
>> Date: Fri, 06 Jun 2008 17:45:43 -0500
>> 
EZ> For editing, I submit that there should be no reason to edit such
EZ> large files.
>> 
>> Maybe 10 years ago that was true.  Today I see huge (over 300 MB) files
>> very often (as a programmer and as a sysadmin).  Logs of all sorts, for
>> instance, and database dumps.

EZ> Why would you want to _edit_ (as opposed to _view_) these files?

As an example, at a previous job all server log time stamps were in Unix
epoch offsets.  That was hard to interpret, so I often had to filter the
whole file to rewrite those time stamps to UTC ISO format.  I then
needed to do further modifications, e.g. look at only fields 3-9 and
12.  I wrote many custom tools to make this easier, but in Emacs it
would have been trivial.  Sure, I can write a custom mode or pipe the
file through a filter, but I *knew* I'd never need the original time
stamps, so saving the ISO dates the first time was productive, and
editing on the fly in general would have made my life easier.

As another example, I often have to peek inside a large database dump or
import CSV/TSV/etc. file and understand what went wrong.  Once
understood, it's more efficient to fix and save inside Emacs than split,
modify, recombine outside Emacs.

Expected memory sizes today are 2-8 GB.  Disk speed is really the major
issue with editing a 300MB file, and that's improving swiftly lately.  I
think it's feasible and not too painful to allow this kind of editing.
How hard would it be to customize the Emacs defaults for that to happen?

EZ> Please note that I agreed that viewing such large files chunk-wise
EZ> would be useful, indeed.

Do you or anyone know of an existing less-like mode for Emacs?  If not,
I'll put it on my TODO list.

Thanks
Ted


reply via email to

[Prev in Thread] Current Thread [Next in Thread]