From wikipedia, I have a string like the following: Here are [[a variable number of words]] in brackets.
I think I'm being dense, as I can't think of a one-liner I can use to substitute the double square brackets with their contents, while at the same time replacing spaces with underscores within the brackets. In other words, I want to get Here are a_variable_number_of_words in brackets.
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |