Skip to content

Commit

Permalink
ci: upgrade yarn for monorepo
Browse files Browse the repository at this point in the history
  • Loading branch information
nikitabelonogov committed Dec 20, 2023
1 parent eaff2a6 commit 082c365
Showing 1 changed file with 15 additions and 10 deletions.
25 changes: 15 additions & 10 deletions .github/workflows/frontend-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,22 @@ jobs:
with:
node-version: "${{ env.NODE }}"

- name: "Monorepo: Check"
id: monorepo-check
run: |
if [ -e '${{ env.FRONTEND_MONOREPO_DIR }}/package.json' ]; then
echo "monorepo_path=${{ env.FRONTEND_MONOREPO_DIR }}" >> $GITHUB_OUTPUT
else
echo "old_path=${{ env.FRONTEND_OLD_DIR }}" >> $GITHUB_OUTPUT
echo "::warning::Frontend Monorepo not found"
fi
- name: Upgrade Yarn
if: steps.monorepo-check.outputs.monorepo_path
run: npm install -g [email protected]

- name: Upgrade Yarn
if: steps.monorepo-check.outputs.old_path
run: npm install -g [email protected]

- name: Get yarn cache directory path
Expand All @@ -60,16 +75,6 @@ jobs:
- name: Print Yarn cache size
run: du -d 0 -h ${{ steps.yarn-cache-dir-path.outputs.dir }}

- name: "Monorepo: Check"
id: monorepo-check
run: |
if [ -e '${{ env.FRONTEND_MONOREPO_DIR }}/package.json' ]; then
echo "monorepo_path=${{ env.FRONTEND_MONOREPO_DIR }}" >> $GITHUB_OUTPUT
else
echo "old_path=${{ env.FRONTEND_OLD_DIR }}" >> $GITHUB_OUTPUT
echo "::warning::Frontend Monorepo not found"
fi
- name: Build
if: steps.monorepo-check.outputs.old_path
run: |
Expand Down

0 comments on commit 082c365

Please sign in to comment.