Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Emacs Question:  How to delete all occurances of <whatever> and </whatever>

Posted on 2004-10-06
2
Medium Priority
?
242 Views
Last Modified: 2010-08-05
Hello everyone,

Using emacs, I'm trying to delete all tags of <whatever> and </whatever>  (whatever being any tags that start with < and end with > ).  So what I did was:

M-x query-replace-regexp
then typed without quotes  ' <.*?> '
and didn't type anything to replace it with.

This worked for all tags that were on the same line but for those that weren't, it did not delete.  Does anyone know what I could do to make this work?

Thanks for your help :)
0
Comment
Question by:justinmaurer
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 23

Accepted Solution

by:
brettmjohnson earned 2000 total points
ID: 12241545
Try '<[^>]*>'  instead.

0
 

Author Comment

by:justinmaurer
ID: 12241625
thank you much!
0

Featured Post

How to Use the Help Bell

Need to boost the visibility of your question for solutions? Use the Experts Exchange Help Bell to confirm priority levels and contact subject-matter experts for question attention.  Check out this how-to article for more information.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When you do backups in the Solaris Operating System, the file system must be inactive. Otherwise, the output may be inconsistent. A file system is inactive when it's unmounted or it's write-locked by the operating system. Although the fssnap utility…
Why Shell Scripting? Shell scripting is a powerful method of accessing UNIX systems and it is very flexible. Shell scripts are required when we want to execute a sequence of commands in Unix flavored operating systems. “Shell” is the command line i…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
Suggested Courses

604 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question