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

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

Re: Emacs as a command line tool


From: address@hidden
Subject: Re: Emacs as a command line tool
Date: Thu, 19 Feb 2004 02:01:37 -0500
User-agent: KNode/0.7.1

David Rasmussen wrote:

> Joakim Hove wrote:
>> 
>> how about redirection:
>> 
>> expand file > tmp_file ; mv tmp_file file
>> 
> 
> Sure, but that doesn't solve the problem with batch runs. I can't do
> 
> expand *.cpp
> 
> which would have been very easy.
> 
> /David

It just occurred to me (when I was thinking of something else, oddly) an 
easy way to solve your problem--at least for me.

Make a macro.

First, use the dired function to set up the directory with all these files. 
Make sure they're set as whole lines. Then start the macro recording 
function.

Search for the cpp extension, stop the search, hit <return> to call the file 
up, untabify the file, save it, close it, returning to dired. End the 
macro.

Now all you have to do is tell the macro to repeat the required number of 
times.

--Rod

__________

Author of "Linux for Non-Geeks--Clear-eyed Answered for Practical Consumers" 
and "Boring Stories from Uncle Rod." Both are available at 
http://www.rodwriterpublishing.com/index.html

To reply by e-mail, take the extra "o" out of the name.



reply via email to

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