Fix environmental variable check on Windows
This commit is contained in:
parent
c5f7ea8e56
commit
58852ca83c
2 changed files with 6 additions and 2 deletions
5
.xonshrc
5
.xonshrc
|
@ -25,6 +25,9 @@ append_path("~/.local/bin")
|
||||||
append_path("~/bin")
|
append_path("~/bin")
|
||||||
append_path("~/go/bin")
|
append_path("~/go/bin")
|
||||||
|
|
||||||
|
if in_win():
|
||||||
|
append_path("F:/programs/installed/micro")
|
||||||
|
|
||||||
# tmux
|
# tmux
|
||||||
try:
|
try:
|
||||||
requires("tmux")
|
requires("tmux")
|
||||||
|
@ -42,4 +45,4 @@ $LESS_TERMCAP_me = "\033[0m" # end mode
|
||||||
$LESS_TERMCAP_so = "\033[01;44;36m" # begin standout-mode (bottom of screen)
|
$LESS_TERMCAP_so = "\033[01;44;36m" # begin standout-mode (bottom of screen)
|
||||||
$LESS_TERMCAP_se = "\033[0m" # end standout-mode
|
$LESS_TERMCAP_se = "\033[0m" # end standout-mode
|
||||||
|
|
||||||
load_aliases()
|
load_aliases()
|
||||||
|
|
|
@ -12,7 +12,8 @@ def in_wsl() -> bool:
|
||||||
def in_win() -> bool:
|
def in_win() -> bool:
|
||||||
"""Determines if the system is running inside a Windows environment."""
|
"""Determines if the system is running inside a Windows environment."""
|
||||||
|
|
||||||
if ${'OS'} == "Windows_NT":
|
import os
|
||||||
|
if 'OS' in os.environ and os.environ['OS'] == "Windows_NT":
|
||||||
return True
|
return True
|
||||||
return False
|
return False
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue