refactor(config): migrate multi-category files and config.fish to named sites
Adds multi-site `# COMPONENT` headers and converts every guard call site in conf.d/tricks.fish, conf.d/abbr.fish, functions/smart_exit.fish, conf.d/yay-wrapper.fish, conf.d/paru-wrapper.fish, conf.d/wakatime.fish, conf.d/first_run.fish, and config.fish (9 sites across 3 categories) to the self-identifying `(status current-function|basename) <site>` calling convention. Regenerates conf.d/__fish_config_op_registry.fish.
This commit is contained in:
+8
-4
@@ -7,6 +7,10 @@
|
||||
# │ system aliases, and history/backup utilities │
|
||||
# ╰──────────────────────────────────────────────────────────╯
|
||||
|
||||
# COMPONENT
|
||||
# site aliases-tricks: aliases/filesystem
|
||||
# site overrides-tricks: overrides/environment
|
||||
|
||||
## Environment setup
|
||||
# Apply .profile: use this to put fish compatible .profile stuff in
|
||||
if test -f ~/.fish_profile
|
||||
@@ -24,7 +28,7 @@ end
|
||||
|
||||
# Format man pages using bat (only if bat is installed)
|
||||
# Overriding $MANPAGER is opinionated (C3 overrides)
|
||||
if type -q bat; and __fish_config_op_enabled __fish_config_op_overrides
|
||||
if type -q bat; and __fish_config_op_enabled (status basename) overrides-tricks
|
||||
set -gx MANROFFOPT -c
|
||||
set -gx MANPAGER "sh -c 'col -bx | bat -l man -p'"
|
||||
end
|
||||
@@ -37,7 +41,7 @@ set -gx __done_notification_urgency_level low
|
||||
# Functions needed for !! and !$ https://github.com/oh-my-fish/plugin-bang-bang
|
||||
# The bang-bang system is opinionated (C3 overrides) and is gated atomically
|
||||
# here, in conf.d/abbr.fish, conf.d/puffer.fish, and functions/expand_*.fish.
|
||||
if __fish_config_op_enabled __fish_config_op_overrides
|
||||
if __fish_config_op_enabled (status basename) overrides-tricks
|
||||
function __history_previous_command
|
||||
switch (commandline -t)
|
||||
case "!"
|
||||
@@ -83,7 +87,7 @@ end
|
||||
# Fish command history override to show timestamps
|
||||
# Shadowing the history command is opinionated (C1 aliasing); when disabled,
|
||||
# the function is never defined and fish's stock history behavior applies.
|
||||
if __fish_config_op_enabled __fish_config_op_aliases
|
||||
if __fish_config_op_enabled (status basename) aliases-tricks
|
||||
function history
|
||||
builtin history --show-time='%F %T '
|
||||
end
|
||||
@@ -123,7 +127,7 @@ alias .....='cd ../../../..'
|
||||
alias ......='cd ../../../../..'
|
||||
|
||||
# Silent flag injection into POSIX tools is opinionated (C1 aliasing)
|
||||
if __fish_config_op_enabled __fish_config_op_aliases
|
||||
if __fish_config_op_enabled (status basename) aliases-tricks
|
||||
# Tools & Core command color overrides
|
||||
# @category Shell Aliases
|
||||
# @desc dir --color=auto
|
||||
|
||||
Reference in New Issue
Block a user