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,

Recommended Answers

All 2 Replies

sed 's/(see: \([^)]*\))/[[\1]]/'

sed 's_(see: Codification)_[[Codification]]_'

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.