[+] Use colorama to fix colors on Windows #45
This commit is contained in:
+6
-1
@@ -11,7 +11,7 @@ from typing import Iterable
|
||||
|
||||
from . import termenv, neofetch_util
|
||||
from .color_scale import Scale
|
||||
from .color_util import printc, clear_screen
|
||||
from .color_util import clear_screen
|
||||
from .constants import *
|
||||
from .models import Config
|
||||
from .neofetch_util import *
|
||||
@@ -348,6 +348,11 @@ def run():
|
||||
except ModuleNotFoundError:
|
||||
pass
|
||||
|
||||
# On Windows: Try to fix color rendering if not in git bash
|
||||
if IS_WINDOWS:
|
||||
import colorama
|
||||
colorama.just_fix_windows_console()
|
||||
|
||||
# Create CLI
|
||||
hyfetch = color('&b&lhyfetch&r')
|
||||
parser = argparse.ArgumentParser(description=color(f'{hyfetch} - neofetch with flags <3'))
|
||||
|
||||
Reference in New Issue
Block a user