From 5e1180f550d8e988edcaaf8b7f073355528d5a0a Mon Sep 17 00:00:00 2001 From: Filip Rojek Date: Fri, 26 May 2023 12:47:10 +0200 Subject: [PATCH] fix: path --- debrepo | 4 +++- scripts/genPkgRel.sh | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/debrepo b/debrepo index 8aa3fbd..3a1a71c 100755 --- a/debrepo +++ b/debrepo @@ -1,6 +1,8 @@ #!/bin/sh VERSION="0.1.0" -DIR="$(cd "$(dirname "$0")" && pwd)" # location of debrepo source path +#DIR="$(cd "$(dirname "$0")" && pwd)" # location of debrepo source path +SCRIPT_PATH=$(readlink -f "$0") +DIR=$(dirname "$SCRIPT_PATH") # set vars index=1 diff --git a/scripts/genPkgRel.sh b/scripts/genPkgRel.sh index 2e608f8..5e3a416 100755 --- a/scripts/genPkgRel.sh +++ b/scripts/genPkgRel.sh @@ -1,5 +1,7 @@ #!/bin/sh -DIR="$(cd "$(dirname "$0")" && pwd)" +#DIR="$(cd "$(dirname "$0")" && pwd)" +SCRIPT_PATH=$(readlink -f "$0") +DIR=$(dirname "$SCRIPT_PATH") LS="$(which ls)" # this prevents bugs when aliasing ls to tools like exa REPODIR="$1" ARCHS="$($LS -l $REPODIR/apt-repo/dists/stable/main/ | awk '{print $9}' | awk NF | awk -F - '{print $2}')"