From 8685ed8de3205be215fe5768e2ff555ac890c085 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Hegyi=20=C3=81ron=20Ferenc?= Date: Sat, 20 Jan 2024 22:15:25 +0100 Subject: [PATCH] =?UTF-8?q?=F0=9F=9A=A7=20wip:=20test?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/e2e.yml | 10 +++++----- bin/hook.sh | 3 +++ 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/.github/workflows/e2e.yml b/.github/workflows/e2e.yml index 5d19ee6..d61f94e 100644 --- a/.github/workflows/e2e.yml +++ b/.github/workflows/e2e.yml @@ -43,12 +43,12 @@ jobs: - name: Setup eemoji run: node ./bin/eemoji.mjs init -c none - - name: Print .git/COMMIT_EDITMSG - run: cat .git/COMMIT_EDITMSG - - - name: Try eemoji - run: pnpm run dev run -d 4 + - name: Find .git/COMMIT_EDITMSG and print where it is + run: find . -name COMMIT_EDITMSG + - name: Find eemoji.mjs and print where it is + run: find . -name eemoji.mjs + - name: Switch to test branch run: git checkout -b test diff --git a/bin/hook.sh b/bin/hook.sh index 28886c9..d30e5cd 100644 --- a/bin/hook.sh +++ b/bin/hook.sh @@ -1,11 +1,14 @@ #!/bin/sh LOCAL_PATH=$(npm root) NODE_PATH=$(npm root -g) +REPO_ROOT=$(git rev-parse --show-toplevel)/node_modules if [ -f "$LOCAL_PATH/eemoji/bin/eemoji.mjs" ]; then node "$LOCAL_PATH/eemoji/bin/eemoji.mjs" run $1 elif [ -f "$NODE_PATH/eemoji/bin/eemoji.mjs" ]; then node "$NODE_PATH/eemoji/bin/eemoji.mjs" run $1 +elif [ -f "$REPO_ROOT/eemoji/bin/eemoji.mjs" ]; then + node "$REPO_ROOT/eemoji/bin/eemoji.mjs" run $1 else echo "eemoji is not properly installed locally or globally" exit 1