Variables within sed

Sprache ändern:

If you want to use a variable within sed you can not use the usual way ($var) to do so. There are some easy formatting needed to make sed understanding that $var is a variable.

So if you want to perform something like ‘s/$var/$foo/g’ the string should look this way to work:

This is how variables can be used with sed icon wink Variables within sed

Leave a Reply

Connect with:

Your email address will not be published.


5 + = 7

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">