-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathushort.py
26 lines (22 loc) · 1.68 KB
/
ushort.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
import pyshorteners,os
from pyshorteners import Shortener
os.system("pip install pyshorteners")
os.system("clear")
def banner():
print("""
█ ██ ██▀███ ██▓ ██████ ██░ ██ ▒█████ ██▀███ ▄▄▄█████▓
██ ▓██▒▓██ ▒ ██▒▓██▒ ▒██ ▒ ▓██░ ██▒▒██▒ ██▒▓██ ▒ ██▒▓ ██▒ ▓▒
▓██ ▒██░▓██ ░▄█ ▒▒██░ ░ ▓██▄ ▒██▀▀██░▒██░ ██▒▓██ ░▄█ ▒▒ ▓██░ ▒░
▓▓█ ░██░▒██▀▀█▄ ▒██░ ▒ ██▒░▓█ ░██ ▒██ ██░▒██▀▀█▄ ░ ▓██▓ ░
▒▒█████▓ ░██▓ ▒██▒░██████▒▒██████▒▒░▓█▒░██▓░ ████▓▒░░██▓ ▒██▒ ▒██▒ ░
░▒▓▒ ▒ ▒ ░ ▒▓ ░▒▓░░ ▒░▓ ░▒ ▒▓▒ ▒ ░ ▒ ░░▒░▒░ ▒░▒░▒░ ░ ▒▓ ░▒▓░ ▒ ░░
░░▒░ ░ ░ ░▒ ░ ▒░░ ░ ▒ ░░ ░▒ ░ ░ ▒ ░▒░ ░ ░ ▒ ▒░ ░▒ ░ ▒░ ░
░░░ ░ ░ ░░ ░ ░ ░ ░ ░ ░ ░ ░░ ░░ ░ ░ ▒ ░░ ░ ░
░ ░ ░ ░ ░ ░ ░ ░ ░ ░ ░
\033[30;46mThe Simple URL Shortener is written using Python\033[0m\n""")
banner()
x = Shortener()
url = input("\033[1;36mEnter long URL \033[0m: ")
y = x.tinyurl
z = y.short(url)
print("\033[1;36mConversion results \033[0m:",z)