File tree 2 files changed +20
-13
lines changed
2 files changed +20
-13
lines changed Original file line number Diff line number Diff line change @@ -26,12 +26,25 @@ jobs:
26
26
- name : Build
27
27
run : npm run build
28
28
29
- - name : Verify build artifacts
29
+ - name : List build output
30
30
run : |
31
+ echo "Listing contents of the dist directory:"
31
32
ls -R dist
32
- [ -f dist/cjs/production/index.jsx ] || exit 1
33
- [ -f dist/esm/production/index.jsx ] || exit 1
34
- [ -f dist/types/index.d.ts ] || exit 1
33
+
34
+ - name : Find built files
35
+ id : find_files
36
+ run : |
37
+ CJS_FILE=$(find dist -name "*.cjs.js" -or -name "index.js" -or -name "index.jsx" | grep "/cjs/" | head -n 1)
38
+ ESM_FILE=$(find dist -name "*.esm.js" -or -name "index.js" -or -name "index.jsx" | grep "/esm/" | head -n 1)
39
+ TYPES_FILE=$(find dist -name "index.d.ts" | head -n 1)
40
+
41
+ echo "CJS file: $CJS_FILE"
42
+ echo "ESM file: $ESM_FILE"
43
+ echo "Types file: $TYPES_FILE"
44
+
45
+ echo "cjs_file=$CJS_FILE" >> $GITHUB_OUTPUT
46
+ echo "esm_file=$ESM_FILE" >> $GITHUB_OUTPUT
47
+ echo "types_file=$TYPES_FILE" >> $GITHUB_OUTPUT
35
48
36
49
- name : Publish to npm
37
50
run : npm publish
42
55
uses : softprops/action-gh-release@v1
43
56
with :
44
57
files : |
45
- dist/cjs/production/index.jsx
46
- dist/esm/production/index.jsx
47
- dist/types/index.d.ts
58
+ ${{ steps.find_files.outputs.cjs_file }}
59
+ ${{ steps.find_files.outputs.esm_file }}
60
+ ${{ steps.find_files.outputs.types_file }}
48
61
env :
49
62
GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
Original file line number Diff line number Diff line change @@ -246,9 +246,3 @@ Contributions are welcome! Feel free to open issues or submit pull requests.
246
246
247
247
This project is licensed under the MIT License.
248
248
249
-
250
- ## Releases
251
-
252
- ` npm run release -- --release-as minor ` for a minor version bump
253
- ` npm run release -- --release-as major ` for a major version bump
254
- ` npm run release -- --prerelease ` for a prerelease version
You can’t perform that action at this time.
0 commit comments