home-config/fish/functions/_tide_item_rustc.fish

ebc322922f66f567ec06595026cf26fe3fa28b32 · 195 B · 6 lines raw

1 function _tide_item_rustc
2 if path is $_tide_parent_dirs/Cargo.toml
3 rustc --version | string match -qr "(?<v>[\d.]+)"
4 _tide_print_item rustc $tide_rustc_icon' ' $v
5 end
6 end