I am writing a small Bash script to do some automatic commands. In particular, I would like to save the current directory path in a variable called my pwd and then use mypwd to change directory.
I have tried the following lines with no success:
mypwd=${PWD}
cd mypwd/other/
cd $mypwd/other/
How can I perform this operation in Bash?