Compare commits

...

5 commits

6 changed files with 24 additions and 8 deletions

View file

@ -4,3 +4,9 @@ def la [path: glob = "."] { ls -a $path | sort-by type }
alias nv = nvim
alias nvide = & neovide "--no-fork"
# "new shell"
alias ns = enter .
# "quit shell"
alias qs = dexit

View file

@ -4,8 +4,11 @@ def --wrapped "git <% new %>" [...rest] {
}
<! end !>
def --wrapped "git a" [p: path, ...rest] {
git add $p ...$rest
}
<!
gitalias("a", "add")
gitalias("c", "commit")
gitalias("ch", "checkout")
gitalias("l", "log")

View file

@ -1,8 +1,14 @@
# See: https://www.nushell.sh/cookbook/external_completers.html#fish-completer
let fish_completer = {|spans|
let completer = {|spans|
fish --command $'complete "--do-complete=($spans | str join " ")"'
| $"value(char tab)description(char newline)" + $in
| from tsv --flexible --no-infer
| each { |comp|
let escaped = $comp.value | str replace --all '"' '\"'
{
value: (if ($escaped | str contains " ") { $'"($escaped)"' } else { $escaped })
description: $comp.description
}
}
}
$env.config = {
@ -15,9 +21,10 @@ $env.config = {
}
completions: {
algorithm: "fuzzy"
external: (if (which fish | is-not-empty) { {
enable: true
completer: $fish_completer
completer: $completer
} } else { {} })
}

View file

@ -93,7 +93,7 @@ cg.opt.fennelCompile = fennel.compileString
-- Evaluate fennel code and JSONify the result. Meant to be used as a post-processor.
cg.opt.fennelToJSON = function(str)
return cg.toJSON(fennel.eval(str))
return cg.fmt.json.serialize(fennel.eval(str))
end
-- Check if the given file exists

View file

@ -2,11 +2,11 @@
"nodes": {
"nixpkgs": {
"locked": {
"lastModified": 1720031269,
"narHash": "sha256-rwz8NJZV+387rnWpTYcXaRNvzUSnnF9aHONoJIYmiUQ=",
"lastModified": 1720768451,
"narHash": "sha256-EYekUHJE2gxeo2pM/zM9Wlqw1Uw2XTJXOSAO79ksc4Y=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "9f4128e00b0ae8ec65918efeba59db998750ead6",
"rev": "7e7c39ea35c5cdd002cd4588b03a3fb9ece6fad9",
"type": "github"
},
"original": {