Skip to content

Commit fe037ee

Browse files
committed
Make sure npm build works.
1 parent 22825c1 commit fe037ee

File tree

2 files changed

+16
-4
lines changed

2 files changed

+16
-4
lines changed

.github/workflows/wp-release.yml

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,22 +9,33 @@ jobs:
99
steps:
1010
- name: Checkout code
1111
uses: actions/checkout@v3
12+
1213
- name: Install Composer dependencies
1314
uses: php-actions/composer@v6
1415
with:
1516
dev: no
1617
php_version: 7.4
1718
php_extensions: bcmath
19+
20+
- name: Install WP-CLI
21+
run: |
22+
curl -O https://raw.githubusercontent.com/wp-cli/builds/gh-pages/phar/wp-cli.phar
23+
chmod +x wp-cli.phar
24+
sudo mv wp-cli.phar /usr/local/bin/wp
25+
1826
- name: Set up Node.js
1927
uses: actions/setup-node@v3
2028
with:
2129
node-version: '16'
22-
- name: Install Node.js dependencies
23-
run: |
24-
npm install
30+
31+
- name: Set Execute Permissions for build_i18n.sh
32+
run: chmod +x bin/build_i18n.sh
33+
2534
- name: Build assets and translation files
2635
run: |
36+
npm install
2737
npm run build
38+
2839
- name: WordPress Plugin Deploy
2940
id: deploy
3041
uses: 10up/action-wordpress-plugin-deploy@stable
@@ -34,6 +45,7 @@ jobs:
3445
SVN_USERNAME: ${{ secrets.SVN_USERNAME }}
3546
SVN_PASSWORD: ${{ secrets.SVN_PASSWORD }}
3647
SLUG: btcpay-greenfield-for-woocommerce
48+
3749
- name: Upload release asset
3850
uses: actions/upload-release-asset@v1
3951
env:

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
"build": "wp-scripts build && npm run i18n:build",
1616
"i18n": "npm run i18n:build",
1717
"i18n:build": "npm run i18n:pot && ./bin/build_i18n.sh",
18-
"i18n:pot": "php -d xdebug.max_nesting_level=512 $(which wp) i18n make-pot --exclude=\"node_modules/,languages/,assets/\" --headers='{\"Report-Msgid-Bugs-To\":\"https://woocommerce.com/my-account/create-a-ticket/\", \"language-team\":\"LANGUAGE <EMAIL@ADDRESS>\"}' . languages/btcpay-greenfield-for-woocommerce.pot",
18+
"i18n:pot": "php -d xdebug.max_nesting_level=512 wp i18n make-pot --exclude=\"node_modules/,languages/,assets/\" --headers='{\"Report-Msgid-Bugs-To\":\"https://woocommerce.com/my-account/create-a-ticket/\", \"language-team\":\"LANGUAGE <EMAIL@ADDRESS>\"}' . languages/btcpay-greenfield-for-woocommerce.pot",
1919
"i18n:json": "$(which wp) i18n make-json languages --no-purge",
2020
"check-engines": "wp-scripts check-engines"
2121
}

0 commit comments

Comments
 (0)