This commit is contained in:
@@ -16,40 +16,40 @@ jobs:
|
|||||||
# --------------------------------
|
# --------------------------------
|
||||||
# OPTIONAL: Setup PHP & Composer
|
# OPTIONAL: Setup PHP & Composer
|
||||||
# --------------------------------
|
# --------------------------------
|
||||||
- name: Setup PHP
|
# - name: Setup PHP
|
||||||
uses: shivammathur/setup-php@v2
|
# uses: shivammathur/setup-php@v2
|
||||||
with:
|
# with:
|
||||||
php-version: '7.4'
|
# php-version: '7.4'
|
||||||
tools: composer
|
# tools: composer
|
||||||
# Remove if your plugin does not use Composer.
|
# Remove if your plugin does not use Composer.
|
||||||
|
|
||||||
# --------------------------------
|
# --------------------------------
|
||||||
# OPTIONAL: Setup Node & NPM
|
# OPTIONAL: Setup Node & NPM
|
||||||
# --------------------------------
|
# --------------------------------
|
||||||
- name: Setup Node.js
|
# - name: Setup Node.js
|
||||||
uses: actions/setup-node@v4
|
# uses: actions/setup-node@v4
|
||||||
with:
|
# with:
|
||||||
node-version: '20'
|
# node-version: '20'
|
||||||
cache: 'npm'
|
# cache: 'npm'
|
||||||
# Remove if your plugin does not use NPM.
|
# Remove if your plugin does not use NPM.
|
||||||
|
|
||||||
# --------------------------------
|
# --------------------------------
|
||||||
# OPTIONAL: Install dependencies & build assets
|
# OPTIONAL: Install dependencies & build assets
|
||||||
# --------------------------------
|
# --------------------------------
|
||||||
- name: Install Composer dependencies (production only)
|
# - name: Install Composer dependencies (production only)
|
||||||
run: |
|
# run: |
|
||||||
if [ -f "composer.json" ]; then
|
# if [ -f "composer.json" ]; then
|
||||||
composer install --no-dev --prefer-dist --optimize-autoloader
|
# composer install --no-dev --prefer-dist --optimize-autoloader
|
||||||
fi
|
# fi
|
||||||
|
|
||||||
- name: Install NPM dependencies & build
|
# - name: Install NPM dependencies & build
|
||||||
run: |
|
# run: |
|
||||||
if [ -f "package.json" ]; then
|
# if [ -f "package.json" ]; then
|
||||||
npm ci
|
# npm ci
|
||||||
fi
|
# fi
|
||||||
if [ -f "package.json" ] && grep -q '"build"' package.json; then
|
# if [ -f "package.json" ] && grep -q '"build"' package.json; then
|
||||||
npm run build
|
# npm run build
|
||||||
fi
|
# fi
|
||||||
|
|
||||||
# --------------------------------
|
# --------------------------------
|
||||||
# Extract plugin metadata
|
# Extract plugin metadata
|
||||||
|
|||||||
Reference in New Issue
Block a user