File tree Expand file tree Collapse file tree 2 files changed +15
-9
lines changed Expand file tree Collapse file tree 2 files changed +15
-9
lines changed Original file line number Diff line number Diff line change @@ -19,7 +19,19 @@ inputs:
1919outputs :
2020 result :
2121 description : ' JSON array of parsed changelog entries'
22+ value : ${{ steps.changelog-extractor.outputs.result }}
23+
24+ # runs:
25+ # using: 'node24'
26+ # main: 'src/index.js'
2227
2328runs :
24- using : ' node24'
25- main : ' src/index.js'
29+ using : ' composite'
30+ steps :
31+ - name : Get WordPress Versions
32+ id : changelog-extractor
33+ uses : actions/github-script@v7
34+ with :
35+ script : |
36+ const run = require('${{github.action_path}}/src/index.js');
37+ await run(core);
Original file line number Diff line number Diff line change 1- const core = require ( '@actions/core' ) ;
21const fs = require ( 'fs' ) ;
32const path = require ( 'path' ) ;
43const { parseChangelog } = require ( './parser' ) ;
54
65/**
76 * Main action entry point
87 */
9- async function run ( ) {
8+ async function run ( core ) {
109 try {
1110 // Get inputs
1211 const changelogPath = core . getInput ( 'changelog-path' ) || 'CHANGELOG.md' ;
@@ -42,9 +41,4 @@ async function run() {
4241 }
4342}
4443
45- // Only run if this is the main module
46- if ( require . main === module ) {
47- run ( ) ;
48- }
49-
5044module . exports = { run } ;
You can’t perform that action at this time.
0 commit comments