Skip to content

Commit

Permalink
Added warning about using old Windows terminal
Browse files Browse the repository at this point in the history
  • Loading branch information
AcidWeb committed Apr 13, 2024
1 parent dfb46f0 commit bef4abe
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions CurseBreaker.py
Original file line number Diff line number Diff line change
Expand Up @@ -277,11 +277,16 @@ def auto_update(self):
sys.exit(1)

def motd_parser(self):
payload = self.core.http.get('https://cursebreaker.acidweb.dev/motd')
if payload.status_code == 200:
self.console.print(Panel(payload.content.decode('UTF-8'), title=':warning: MOTD :warning:',
border_style='red'))
if detect_legacy_windows():
self.console.print(Panel('The old Windows terminal was detected. Use of the new Windows Terminal is highly '
'recommended. https://aka.ms/terminal', title='WARNING', border_style='red'))
self.console.print('')
else:
payload = self.core.http.get('https://cursebreaker.acidweb.dev/motd')
if payload.status_code == 200:
self.console.print(Panel(payload.content.decode('UTF-8'), title=':warning: MOTD :warning:',
border_style='red'))
self.console.print('')

def handle_exception(self, e, table=True):
if self.table.row_count > 1 and table:
Expand Down

0 comments on commit bef4abe

Please sign in to comment.