linux bash script example cd directory Example: bash change to script directory cd "$(dirname "${BASH_SOURCE[0]}")"