Skip to content

Commit

Permalink
add comments describing relative directory change
Browse files Browse the repository at this point in the history
  • Loading branch information
James-Rocker committed Oct 5, 2024
1 parent 4b178d3 commit c9da1d2
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions code/pcgen.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
#!/bin/sh
set -e

# Changing the current directory temporarily to the file location.
# Ensuring the script operates relative to its own location, regardless
# of where it is run from
cd "$(dirname "$0")"

# Most GUIs will change directory to the location of the script
Expand Down

0 comments on commit c9da1d2

Please sign in to comment.