Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Create executable that uses admin rights with Pyinstaller

I need to create an executable for windows 8.1 and lower, so I tried Py2Exe (no success) and then PyInstaller, and damn it, it worked. Now I need to run it as admin (everytime since that uses admin tasks). My actual compiling script looks like this : python pyinstaller.py --onefile --noconsole --icon=C:\Python27\my_distrib\ico_name --name=app_name C:\Python27\my_distrib\script.py Is there an option to use UAC or things like this ? (its mess to me)

Also, everytime I start it on my laptop windows 8.1 (my desktop computer is windows 7) it says that is dangerous... Anything to make it a "trust" exe? Thanks in advance

like image 993
Maxim Avatar asked Mar 07 '15 23:03

Maxim


1 Answers

PyInstaller 3.0 includes the --uac-admin option!

like image 170
cdonts Avatar answered Oct 19 '22 21:10

cdonts