shell - Using sed to find a folder directory in a file and replacing with another directory -



shell - Using sed to find a folder directory in a file and replacing with another directory -

so trying utilize simple sed command in shell find , replace string in bash file alias.

the alias like:

alias configure='cd /opt/test/conf/server'

i want replace /opt/test/conf/server /opt/test/conf having difficulties syntax.

thanks help.

cat my_bash_file.sh | sed 's#/opt/test/conf/server#/opt/test/conf#g'

shell sed

Comments

Popular posts from this blog

iphone - Dismissing a UIAlertView -

intellij idea - Update external libraries with intelij and java -

javascript - send data from a new window to previous window in php -