On 19 Feb 2016, at 21:19, Pierre Pronchery
<khorben(a)defora.org> wrote:
This works for me:
$ REGEXP='s/\[\[Image(\([^,]*\), *\([0-9]*\)px)\]\]/{{thumbnail(\1,
size=\2)}}/'
$ echo '[[Image(motorola_filter_replacement_step_1_low.jpg, 250px)]]' |
sed -e "$REGEXP"
{{thumbnail(motorola_filter_replacement_step_1_low.jpg, size=250)}}
great. could you try to make it work with irb and 'string'.gsub(/regexp/,
'replacement') too?
thanks!
holger