Mass Search and Replace?
Mass Search and Replace?
I'm restructuring the global variables.
Any decent text editors that you can setup a table with 2 columns to do a batch search and replace?
Manual search and replaces are subject to human error and I have about 70 to do.
Any decent text editors that you can setup a table with 2 columns to do a batch search and replace?
Manual search and replaces are subject to human error and I have about 70 to do.
The night is young. How else can I annoy the world before sunsrise?
Inquisitive minds want to know ! And if they don't -- well like that ever has stopped me before ..
-
behind_you
- Posts: 237
- Joined: Sat Feb 05, 2011 6:57 am
- Location: Tripoli, Libya
I already have singular replace in all files. I need something that do 70+ replaces with like 2 columns. Otherwise it'll take maybe an hour. 
The night is young. How else can I annoy the world before sunsrise?
Inquisitive minds want to know ! And if they don't -- well like that ever has stopped me before ..
I was hoping for something open source or something built-in to one of the more notable text editors like Notepad++ or UltraEdit or such.
But this is gonna have to do ... http://www.replsoft.com/replacer.html
But this is gonna have to do ... http://www.replsoft.com/replacer.html
The night is young. How else can I annoy the world before sunsrise?
Inquisitive minds want to know ! And if they don't -- well like that ever has stopped me before ..
-
behind_you
- Posts: 237
- Joined: Sat Feb 05, 2011 6:57 am
- Location: Tripoli, Libya
www.replsoft.com/replacer.html
Havent tried this but its what you are looking for. Tell me if it works.
Havent tried this but its what you are looking for. Tell me if it works.
-
behind_you
- Posts: 237
- Joined: Sat Feb 05, 2011 6:57 am
- Location: Tripoli, Libya
U beat me to it...Baker wrote:I was hoping for something open source or something built-in to one of the more notable text editors like Notepad++ or UltraEdit or such.
But this is gonna have to do ... http://www.replsoft.com/replacer.html
That tool is actually rather sophisticated. It's not bad. I'd still prefer a built-in plug-in for a well-known text editor, but it is getting the job done.
The night is young. How else can I annoy the world before sunsrise?
Inquisitive minds want to know ! And if they don't -- well like that ever has stopped me before ..
You could write a macro for JEdit.
Improve Quaddicted, send me a pull request: https://github.com/Quaddicted/quaddicted-data

This thing is doing the job "ok". And I don't have to write macros. I just export 2 column Excel worksheet as .csv and import it. And then correct small issues as the Quake engine occasionally has local and global variables with the same name.
(Aside, some of the console and screen drawing variables have the absolutely worst names ... telling you really nothing about what they do. On the plus side: 30 minutes later trying to sort them out and the console code is easy to understand now for me.
The night is young. How else can I annoy the world before sunsrise?
Inquisitive minds want to know ! And if they don't -- well like that ever has stopped me before ..
-
behind_you
- Posts: 237
- Joined: Sat Feb 05, 2011 6:57 am
- Location: Tripoli, Libya
-
dreadlorde
- Posts: 268
- Joined: Tue Nov 24, 2009 2:20 am
- Contact:
I thought about that, but then I thought about to actually do it.dreadlorde wrote:Try sed.
How would you do it? 70 pipes for each file?
Improve Quaddicted, send me a pull request: https://github.com/Quaddicted/quaddicted-data
-
dreadlorde
- Posts: 268
- Joined: Tue Nov 24, 2009 2:20 am
- Contact:
sed -f file.sed file(s). file.sed contains multiple lines of search and replace regex commands, which will be iterated through on the file.Spirit wrote: I thought about that, but then I thought about to actually do it.
How would you do it? 70 pipes for each file?
The file given to -f doesn't need the suffix .sed, i provided it to be clearer in the answer.
Get off my lawn!Ken Thompson wrote:One of my most productive days was throwing away 1000 lines of code.
This might be a bit late for Baker, but may be of use in the future.
Until 12 midnight you can get a free copy of AKS Text Replacer at Giveaway of the Day
I think this might have been what Baker was looking for?
Anyways, thought I'd share. If you're wanting more info on the program here is the website
Until 12 midnight you can get a free copy of AKS Text Replacer at Giveaway of the Day
I think this might have been what Baker was looking for?
Anyways, thought I'd share. If you're wanting more info on the program here is the website
Good God! You shot my leg off!