How would I go about using regx to return all characters between two brackets. Here is an example:
foobar[\'infoNeededHere\']ffffd needs to return infoNeededHe
^.*\['(.*)'\].*$ will match a line and capture what you want in a group.
You have to escape the [ and ] with \
[
]
\
The documentation at the rubular.com proof link will explain how the expression is formed.