mirror of
https://github.com/Cian-H/dotfiles.git
synced 2026-01-06 00:51:57 +00:00
This change allows the dotfiles to work with chezmoi (e.g: on windows) and improves grepability with neovim/telescope
37 lines
557 B
Nu
37 lines
557 B
Nu
# Note: this requires the latest 0.32.1 or later
|
|
#
|
|
# usage:
|
|
# > source lisp_mode.nu
|
|
# > (echo (+ 1 (* 3 2)))
|
|
|
|
def "+" [x, y] { $x + $y }
|
|
|
|
def "-" [x, y] { $x - $y }
|
|
|
|
def "*" [x, y] { $x * $y }
|
|
|
|
def "/" [x, y] { $x / $y }
|
|
|
|
def in [x, y] { $x in $y }
|
|
|
|
def not-in [x, y] { $x not-in $y}
|
|
|
|
def "<" [x, y] { $x < $y }
|
|
|
|
def "<=" [x, y] { $x <= $y }
|
|
|
|
def ">" [x, y] { $x > $y }
|
|
|
|
def ">=" [x, y] { $x >= $y }
|
|
|
|
def "==" [x, y] { $x == $y }
|
|
|
|
def "!=" [x, y] { $x != $y }
|
|
|
|
def "=~" [x, y] { $x =~ $y }
|
|
|
|
def "!~" [x, y] { $x !~ $y }
|
|
|
|
def array [...rest] { echo $rest }
|
|
|