From a5d088500956744c70e7ca2d086fff04d19e5e4d Mon Sep 17 00:00:00 2001 From: "(quasar) nebula" Date: Thu, 16 May 2024 17:06:24 -0300 Subject: zsh: vimhelp function --- .zshrc | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/.zshrc b/.zshrc index c86c535..1de48ad 100644 --- a/.zshrc +++ b/.zshrc @@ -4,6 +4,7 @@ # per-device configuration (pre) # zsh configuration # third party configuration <3rd-conf> +# aliases & non-script functions # per-device configuration (post) @@ -106,6 +107,17 @@ fi export PATH +# //// aliases & non-script functions //////////////////////// // # + +# -- hooks into third-party stuff -- + +if [[ -v DEVICE_HAS_VIM ]]; then + vimhelp() { + vim -c ":h $1 | only" + } +fi + + # //// per-device configuration /////////////////////////////// // # device_postconfig -- cgit 1.3.0-6-gf8a5