newspack-scripts 5.9.4 → 5.9.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -34,6 +34,15 @@ jobs:
34
34
  node-version-file: '.nvmrc'
35
35
  cache: 'npm'
36
36
 
37
+ - name: Verify Node version
38
+ run: node --version
39
+
40
+ - name: Setup PHP
41
+ uses: shivammathur/setup-php@v2
42
+ with:
43
+ php-version: '8.3'
44
+ tools: composer
45
+
37
46
  - name: Install PHP packages
38
47
  run: composer install --no-dev --no-scripts
39
48
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "newspack-scripts",
3
- "version": "5.9.4",
3
+ "version": "5.9.6",
4
4
  "description": "",
5
5
  "bin": {
6
6
  "newspack-scripts": "./bin/newspack-scripts.js"
@@ -11,7 +11,11 @@ SVN_PLUGINS_URL="https://plugins.svn.wordpress.org"
11
11
  SVN_REPO_LOCAL_PATH="release/svn"
12
12
  SVN_REPO_URL="$SVN_PLUGINS_URL/$WP_ORG_PLUGIN_NAME"
13
13
 
14
- LATEST_GIT_TAG=$(git describe --tags `git rev-list --tags --max-count=1`)
14
+ LATEST_GIT_TAG=$(git tag --list 'v*' --sort=-v:refname | grep -E '^v[0-9]+\.[0-9]+\.[0-9]+$' | head -n 1)
15
+ if [ -z "$LATEST_GIT_TAG" ]; then
16
+ echo "No stable version tag found. Aborting deployment."
17
+ exit 1
18
+ fi
15
19
  # Remove the "v" at the beginning of the git tag
16
20
  LATEST_SVN_TAG=${LATEST_GIT_TAG:1}
17
21