| | |
Changing a string in 1500 documents
Please support our Shell Scripting advertiser: Programming Forums - DaniWeb Sister Site
![]() |
•
•
Join Date: Apr 2009
Posts: 13
Reputation:
Solved Threads: 0
Hello dear people,
I have a bit of a problem, I need to change something and I am not sure how.
I need to change
(see: Codification)
To look like.
[[Codification]]
Of course the word codification can also look like
(see: PrimaryLegislation)
And then it needs to be
[[Primary Legislation]]
Can someone please write this little conversion for me? It is for MediaWiki (obviously)
I can only do the first part I think
/(see:/[[/g
But that is about as far as I get,
I have a bit of a problem, I need to change something and I am not sure how.
I need to change
(see: Codification)
To look like.
[[Codification]]
Of course the word codification can also look like
(see: PrimaryLegislation)
And then it needs to be
[[Primary Legislation]]
Can someone please write this little conversion for me? It is for MediaWiki (obviously)
I can only do the first part I think
/(see:/[[/gBut that is about as far as I get,
Last edited by externalaw; Oct 4th, 2009 at 10:32 am.
•
•
Join Date: Dec 2008
Posts: 69
Reputation:
Solved Threads: 13
Shell Scripting Syntax (Toggle Plain Text)
sed 's/(see: \([^)]*\))/[[\1]]/'
Chris F.A. Johnson
http://cfajohnson.com
http://cfajohnson.com
![]() |
Similar Threads
- Changing string to date help (PHP)
- String and characters (Java)
- find and replace string in a text file (C)
- Changing string (C)
- Creating a ref to a string ? (Python)
- add values to enums or change string (Java)
- Need help debugging program (Java)
- ASP .NET web apps/service in VS.NET won't let me name the project? (ASP.NET)
Other Threads in the Shell Scripting Forum
- Previous Thread: Getting script to run on boot up in linux
- Next Thread: how to recursive search of subdiretories in BASH script
Views: 843 | Replies: 2
| Thread Tools | Search this Thread |
Tag cloud for Shell Scripting





