From 83aae8c248dd4ed65218b2733acdfbc5378e9f46 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EB=A3=A8=EB=B0=80LuMir?= Date: Tue, 5 Nov 2024 18:00:34 +0900 Subject: [PATCH] chore(clang-format-node): add `chmod` command to `package.json`'s `post`, `pre` scripts (#78) --- .github/workflows/test-cross-platform.yml | 3 --- packages/clang-format-node/package.json | 8 +++++--- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/.github/workflows/test-cross-platform.yml b/.github/workflows/test-cross-platform.yml index 4c92631..a801fed 100644 --- a/.github/workflows/test-cross-platform.yml +++ b/.github/workflows/test-cross-platform.yml @@ -49,9 +49,6 @@ jobs: - name: Build run: npm run build - - name: Chmod - run: npx lerna run postinstall - - name: Debug Permission if: runner.os != 'Windows' run: ls -alR packages/clang-format-node/build/bin diff --git a/packages/clang-format-node/package.json b/packages/clang-format-node/package.json index 4029e63..877c19c 100644 --- a/packages/clang-format-node/package.json +++ b/packages/clang-format-node/package.json @@ -41,10 +41,12 @@ "node": ">=16" }, "scripts": { - "postinstall": "find ./build/bin -type f -exec chmod 755 {} + || true", + "postinstall": "npm run chmod", "prepublishOnly": "npm run build", "build": "npx babel src -d build --ignore **/*.test.js && cp -r src/bin build && cp ../../LICENSE ../../README.md .", - "pretest": "find ./src/bin -type f -exec chmod 755 {} + || true", - "test": "node --test" + "postbuild": "npm run chmod", + "pretest": "npm run chmod", + "test": "node --test", + "chmod": "find ./src/bin ./build/bin -type f -exec chmod 755 {} + || true" } }