We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents c4a7e2e + 30fb38d commit 7b6ed71Copy full SHA for 7b6ed71
xontrib/powerline2.xsh
@@ -2,7 +2,11 @@ import os
2
from os import path
3
from collections import namedtuple
4
from time import strftime
5
-from xonsh.platform import ptk_shell_type
+try:
6
+ from xonsh.platform import ptk_shell_type
7
+ ptk2 = ptk_shell_type() == 'prompt_toolkit2'
8
+except ImportError:
9
+ ptk2 = True
10
11
12
__all__ = ()
@@ -30,7 +34,7 @@ $PL_DEFAULT_COLORS = {
30
34
"full_rtns": ("WHITE", "RED", "#444"),
31
35
}
32
36
33
-if ptk_shell_type() == 'prompt_toolkit2':
37
+if ptk2:
38
$PTK_STYLE_OVERRIDES['bottom-toolbar'] = 'noreverse'
39
40
modes = {
0 commit comments