I want to get the value and line number from the .bash_profile so that I can either delete it or update it if it doesn't match.
Current example from the file is.
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi
export PS1="`whoami`@\h:\${PWD}
\t # "
So I want to know what the value is matching "export PS1...." and replace it. My problem is it is wraps and I'm not sure what regex to use to get the full value and which lines it's on. Any help is appreciated.