Start a webserver that hosts the current pwd.
Python2 | Python3 |
---|---|
python -m SimpleHTTPServer 8000 |
python3 -m http.server 8000 |
Start a ftp that hosts the current pwd, allows writing and is protected by a username/password.
Install
pip3 install pyftpdlib
Python2 | Python3 |
---|---|
python -m pyftpdlib -p 21 -w --user=username --password=password |
python3 -m pyftpdlib -p 21 -w --user=username --password=password |
Print a unicode character
Python2 | Python3 |
---|---|
python -c "print unichr(234)" |
python3 -c "print(chr(234))" |
functionname = inspect.stack()[0][3]
functionname = inspect.stack()[1][3]