- Download Ngrok first & unzip it & enter its directory
$ chmod +x ngrok
$ cp ngrok /usr/local/bin
- Now try if everything is OK (in a directory where ngrok file doesn't exist). If you see Ngrok help, it means everything is OK.
$ ngrok -help
#! /bin/bash | |
###################################################################### | |
# | |
# This script generates an SSL certficate for local development. To | |
# execute the script, run `bash create-dev-ssl-cert.sh`. Sudo is | |
# needed to save the certificate to your Mac KeyChain. After the cert | |
# is generated, you can use `HTTPS=true yarn start` to run the web | |
# server. | |
# |
$ chmod +x ngrok
$ cp ngrok /usr/local/bin
$ ngrok -help
`pip install pycrypto` | |
from Crypto.Cipher import DES3 | |
from Crypto import Random | |
key = 'Sixteen byte key' | |
iv = Random.new().read(DES3.block_size) #DES3.block_size==8 | |
cipher_encrypt = DES3.new(key, DES3.MODE_OFB, iv) | |
plaintext = 'sona si latine loqueri ' #padded with spaces so than len(plaintext) is multiple of 8 | |
encrypted_text = cipher_encrypt.encrypt(plaintext) |
# | |
# Working with branches | |
# | |
# Get the current branch name (not so useful in itself, but used in | |
# other aliases) | |
branch-name = "!git rev-parse --abbrev-ref HEAD" | |
# Push the current branch to the remote "origin", and set it to track | |
# the upstream branch | |
publish = "!git push -u origin $(git branch-name)" |
Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000