File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -26,29 +26,14 @@ module.exports = {
2626 results . forEach ( result => {
2727 let artifactPath = result . artifacts [ 0 ] ;
2828
29-
30- // list all files in the directory
31- fs . readdir ( artifactPath , ( err , files ) => {
32- if ( err ) {
33- throw err ;
34- }
35-
36- console . log ( "Now listing contents of artifact path" ) ;
37- // files object contains all files names
38- // log them on console
39- files . forEach ( file => {
40- console . log ( file ) ;
41- } ) ;
42- } ) ;
43-
4429 console . log ( `Artifact for ${ result . arch } /${ result . platform } packaged to: ${ artifactPath } ` ) ;
4530 if ( artifactPath . includes ( "squirrel.windows" ) ) {
46- artifactPath = artifactPath + path . sep + "github-pr-tool. exe" ;
31+ artifactPath = artifactPath . replace ( "RELEASES" , "github-pr-tool-1.0.0 Setup. exe" ) ;
4732 }
4833 const pathParts = artifactPath . split ( "." ) ;
4934 const extension = pathParts [ pathParts . length - 1 ] ;
5035 const newPath = `out${ path . sep } github-pr-tool-${ result . arch } -${ result . platform } .${ extension } ` ;
51- fs . copyFile ( result . artifacts [ 0 ] , newPath , ( err ) => {
36+ fs . copyFile ( artifactPath , newPath , ( err ) => {
5237 if ( err ) {
5338 throw err ;
5439 }
You can’t perform that action at this time.
0 commit comments