From cb9af4e759e418a602e76016ed6d4703e73fec86 Mon Sep 17 00:00:00 2001 From: Zoe Codez Date: Wed, 25 Sep 2024 10:30:24 -0500 Subject: [PATCH] scripts --- package.json | 2 +- scripts/run.sh | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/package.json b/package.json index e362e2f..10dabd5 100644 --- a/package.json +++ b/package.json @@ -15,7 +15,7 @@ "url": "https://github.com/zoe-codez", "name": "Zoe Codez" }, - "bin": "./scripts/run/sh", + "bin": "./scripts/run.sh", "files": [ "dist/**/*", "scripts/**/*", diff --git a/scripts/run.sh b/scripts/run.sh index 38df73f..b8382aa 100755 --- a/scripts/run.sh +++ b/scripts/run.sh @@ -1,2 +1,6 @@ #!/bin/sh + +FULL_PATH=$(realpath "$0") +FILE_BASE=$(dirname "$FULL_PATH") +cd "$FILE_BASE/.." || exit npx tsx src/main.ts "$1"