Skip to content

Commit 7943223

Browse files
committed
update workflows
1 parent 1120533 commit 7943223

File tree

5 files changed

+55
-41
lines changed

5 files changed

+55
-41
lines changed

.github/workflows/manual-release.yml

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,13 @@ jobs:
1616
runs-on: ubuntu-latest
1717

1818
steps:
19-
- name: Checkout code
19+
- name: 🏗 Checkout code
2020
uses: actions/checkout@v4
2121

22-
- name: Setup Release Version
22+
- name: 🔖 Setup Release Version
2323
run: echo "VERSION=${{ github.event.inputs.releaseVersion }}" >> $GITHUB_ENV
2424

25-
- name: Create Release
25+
- name: 📦 Create Release
2626
id: create_release
2727
uses: actions/create-release@v1
2828
env:
@@ -33,21 +33,25 @@ jobs:
3333
draft: true
3434
prerelease: ${{ contains(env.VERSION, '-beta') }}
3535

36-
- name: Build
37-
env:
38-
YARN_ENABLE_IMMUTABLE_INSTALLS: false
36+
- name: 🏗 Setup pnpm
37+
uses: pnpm/action-setup@v4
38+
with:
39+
version: '10.6.5'
40+
41+
- name: 👷 Build
3942
run: |
40-
yarn install
43+
pnpm install
4144
composer prefix-dependencies
4245
composer install --no-dev
43-
yarn build:js
46+
pnpm settings build
47+
pnpm analytics build
4448
45-
- name: Sync to Temporary Directory
49+
- name: 📂 Sync to Temporary Directory
4650
run: |
4751
mkdir temp_dir
4852
rsync -av --prune-empty-dirs --exclude-from='.distignore' ./ temp_dir/
4953
50-
- name: Compress and Upload ZIP
54+
- name: 📦 Compress and Upload ZIP
5155
run: |
5256
cd temp_dir
5357
zip -r ../woocommerce-pos.zip .

.github/workflows/release.yml

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,10 @@ jobs:
1313
runs-on: ubuntu-latest
1414

1515
steps:
16-
- name: Checkout code
16+
- name: 🏗 Checkout code
1717
uses: actions/checkout@v4
1818

19-
- name: Check if version has changed
19+
- name: 🔖 Check if version has changed
2020
id: check_version
2121
run: |
2222
VERSION=$(grep -oP "Version:\s*\K\d+(\.\d+)*(-\w+)?(\.\d+)?" woocommerce-pos.php)
@@ -31,7 +31,7 @@ jobs:
3131
echo "::set-output name=release::true"
3232
fi
3333
34-
- name: Create Release
34+
- name: 📦 Create Release
3535
if: steps.check_version.outputs.release == 'true'
3636
id: create_release
3737
uses: actions/create-release@v1
@@ -43,23 +43,27 @@ jobs:
4343
draft: true
4444
prerelease: ${{ contains(env.VERSION, '-beta') }}
4545

46-
- name: Build
46+
- name: 🏗 Setup pnpm
47+
uses: pnpm/action-setup@v4
48+
with:
49+
version: '10.6.5'
50+
51+
- name: 👷 Build
4752
if: steps.check_version.outputs.release == 'true'
48-
env:
49-
YARN_ENABLE_IMMUTABLE_INSTALLS: false
5053
run: |
51-
yarn install
54+
pnpm install
5255
composer prefix-dependencies
5356
composer install --no-dev
54-
yarn build:js
57+
pnpm settings build
58+
pnpm analytics build
5559
56-
- name: Sync to Temporary Directory
60+
- name: 📂 Sync to Temporary Directory
5761
if: steps.check_version.outputs.release == 'true'
5862
run: |
5963
mkdir temp_dir
6064
rsync -av --prune-empty-dirs --exclude-from='.distignore' ./ temp_dir/
6165
62-
- name: Compress and Upload ZIP
66+
- name: 📦 Compress and Upload ZIP
6367
if: steps.check_version.outputs.release == 'true'
6468
run: |
6569
cd temp_dir

.github/workflows/wp-engine.yml

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -10,19 +10,23 @@ jobs:
1010
runs-on: ubuntu-latest
1111

1212
steps:
13-
- name: Checkout code
14-
uses: actions/checkout@v3
13+
- name: 🏗 Checkout code
14+
uses: actions/checkout@v4
1515

16-
- name: Build
17-
env:
18-
YARN_ENABLE_IMMUTABLE_INSTALLS: false
16+
- name: 🏗 Setup pnpm
17+
uses: pnpm/action-setup@v4
18+
with:
19+
version: '10.6.5'
20+
21+
- name: 👷 Build
1922
run: |
20-
yarn install
23+
pnpm install
2124
composer prefix-dependencies
2225
composer install --no-dev
23-
yarn build:js
26+
pnpm settings build
27+
pnpm analytics build
2428
25-
- name: Deploy to WP Engine
29+
- name: 🚀 Deploy to WP Engine
2630
uses: wpengine/github-action-wpe-site-deploy@v3
2731
with:
2832
WPE_SSHG_KEY_PRIVATE: ${{ secrets.WPE_SSHG_KEY_PRIVATE }}

.github/workflows/wporg-deploy.yml

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -12,19 +12,23 @@ jobs:
1212
runs-on: ubuntu-latest
1313

1414
steps:
15-
- name: Checkout code
15+
- name: 🏗 Checkout code
1616
uses: actions/checkout@v4
1717

18-
- name: Build
19-
env:
20-
YARN_ENABLE_IMMUTABLE_INSTALLS: false
18+
- name: 🏗 Setup pnpm
19+
uses: pnpm/action-setup@v4
20+
with:
21+
version: '10.6.5'
22+
23+
- name: 👷 Build
2124
run: |
22-
yarn install
25+
pnpm install
2326
composer prefix-dependencies
2427
composer install --no-dev
25-
yarn build:js
28+
pnpm settings build
29+
pnpm analytics build
2630
27-
- name: WordPress Plugin Deploy
31+
- name: 📦 WordPress Plugin Deploy
2832
id: deploy
2933
uses: 10up/action-wordpress-plugin-deploy@stable
3034
env:

package.json

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,13 @@
1010
},
1111
"scripts": {
1212
"wp-env": "wp-env",
13-
"start": "wp-env start --xdebug=debug --debug",
14-
"stop": "wp-env stop",
15-
"cli": "wp-env run cli",
16-
"wp": "wp-env run cli wp",
1713
"lint:php": "composer run lint-report | cs2pr",
1814
"test": "pnpm run test:unit:php",
1915
"pretest": "wp-env start --xdebug=coverage && wp-env run cli --env-cwd='wp-content/plugins/woocommerce-pos' composer install",
2016
"test:unit:php": "wp-env run cli -- wp plugin activate woocommerce && wp-env run --env-cwd='wp-content/plugins/woocommerce-pos' tests-cli -- vendor/bin/phpunit -c .phpunit.xml.dist --verbose --log-junit phpunit.xml",
21-
"build:docs": "jsdoc -c hookdoc-conf.json"
17+
"build:docs": "jsdoc -c hookdoc-conf.json",
18+
"settings": "pnpm --filter=@wcpos/settings",
19+
"analytics": "pnpm --filter=@wcpos/analytics"
2220
},
2321
"repository": {
2422
"type": "git",
@@ -43,5 +41,5 @@
4341
"turbo": "2.4.4",
4442
"wp-hookdoc": "0.2.0"
4543
},
46-
"packageManager": "pnpm@10.4.1"
44+
"packageManager": "pnpm@10.6.5"
4745
}

0 commit comments

Comments
 (0)