I'm trying to replace {{ var }} in file and have no idea how to escape curly brackets.
" {{ item.key }} "
of course replaces item.key but ignores {{ }}. Variables to replace in my file look like this:
define ( 'DB_HOST', '{{ DB_HOST }}' );
Part of script:
replace:
dest=env.php.j2
regexp= " {{ item.key }} " << ??????
replace= " {{ item.value }} "
and I need to replace inside of ''. Expected result:
define ( 'DB_HOST', 'hostname' );
Thanks in advance.