elads11
elads11

Reputation: 377

Distributing my TKinter app with pyinstaller doesn't work

I have an app with 2 classes: class called GUI, and a logic class being used by the GUI. The GUI class app is being initiated by this 4 lines at the bottom of the class:

if __name__ == '__main__':
    global g
    g = gui()
    g.start()

But when I try to do the following command on cmd:

pyinstaller --onefile --noconsole --GUI.py

I get the following error:

pyinstaller: error: the following arguments are required: scriptname

What can I do? I want to have the option to deploy the app to users, where they can just click and launch it after downloading a zip file with the project. The project consists of 2 classes aforementioned, and an image.

Upvotes: 2

Views: 194

Answers (1)

user15778183
user15778183

Reputation:

You should be able to just get rid of the two dashes in front of GUI.py, if that is the name of your python file. See here

Upvotes: 2

Related Questions