Appacker icon indicating copy to clipboard operation
Appacker copied to clipboard

Terminal staying open while program is open

Open soshimee opened this issue 3 years ago • 9 comments

I don't know why it's happening

soshimee avatar Feb 03 '22 13:02 soshimee

What program did you package? Maybe it's the terminal of the packaged application.
Is there any text in the terminal?

SerGreen avatar Feb 03 '22 16:02 SerGreen

No text, if I close the terminal app stays running, no text can be inputted into the terminal either. Original app does not open terminal and iexpress can make app packed without terminal.

soshimee avatar Feb 04 '22 10:02 soshimee

Also most antivirus softwares don't flag the self-extracting package made with iexpress, how can that be?

soshimee avatar Feb 04 '22 10:02 soshimee

I don't know how IExpress does its packaging but i suppose it doesn't do any weird hacks and that's why antiviruses don't get suspicious.

And back to the topic: what is the name of the original application? What is the name of the terminal window that you see? When you package a different app, does it have a visible terminal too?

The terminal that Appacker creates should hide itself immediately and shouldn't stay visible and its name should be the same as the name of the package file (visible in Task Manager). If what you see is in fact the terminal of the Appacker then i don't understand why it doesn't hide itself for you. Maybe some Windows setting prohibits creation of hidden windows?

SerGreen avatar Feb 04 '22 17:02 SerGreen

Would using Windows Terminal as default terminal matter?

soshimee avatar Feb 05 '22 05:02 soshimee

Does the window that opens is a Windows Terminal window or a Command Prompt window?

I want to say it shouldn't matter because it's Windows OS who should be responsible for hiding program's window, it shouldn't matter what window it is, but i'm not sure, maybe it does matter, maybe Windows Terminal cannot be hidden.

You can try making Command Prompt the default terminal and see if this changes anything.

SerGreen avatar Feb 05 '22 06:02 SerGreen

In my case, when I clicked the packed exe, a Command Prompt window showed immediately the disappeared, when I closed the software, the same thing happened again, this is not the behavior of my software but of Appacker, so please suppress Command Prompt windows from showing in these scenarios.

A demo video: https://user-images.githubusercontent.com/5896180/162564820-f3c8da9d-1930-477c-a7a0-76f65f7f0e23.mp4

redstoneleo avatar Apr 09 '22 09:04 redstoneleo

That's expected behaviour in your demo video, @redstoneleo. Command Prompt that is briefly visible is the Appacker itself, it sits in background and waits for the main application to finish. It hides its own window as soon as possible, but there's still a short period of time you can see it.

But there may be a way to make it completely invisible, so maybe in future there will be an option for that.

SerGreen avatar Apr 10 '22 09:04 SerGreen

Thanks for the reply! @SerGreen

But there may be a way to make it completely invisible, so maybe in future there will be an option for that.

Yes, there indeed exists a method to totally hide the Command Prompt - I said so based on my Python programming experience, unfortunately I have no experience with C#. For a better user experience, I strongly advise hiding them.

redstoneleo avatar Apr 10 '22 13:04 redstoneleo