This is a @o/elecron-sudo's python port.
Run a subprocess with administrative privileges, prompting the user with a graphical OS dialog if necessary.
-
Windows
, uses elevate utility with nativeUser Account Control (UAC)
prompt (noPowerShell
required) -
OS X
, uses bundled applet (inspired by Joran Dirk Greef) -
Linux
, uses systempkexec
or gksudo (system or bundled).
If you don't trust binaries bundled in pip
package you can manually build tools and use them instead.
Clone the project:
git clone https://github.com/qlrd/pysudoer.git
Install poetry:
pipx install poetry
Enter in pysudoer
folder:
cd pysudoer
Install dependencies:
poetry install
Before commit some changes, we recommend to follow a three step:
- Text formatting:
poetry run poe format
- Code linting:
poetry run poe lint
- Test:
poetry run poe test
To build .tar.gz
and .whl
files:
poetry build