Get the directory of the script that is running


Because relative paths break if you start the script from a different directory

THIS_SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"

source

Tags:  bash

Share: