19 Feb
2016
19 Feb
'16
8:26 p.m.
On 19 Feb 2016, at 21:19, Pierre Pronchery <khorben@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