Created
February 12, 2017 03:44
-
-
Save gabrielfalcao/6543eed09bef204e79e911449d3afd28 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
from __future__ import unicode_literals | |
import os | |
import sys | |
import time | |
from itertools import chain | |
reload(sys) | |
sys.setdefaultencoding('utf-8') | |
braille = map(unichr, range(10240, 10369)) | |
def spin(delay=0.0134): | |
for c in chain(braille, reversed(braille)): | |
print "\033[A\r{}".format(c * 79) | |
time.sleep(delay) | |
try: | |
os.system('tput clear') | |
while True: | |
spin() | |
time.sleep(0.1) | |
except KeyboardInterrupt: | |
print "\r" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment