FreeKB - Bash (Scripting) wildcard character
Bash (Scripting) - wildcard character

Let's say you have a string of data that contains a wildcard character.



If you want to replace the wildcard character with something else in sed, you'll need to first escape the wildcard character in sed.

echo $foo | sed 's|\*|TEST|'


In this example, $foo will be become:


Add a Comment

We will never share your name or email with anyone. Enter your email if you would like to be notified when we respond to your comment.

Please enter c0d42 in the box below so that we can be sure you are a human.


Web design by yours truely - me, myself, and I   |   |