emacs-devel
[Top][All Lists]
Advanced

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

How can I view the output of a command on a file when visit-file?


From: Stephen Eglen
Subject: How can I view the output of a command on a file when visit-file?
Date: Wed, 05 Feb 2014 11:01:29 +0000
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux)

Hi,

There is a file on emacswiki that when you visit a file foo.doc, it will
run the antiword program and view that output, rather than the binary
contents of the file.

  http://www.emacswiki.org/cgi-bin/wiki/no-word.el

Likewise, if you visit a .png file, doc-view mode renders the image (and
allows you to see the file contents by hitting C-c C-c)

I'd like to do something similar to doc-view for a few other file types:

file.odt -> show the output of "odt2txt file.odt"
file.ods -> show the output of "odt2txt file.ods"
file.h5  -> show the output of "h5dump file.h5"

Before I reinvent the wheel with some code, I thought I'd just ask if
anyone has seen code already that handles this kind of idea?  

Thanks, Stephen






reply via email to

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