Closed Automatically At Exporting .exe With pkg
See original GitHub issueI don’t know why, but when I try to export a .exe file with terminal-kit, the .exe file is closed automatically. How do I know what is caused by terminal-kit?, 'cause When I Retire terminal-kit of my code the exported .exe is working perfectly.
If anyone want to see my code, is here, but I repeat, when I retire “require(‘terminal-kit’)” the .exe works. But in terminal with “node index.js” it’s working fine with terminal-kit.
var term = require('terminal-kit').terminal;
var User = require('./user.js');
setInterval(function() {
console.log("timer that keeps nodejs processing running");
}, 1000 * 60 * 60);
console.clear = function(){
var lines = process.stdout.getWindowSize()[1];
for(var i = 0; i < lines; i++) {
console.log('\r\n');
}
}
//STARTS LOADING USER Data
User.Load();
if(User.Data.language == null){
console.clear();
console.log( 'Select Language:\n' ) ;
var items = [
'> English' ,
'> Spanish'
] ;
term.singleColumnMenu( items , function( error , response ) {
term( '\n' ).eraseLineAfter.green(
"#%s selected: %s (%s,%s)\n" ,
response.selectedIndex ,
response.selectedText ,
response.x ,
response.y
) ;
process.exit() ;
} ) ;
}
//========================
Issue Analytics
- State:
- Created 5 years ago
- Comments:14 (7 by maintainers)
Top Results From Across the Web
Pyinstaller's .exe file closes immediately - python
I got it working by dragging the main.exe file to a open command prompt and then pressed enter and it worked, and I...
Read more >Compiling a Node.js Application into an .exe File - Section.io
In this article, we will discuss the reasons for converting an application into a .exe file and finally understand the technical details ...
Read more >Manual Deployment Using Packages for Export
The package installation program automatically detects the computer type and installs the applicable components. Closed Creating or Changing a Package for ...
Read more >Issues When Using auto-py-to-exe - Nitratine
The Terminal Just Opens and Closes But There Are No Errors; 'python'/'pip'/'auto-py-to-exe' is not recognised as an internal or external ...
Read more >How to create an executable (.exe) file from JavaScript code ...
During the compilation process, pkg looks at the require() statements in the code and automatically include these files as static assets.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
This is more than likely the issue.
"pkg": { "assets": "node_modules/terminal-kit/**/*" }
Add this to your package.json and try it again.i’ve same problem. Also added the snippet-code mencioned by @envis10n . I’m getting the follow message :