Skip to content

Commit 814728e

Browse files
committed
Fixed npmpublish.
1 parent 3552bb5 commit 814728e

File tree

1 file changed

+12
-4
lines changed

1 file changed

+12
-4
lines changed

.github/workflows/npmpublish.yml

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -44,17 +44,25 @@ jobs:
4444
restore-keys: |
4545
${{ runner.os }}-pnpm-store-
4646
-
47-
run: cd ../etherpad-lite/src && ./bin/installDeps.sh
47+
run: cd ../etherpad-lite/src && ./bin/installDeps.sh && pnpm link --global
4848
-
4949
run: |
5050
pnpm config set auto-install-peers false
5151
pnpm i
5252
-
53-
run: pnpm install ep_etherpad-lite@file:../etherpad-lite/src
53+
run: pnpm link --global ep_etherpad-lite
5454
-
5555
run: |
56-
pnpm run test
57-
working-directory: ./node_modules/ep_etherpad-lite
56+
has_testcli_script () {
57+
[[ $(npm run | grep "^ test" | wc -l) > 0 ]]
58+
}
59+
60+
if has_testcli_script; then
61+
pnpm run test
62+
else
63+
npm test
64+
fi
65+
name: Run tests if available
5866
-
5967
run: pnpm run lint
6068

0 commit comments

Comments
 (0)