howmuch515 icon

color_log.py

howmuch515 | PRO | 10/23/18 12:29:42 AM UTC | 0 ⭐ | 256 👁️ | Never ⏰ | []
Python |

470 B

|

None

|

0 👍

/

0 👎

#!/usr/bin/env python3
#-*- coding:utf-8 -*-
 
def info(message):
    print("\033[0;34m[+] " + message + "\033[0;39m")
    
def warning(message):
    print("\033[0;33m[-] " + message + "\033[0;39m")
 
def result(message):
    print("\033[0;32m[*] " + message + "\033[0;39m")
 
def error(message):
    print("\033[0;31m[!] " + message + "\033[0;39m")
    
 
if __name__=='__main__':
    info("info!")
    warning("warning!")
    result("result!")
    error("error!")

Comments