How to create a .exe of a python script

Question:

I’ve been trying to use pyinstaller, but it never creates it. There is always this error:
error

I’ve found that if I put this, it should work, but it doesn’t. Does somebody know how to do it?
.pyinstaller –onefile -w ‘filename.py’

Asked By: gitblanc

||

Answers:

Add Your pyinstaller directory PATH to environment variable.

Answered By: MrShakila

Search for ‘Edit system environment variables’ in control panel and add (C:Users"Your username"AppDataLocalProgramsPythonPython311Scripts) to PATH

Answered By: 2TUF2TAP
Categories: questions Tags:
Answers are sorted by their score. The answer accepted by the question owner as the best is marked with
at the top-right corner.