33 */
44
55// For CommonJS use:
6- // const { readFile } = require('fs').promises;
7- // const { resolve } = require('path');
6+ const { readFile } = require ( 'fs' ) . promises ;
7+ const { resolve } = require ( 'path' ) ;
88
99// For ES6 modules use:
10- import { readFile } from 'fs/promises' ;
11- import { resolve , dirname } from 'path' ;
12- import { fileURLToPath } from 'url' ;
10+ // import { readFile } from 'fs/promises';
11+ // import { resolve, dirname } from 'path';
12+ // import { fileURLToPath } from 'url';
1313
1414// Get env vars
1515const ref = process . env . GITHUB_REF ;
@@ -106,8 +106,8 @@ async function config() {
106106async function loadTemplates ( ) {
107107 for ( const template of Object . keys ( templates ) ) {
108108 // For ES6 modules use:
109- const fileUrl = import . meta. url ;
110- const __dirname = dirname ( fileURLToPath ( fileUrl ) ) ;
109+ // const fileUrl = import.meta.url;
110+ // const __dirname = dirname(fileURLToPath(fileUrl));
111111
112112 const filePath = resolve ( __dirname , resourcePath , templates [ template ] . file ) ;
113113 const text = await readFile ( filePath , 'utf-8' ) ;
@@ -117,12 +117,12 @@ async function loadTemplates() {
117117
118118function getReleaseComment ( ) {
119119 const url = repositoryUrl + '/releases/tag/${nextRelease.gitTag}' ;
120- const comment = '🎉 This change has been released in version [${nextRelease.version}](' + url + ')' ;
120+ let comment = '🎉 This change has been released in version [${nextRelease.version}](' + url + ')' ;
121121 return comment ;
122122}
123123
124124// For CommonJS use:
125- // module.exports = config();
125+ module . exports = config ( ) ;
126126
127127// For ES6 modules use:
128- export default config ( ) ;
128+ // export default config();
0 commit comments