Home

scripts @72e04a7fbce762cdfaf109d3226df31e59ea9502 - refs - log -
-
https://git.jolheiser.com/scripts.git
A collection of Nushell scripts
scripts / nu / fg.nu
- raw
1
2
3
4
export def main [args ...string] {
  ^rg --ignore-case --color=always --line-number --no-heading $args
  | ^fzf --ansi --color 'hl:-1:underline,hl+:-1:underline:reverse' --delimiter ':' --preview "bat --color=always {1} --theme='ctp-mocha' --highlight-line {2}" --preview-window 'up,60%,border-bottom,+{2}+3/3,~3' --bind $"enter:become\(($env.EDITOR) +{2} {1}\)"
}