@wise/wds-codemods 0.0.1-experimental-e47d8df → 0.0.1-experimental-c53225c

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.
@@ -64,6 +64,7 @@ jobs:
64
64
  shell: bash
65
65
 
66
66
  - name: Publish snapshot release on npm
67
+ id: publish-experimental
67
68
  run: |
68
69
  # Get current version from package.json
69
70
  CURRENT_VERSION=$(node -p "require('./package.json').version")
@@ -72,12 +73,33 @@ jobs:
72
73
  # Update package.json version directly
73
74
  npm version $EXPERIMENTAL_VERSION --no-git-tag-version
74
75
 
75
- # Publish the experimental version
76
- npm publish --tag experimental
76
+ # Publish the experimental version and capture output
77
+ PUBLISH_OUTPUT=$(npm publish --tag experimental 2>&1)
78
+ echo "$PUBLISH_OUTPUT"
79
+
80
+ # Extract the published package name and version from npm output
81
+ PUBLISHED_PACKAGE=$(echo "$PUBLISH_OUTPUT" | grep -o '@wise/wds-codemods@[^[:space:]]*' | head -1)
82
+ echo "published_package=$PUBLISHED_PACKAGE" >> $GITHUB_OUTPUT
77
83
  env:
78
84
  GITHUB_TOKEN: ${{ secrets.GH_ACCESS_TOKEN }}
79
85
  NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN_AUTOMATION }}
80
86
 
87
+ - name: Comment on PR with experimental build
88
+ uses: actions/github-script@v7
89
+ with:
90
+ github-token: ${{ secrets.GH_ACCESS_TOKEN }}
91
+ script: |
92
+ const publishedPackage = '${{ steps.publish-experimental.outputs.published_package }}';
93
+
94
+ const body = `<img width="40" src="https://github.com/user-attachments/assets/78dbfe3a-08af-49d2-9783-c60ae7c493fe" align="left" /> **Experimental build created:** <br /> \`${publishedPackage}\``;
95
+
96
+ github.rest.issues.createComment({
97
+ issue_number: context.issue.number,
98
+ owner: context.repo.owner,
99
+ repo: context.repo.repo,
100
+ body: body
101
+ });
102
+
81
103
  publish:
82
104
  name: 🚀 Publish stable packages
83
105
  if: ${{ github.ref == 'refs/heads/main' }}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wise/wds-codemods",
3
- "version": "0.0.1-experimental-e47d8df",
3
+ "version": "0.0.1-experimental-c53225c",
4
4
  "license": "UNLICENSED",
5
5
  "author": "Wise Payments Ltd.",
6
6
  "type": "module",