forked from baron/baron-sso
fix(ci): update github actions to properly support pnpm workspace
This commit is contained in:
@@ -57,11 +57,6 @@ jobs:
|
|||||||
uses: actions/setup-node@v4
|
uses: actions/setup-node@v4
|
||||||
with:
|
with:
|
||||||
node-version: "24"
|
node-version: "24"
|
||||||
cache: "npm"
|
|
||||||
cache-dependency-path: |
|
|
||||||
adminfront/package-lock.json
|
|
||||||
devfront/package-lock.json
|
|
||||||
orgfront/package-lock.json
|
|
||||||
|
|
||||||
- name: i18n resource check
|
- name: i18n resource check
|
||||||
run: |
|
run: |
|
||||||
@@ -91,7 +86,8 @@ jobs:
|
|||||||
- name: Install adminfront dependencies
|
- name: Install adminfront dependencies
|
||||||
run: |
|
run: |
|
||||||
cd adminfront
|
cd adminfront
|
||||||
npm ci
|
npm install -g pnpm
|
||||||
|
pnpm install -C ../common
|
||||||
|
|
||||||
- name: Biome check adminfront (lint + format)
|
- name: Biome check adminfront (lint + format)
|
||||||
run: |
|
run: |
|
||||||
@@ -102,7 +98,8 @@ jobs:
|
|||||||
- name: Install devfront dependencies
|
- name: Install devfront dependencies
|
||||||
run: |
|
run: |
|
||||||
cd devfront
|
cd devfront
|
||||||
npm ci
|
npm install -g pnpm
|
||||||
|
pnpm install -C ../common
|
||||||
|
|
||||||
- name: Biome check devfront (lint + format)
|
- name: Biome check devfront (lint + format)
|
||||||
run: |
|
run: |
|
||||||
@@ -113,7 +110,8 @@ jobs:
|
|||||||
- name: Install orgfront dependencies
|
- name: Install orgfront dependencies
|
||||||
run: |
|
run: |
|
||||||
cd orgfront
|
cd orgfront
|
||||||
npm ci
|
npm install -g pnpm
|
||||||
|
pnpm install -C ../common
|
||||||
|
|
||||||
- name: Biome check orgfront (lint + format)
|
- name: Biome check orgfront (lint + format)
|
||||||
run: |
|
run: |
|
||||||
@@ -561,8 +559,6 @@ jobs:
|
|||||||
uses: actions/setup-node@v4
|
uses: actions/setup-node@v4
|
||||||
with:
|
with:
|
||||||
node-version: "24"
|
node-version: "24"
|
||||||
cache: "npm"
|
|
||||||
cache-dependency-path: adminfront/package-lock.json
|
|
||||||
|
|
||||||
- name: Get Playwright version
|
- name: Get Playwright version
|
||||||
id: playwright-version
|
id: playwright-version
|
||||||
@@ -656,8 +652,6 @@ jobs:
|
|||||||
uses: actions/setup-node@v4
|
uses: actions/setup-node@v4
|
||||||
with:
|
with:
|
||||||
node-version: "24"
|
node-version: "24"
|
||||||
cache: "npm"
|
|
||||||
cache-dependency-path: devfront/package-lock.json
|
|
||||||
|
|
||||||
- name: Get Playwright version
|
- name: Get Playwright version
|
||||||
id: playwright-version
|
id: playwright-version
|
||||||
@@ -679,7 +673,8 @@ jobs:
|
|||||||
mkdir -p reports
|
mkdir -p reports
|
||||||
set +e
|
set +e
|
||||||
cd devfront
|
cd devfront
|
||||||
npm ci 2>&1 | tee ../reports/devfront-install.log
|
npm install -g pnpm
|
||||||
|
pnpm install -C ../common 2>&1 | tee ../reports/devfront-install.log
|
||||||
install_exit_code=${PIPESTATUS[0]}
|
install_exit_code=${PIPESTATUS[0]}
|
||||||
cd ..
|
cd ..
|
||||||
set -e
|
set -e
|
||||||
@@ -839,8 +834,6 @@ jobs:
|
|||||||
uses: actions/setup-node@v4
|
uses: actions/setup-node@v4
|
||||||
with:
|
with:
|
||||||
node-version: "24"
|
node-version: "24"
|
||||||
cache: "npm"
|
|
||||||
cache-dependency-path: orgfront/package-lock.json
|
|
||||||
|
|
||||||
- name: Get Playwright version
|
- name: Get Playwright version
|
||||||
id: playwright-version
|
id: playwright-version
|
||||||
@@ -862,7 +855,8 @@ jobs:
|
|||||||
mkdir -p reports
|
mkdir -p reports
|
||||||
set +e
|
set +e
|
||||||
cd orgfront
|
cd orgfront
|
||||||
npm ci 2>&1 | tee ../reports/orgfront-install.log
|
npm install -g pnpm
|
||||||
|
pnpm install -C ../common 2>&1 | tee ../reports/orgfront-install.log
|
||||||
install_exit_code=${PIPESTATUS[0]}
|
install_exit_code=${PIPESTATUS[0]}
|
||||||
cd ..
|
cd ..
|
||||||
set -e
|
set -e
|
||||||
|
|||||||
@@ -61,7 +61,7 @@ ensure_frontend_dependencies() {
|
|||||||
echo "Installing frontend dependencies..."
|
echo "Installing frontend dependencies..."
|
||||||
if [ "$WORKSPACE_DIR" = "/common" ]; then
|
if [ "$WORKSPACE_DIR" = "/common" ]; then
|
||||||
|
|
||||||
(cd /common && rm -rf node_modules .pnpm-store pnpm-lock.yaml pnpm-workspace.yaml && npm install --no-fund --no-audit)
|
(cd /common && rm -rf node_modules .pnpm-store package-lock.json && npm install --no-workspaces --no-fund --no-audit)
|
||||||
else
|
else
|
||||||
npm ci
|
npm ci
|
||||||
fi
|
fi
|
||||||
|
|||||||
@@ -61,7 +61,7 @@ ensure_frontend_dependencies() {
|
|||||||
echo "Installing frontend dependencies..."
|
echo "Installing frontend dependencies..."
|
||||||
if [ "$WORKSPACE_DIR" = "/common" ]; then
|
if [ "$WORKSPACE_DIR" = "/common" ]; then
|
||||||
|
|
||||||
(cd /common && rm -rf node_modules .pnpm-store pnpm-lock.yaml pnpm-workspace.yaml && npm install --no-fund --no-audit)
|
(cd /common && rm -rf node_modules .pnpm-store package-lock.json && npm install --no-workspaces --no-fund --no-audit)
|
||||||
else
|
else
|
||||||
npm ci
|
npm ci
|
||||||
fi
|
fi
|
||||||
|
|||||||
@@ -61,7 +61,7 @@ ensure_frontend_dependencies() {
|
|||||||
echo "Installing frontend dependencies..."
|
echo "Installing frontend dependencies..."
|
||||||
if [ "$WORKSPACE_DIR" = "/common" ]; then
|
if [ "$WORKSPACE_DIR" = "/common" ]; then
|
||||||
|
|
||||||
(cd /common && rm -rf node_modules .pnpm-store pnpm-lock.yaml pnpm-workspace.yaml && npm install --no-fund --no-audit)
|
(cd /common && rm -rf node_modules .pnpm-store package-lock.json && npm install --no-workspaces --no-fund --no-audit)
|
||||||
else
|
else
|
||||||
npm ci
|
npm ci
|
||||||
fi
|
fi
|
||||||
|
|||||||
@@ -133,7 +133,7 @@ fi
|
|||||||
set +e
|
set +e
|
||||||
(
|
(
|
||||||
cd "$tmp_dir/adminfront"
|
cd "$tmp_dir/adminfront"
|
||||||
npm ci --ignore-scripts
|
npm install -g pnpm && pnpm install -C ../common
|
||||||
) 2>&1 | tee reports/adminfront-install.log
|
) 2>&1 | tee reports/adminfront-install.log
|
||||||
install_exit_code=${PIPESTATUS[0]}
|
install_exit_code=${PIPESTATUS[0]}
|
||||||
set -e
|
set -e
|
||||||
@@ -148,7 +148,7 @@ if [ "$install_exit_code" -ne 0 ]; then
|
|||||||
echo "- Exit Code: \`$install_exit_code\`"
|
echo "- Exit Code: \`$install_exit_code\`"
|
||||||
echo
|
echo
|
||||||
echo "## Command"
|
echo "## Command"
|
||||||
echo "\`cd adminfront && npm ci --ignore-scripts\`"
|
echo "\`cd adminfront && npm install -g pnpm && pnpm install -C ../common\`"
|
||||||
echo
|
echo
|
||||||
echo "## Install Log Tail (last 200 lines)"
|
echo "## Install Log Tail (last 200 lines)"
|
||||||
echo '```text'
|
echo '```text'
|
||||||
@@ -215,7 +215,7 @@ if [ "$test_exit_code" -ne 0 ]; then
|
|||||||
echo
|
echo
|
||||||
echo "## Commands"
|
echo "## Commands"
|
||||||
echo "1. \`cd adminfront\`"
|
echo "1. \`cd adminfront\`"
|
||||||
echo "2. \`npm ci --ignore-scripts\`"
|
echo "2. \`npm install -g pnpm && pnpm install -C ../common\`"
|
||||||
echo "3. \`${playwright_install_desc}\`"
|
echo "3. \`${playwright_install_desc}\`"
|
||||||
echo "4. \`node ./node_modules/playwright/cli.js test\`"
|
echo "4. \`node ./node_modules/playwright/cli.js test\`"
|
||||||
echo
|
echo
|
||||||
|
|||||||
Reference in New Issue
Block a user