The tag has no wiki summary.

learn more… | top users | synonyms (1)

2
votes
3answers
632 views

Substituting a multi-line pattern in an HTML file

I have a series of HTML files that contain two lines like this: <body> <h1>Title</h1><p> <a href="url">Description</a><br> I want to replace this text with ...
2
votes
1answer
1k views

How can I search and replace in Firefox?

I am moderator on a site with lots of structured content and regularly edit posts for poor formatting (in particular Markdown and LaTeX). Many of those tasks are tedious and could easily be performed ...
2
votes
2answers
32 views

Find & replace on a folder of .txt (but only first 1-3 lines)

I have a folder of .txt files. They all look like this: Title: Title of blog post. Tags: tag1,tag2,tag3 Text on the post. Just my thoughts. > A blockqoute Written in *markdown.* Using ...
2
votes
2answers
184 views

Microsoft Word 2010: “replace all” with same word + something else

I want to find all bolded words and replace them with the same word, unbolded, but with a symbol after it indicating that it was bolded. So for example Yesterday, love was such an easy game to play. ...
2
votes
1answer
1k views

Multiple find and replace in a word document

I want to do a series of find and replace operations. Unfortunately, the documents I have to work on are in Word (.docx) format so I cannot script this. These are book chapters so formatting is ...
2
votes
2answers
186 views

Find And Replace strings containing a caret

Consider a string to be replaced in Microsoft Word Foo^Bar Using the Find and Replace dialog, Word interprets a caret(^) character as a control character to help find predefined elements in your ...
2
votes
2answers
278 views

Regular Expression Help Needed in Notepad++

I need to know the syntax for a regular expression (notepad++) to help me find/replace every instance of following string in a text document the string is as follows Where do you want to go next? ...
2
votes
3answers
99 views

using vims pattern-multi-items {n} to match the 5th space in a line

With this entry from our crontab 1 3 1 * * find /var/log/tomcat/* -mtime +61 -type f -delete I want to match the 5th space char so I can separate the command part from the time field part. Cron ...
2
votes
1answer
907 views

Removing HTML tags in Notepad++

I'm trying to remove some tags using the Find and Replace feature of Notepad++. What I'm trying to remove for example is <num> and </num>. Right now I'd input <num> and replace it, ...
2
votes
1answer
35 views

Delete text in excel cell with certain format

How do I easily delete strings in excel cells with certain formatting.I want to get cell with formatted string deleted like the second cell The string could be anything the only thing that define ...
2
votes
1answer
55 views

How can I add an additional line break (paragraph return) to each line break found in an Open Office Document?

I have tons of text that runs together paragraph breaks like so: off the wounded, and with the same calmness and composure as before resumed the watch over his armor. But these freaks of his guest ...
2
votes
3answers
190 views

Word find/replace: add space to postal code with wildcards

Using the “Find and Replace” dialog in Microsoft Word 2003, I want to search a list of addresses for postal codes (Canadian) that do not have a space in them, e.g., M2N3X6 L4C2A9 K5G1S7 and put a ...
2
votes
3answers
186 views

Is there a find and replace application with multiple rules?

I'm looking for a search and replace tool that takes a list of rules and either a file (or directory) and runs those rules on the files. I have a bunch of different things that need to be changed in ...
2
votes
1answer
1k views

grep + sed for find & replace fun!

I have a dev copy of a website set up that has quite a few hardcoded references to its live counterpart. I would like to replace all occurrences of "www." with "dev." in all files. I think I can use ...
2
votes
1answer
3k views

Notepad++ excluding find filters

In Notepad++ I want to search in all file types except one. For instance: I want to search in all files but not .class files. Can the Notepad++ filter can be configured to work this way?
2
votes
1answer
3k views

Komodo Edit: How to use Tabs and Carriage Returns in Find/Replace?

In NoteTab Pro, I could use tabs and returns in the find and replace dialogs by using ^t and ^p. Now I have switched to Komodo Edit which is much more powerful, and I can't find any way to search for ...
2
votes
1answer
70 views

Use perl to do multi-line replacement [closed]

I have to do some replacements in many *.c files. I want to do the replacement like this: original: printf("This is a string! %d %d\n", 1, 2); result: print_record("This is a string! %d %d", 1, 2); ...
2
votes
2answers
557 views

How do I replace all WOrds with FAlse SEcond LEtter Capitalization in lots of Word documents?

I need to mass-correct large amounts of documents in German. I need to handle several hundred pages of text. I have written a macro to do mass find-and-replace operations on common spelling mistakes. ...
2
votes
1answer
2k views

How can I automate modifying key/value pairs in a shell script?

I often want to automate this sort of task in a shell script: if the line: SOMEKEY=SOMEVALUE exists in a file, then change it to SOMEKEY=SOMEOTHERVALUE otherwise, append the line ...
2
votes
1answer
484 views

Notepad++ want to use RegEx to seek minimum-length strings

Only been using Notepad++ v 5.92 for a few weeks, and RegEx for a few hours (!!) I want to use Find & Replace for UPPERCASE strings of a minimum length to change them to "Title Case" or "Sentence ...
2
votes
2answers
7k views

Using sed to replace string with special characters in XML file

I am having difficulty getting sed to replace a string of text in an XML file, despite the fact that I have no trouble using grep to find that same string. Since the new string and old string to be ...
2
votes
1answer
2k views

How to find and replace on regedit?

I use win_xp_sp3 inside my virtualbox i was mapped all the xp folder destination into my host machine in regedit. and now i need to change the my username and i don't remember all files i changed. is ...
2
votes
2answers
850 views

Text editor on Windows to delete large block of copyright text in multiple source files?

Optional Background Information: [ The author of a Java open source project I am using has changed the copyright notice in every file in the project. As a result, I can no longer diff between the ...
2
votes
2answers
2k views

How can I do a text find and replace with a standard batch file?

Without any additional tools, using just the command line that comes with Windows 7, how can I create a batch file that will perform a file and replace of some text in a file?
2
votes
0answers
11 views

How to find and replace hyphens with minus signs in Microsoft Word 2013?

When editing scientific texts, I often have to replace hyphens incorrectly used as minus signs with proper minus signs (i.e. U+2212). I'm working in Microsoft Word 2013 and trying to use a wildcard ...
2
votes
0answers
54 views

How do I stop command-f from sharing state across applications on Mac OS X (10.8.2)?

If I have a find bar (command-f) open in two applications, and I change the text in one, the text in the other changes to match as soon as I tab over to the second application. Is there a way to turn ...
2
votes
0answers
124 views

How can I add non-breaking space (&nbsp;) in dates using search and replace in DreamWeaver

Example: January 1, 2012 This is the current text, but I want to change the source code to: January&nbsp;1&nbsp;2012 automatically using search and replace. There are multiple dates ...
2
votes
4answers
463 views

Text-Editing program : muti-search-replace/multi-regex?

I have a long and arduous text file, and I need to do lots and lots of the same search-replaces on it inside of selections. Is there a text editing program where I can do multiple find/replace (or ...
1
vote
6answers
10k views

Find and Replace several several different values all at once

I have a file with multiple instances of Text_1 and Text1 and I need to replace both those strings with Text_A and TextB respectively. Currently I'm doing two Find and Replace functions on each ...
1
vote
3answers
2k views

Using sed to replace text from a list of files from find

Given the following find command: find . | xargs grep 'userTools' -sl How can I use sed on the results of that command? output: ./file1.ext ./file2.ext ./file3.ext
1
vote
4answers
145 views

Search and Replace string in Vim

I have code similar to this: $POST_['%'] where % is any length any letter+numbers string and I want to replace it with mysql_real_escape_string($POST['%']) so far I have built up this command ...
1
vote
1answer
271 views

How to replace text using regex with back-referece in Notepad++?

I'm converting Windows batch script .bat to Linux batch script .sh What takes time a lot is to change the way .bat script use variables. i.e. In Windows @set varName=122 echo %varName% In Linux ...
1
vote
2answers
1k views

command line find/replace help

I've got a set of 5000+ files that I need to do a simple search and replace in. I have been doing it in a text editor (EditPlus) by opening 500 files at a time, doing a global search/replace, saving ...
1
vote
1answer
506 views

How to replace every text in a Mac folder?

In Mac OS, how do I find and replace a certain text in all of a directory and its sub directories?
1
vote
4answers
4k views

How to replace html using dreamweaver's “find and replace”?

I want to do find and replace for example . In dreamweaver's find and replace <p><strong>Business Development</strong></p> into <h4>Business Development</h4> I have to change in ...
1
vote
3answers
7k views

Notepad++ find string with a new-line and replace

[Notepad++ Question] How do I use find-and-replace to replace the attribute of a series of tags using expression? Case scenario: Let's say I have a couple of lines of something like this: ...
1
vote
2answers
2k views

Replacing last character at the end of each line in a file

I have a file with the format: abc!12345th! bcv!2345568790hg! fjldslj12123344!!flgnjlk! I was trying to figure out how to remove the ! symbol at the end of each line. I tried using "Find and ...
1
vote
2answers
127 views

Delete first half of line in Notepad++

I think the following can be done in a search & replace function. How can I select until yahoo.com: overjoyedradica@yahoo.com:SQOVTJOHEN and turn it to: :SQOVTJOHEN
1
vote
2answers
945 views

How to “demote” all titles and headings in Word 2010?

I built a large help document for an application I wrote. I used all the default styles in Word 2010, including "Title", "Heading 1", "Heading 2", etc. Sadly, when I generated the Table of Contents, ...
1
vote
5answers
6k views

Find and replace text in multiple files

I’m hoping someone might lend their time in helping me create a batch file or similar for finding and replacing text in several files. I have tried many “search and replace” utilities but have not ...
1
vote
1answer
162 views

How can I replace “/>XXXXX”/> with "/> within a selection

I have a CSV file which I am editing with Notepad++. There is a section of about 500 consecutive lines where I want to replace "/>XXXXX"/> with "/> where XXXXX are numbers. Is there a way to ...
1
vote
3answers
43 views

How to Copy words highlighted after search directly into command line with shortcut?

Here is the situation, for example, I have several lines like this: foo test foo I searched "foo" with "/" and all the two "foo"s above are highlighted. And now I want to replace "foo" with ...
1
vote
1answer
4k views

Multi-Line Sed Replace

Consider the following text (incidentally, part of a MySQL dump): CREATE TABLE `table` ( `id` int(10) NOT NULL auto_increment, `name` varchar(100) NOT NULL default '', `description` text NOT ...
1
vote
1answer
254 views

Replace a regular expression within vim with an output produced by a console command with the expression as its argument?

let's say I have a file with the following content: This is a _file_ which has some _special_ keywords, that I would _like_ to replace. I can do a search and replace of the speical keywords ...
1
vote
1answer
917 views

Replace a block of numbers in sed

I've been fiddling with this for a while now and can't seem to figure it out. What I'm trying to do is replace all numbers in a file with a single #. Sounds simple, and it should be, but I can't get ...
1
vote
2answers
1k views

Notepad++ RegEx does not work with min and max occurence

I want to find two or more (max 9) white-space characters and replace it with newlines. My RegEx syntax is as follows: [\s]{2,9} However, Notepad++'s RegEx doesn't seem to work with curly braces. ...
1
vote
2answers
86 views

Trying to cleanse log files on a Linux machine, currently using sed

I have a large amount of log files that I need to remove sensitive data from. The sensitive data is provided to me in a text file and is prone to change. I had hoped to do the equivalent of this: ...
1
vote
2answers
398 views

Change YYYY-MM-DD to YYYYMMDD everywhere in file

I can't just delete all of the hyphens, because elsewhere they are used as minus signs. I can find these dates with [0-9]\{4\}-[0-9]\{2\}-[0-9]\{2\} but I can't figure out how to keep those three ...
1
vote
1answer
347 views

Add constant value to numeric XML attribute

Background Add a constant value to numbers matched with a regular expression, using vim (gvim). Problem The following regular expression will match width="32": /width="\([0-9]\{2\}\)" Question ...
1
vote
1answer
327 views

Regular Expressions find/replace

How to I do a search for @anydomain.anyTLD using regular expressions?