Skip to content

Commit

Permalink
use more simple method to get module info
Browse files Browse the repository at this point in the history
  • Loading branch information
circlecube committed Dec 14, 2023
1 parent cce739d commit 1580ca8
Showing 1 changed file with 12 additions and 6 deletions.
18 changes: 12 additions & 6 deletions .github/workflows/module-plugin-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -127,18 +127,24 @@ jobs:
working-directory: ./vendor/${{ inputs.module-repo }}
shell: bash
run: |
hasPackageJson=`test -f package.json`
echo "Module has package.json file: $hasPackageJson"
echo "hasPackageJson=$hasPackageJson" >> $GITHUB_OUTPUT
if [[ -f package.json ]]
then
echo "hasPackageJson=true" >> $GITHUB_OUTPUT
else
echo "hasPackageJson=false" >> $GITHUB_OUTPUT
fi
- name: Check Module for build script
id: build
working-directory: ./vendor/${{ inputs.module-repo }}
shell: bash
run: |
hasBuildCommand=`grep -wq '"build":' package.json`
echo "Module has build command: $hasBuildCommand"
echo "hasBuildCommand=$hasBuildCommand" >> $GITHUB_OUTPUT
if grep -wq '"build":' package.json;
then
echo "hasBuildCommand=true" >> $GITHUB_OUTPUT
else
echo "hasBuildCommand=false" >> $GITHUB_OUTPUT
fi
- name: Setup Registry for Module
working-directory: ./vendor/${{ inputs.module-repo }}
Expand Down

0 comments on commit 1580ca8

Please sign in to comment.