- Generating a short link from a long link.
- Save you cuctom long and short links, then het long link from short
Clone git repository https://github.com/hitnik/url_shortener.git
git clone https://github.com/hitnik/url_shortener.git .
cd url_shortener
python3 -m pip install -r requirements.txt
python main.py -h
To generate short url from long
python main.py <long url> --generate
To save long and short urls
python main.py <long url> --generate --short_url <short url>
To get short url from long url
python main.py <short url>
export FLASK_APP=main
export SECRET_KEY=<your_secret>
flask init-db
flask run --port=80