I have a pattern like this:
word word one/two/three word
I want to match the groups which is seperated by the /. My thought is as follows:
[\w]+ # match any words
[\w]+/[\w]+ # followed by / and another word
[\w]+[/[\w]+]+ # repeat the latter
But this does not work since it seems as soon as I add ], it does not close the mose inner [ but the most outer [.
How can I work with nested squared brackets?