mirror of
https://github.com/RGBCube/nu_scripts
synced 2025-08-02 07:07:46 +00:00
update type-o for windows (#213)
This commit is contained in:
parent
8e23fe5560
commit
3850edbb50
1 changed files with 1 additions and 1 deletions
|
@ -19,7 +19,7 @@
|
||||||
def home_abbrev [os_name] {
|
def home_abbrev [os_name] {
|
||||||
let is_home_in_path = ($env.PWD | str starts-with $nu.home-path)
|
let is_home_in_path = ($env.PWD | str starts-with $nu.home-path)
|
||||||
if $is_home_in_path {
|
if $is_home_in_path {
|
||||||
if ($os_name == "Windows") {
|
if ($os_name =~ "windows") {
|
||||||
let home = ($nu.home-path | str replace -a '\\' '/')
|
let home = ($nu.home-path | str replace -a '\\' '/')
|
||||||
let pwd = ($env.PWD | str replace -a '\\' '/')
|
let pwd = ($env.PWD | str replace -a '\\' '/')
|
||||||
$pwd | str replace $home '~'
|
$pwd | str replace $home '~'
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue