Description

Very basic script demonstrating running a script with sudo.

Code

1
2
3
4
5
from tinyscript import *

if __name__ == '__main__':
    initialize(sudo=True)
    logger.success("Do it as sudo !")

Help

1
2
$ python sudo.py -h
usage: python sudo.py [-h] [--help] [-v]

Execution

1
2
3
$ python sudo.py 
[sudo] password for user: 
12:34:56 [SUCCESS] Do it as sudo !