Files
dotfiles/dot_config/nushell/nu_scripts/sourced/nu_101/nothing.nu
Cian Hughes 896af887ca Changed . token to _dot
This change allows the dotfiles to work with chezmoi (e.g: on windows)
and improves grepability with neovim/telescope
2024-11-07 13:52:17 +00:00

25 lines
364 B
Nu

# This checks the -f switch to see if it was supplied
# and tests the new $nothing variable
def nada [
flat?
] {
if $flat == null {
true
} else {
false
}
}
# This shows an alternate way to check for nothing
def nada2 [
flat?
] {
let flat = ($flat | is-empty)
if $flat {
true
} else {
false
}
}