qash/library/getdir.sh

4 lines
71 B
Bash

#!/bin/bash
dir=$(cd "$(dirname "${BASH_SOURCE}")" && pwd)
echo "$dir"