refactor(config): migrate C4 integrations call sites to self-identifying guard

This commit is contained in:
2026-08-17 21:49:45 -04:00
parent a981fa7f0a
commit 516b2ba26c
8 changed files with 42 additions and 7 deletions
+14
View File
@@ -16,12 +16,15 @@ set -g __fish_config_op_registry_keys \
bash_expands: \ bash_expands: \
cat: \ cat: \
claude: \ claude: \
done: \
du: \ du: \
edit: \ edit: \
fish_right_prompt: \ fish_right_prompt: \
help: \ help: \
hist: \
key_bindings: \ key_bindings: \
less: \ less: \
logs: \
ls: \ ls: \
mkdir: \ mkdir: \
mv: \ mv: \
@@ -29,10 +32,14 @@ set -g __fish_config_op_registry_keys \
puffer: \ puffer: \
rg: \ rg: \
rm: \ rm: \
split: \
spwin: \
ssh: \ ssh: \
starship: \ starship: \
tab: \
theme: \ theme: \
top: \ top: \
upgrade: \
yt-dlp: \ yt-dlp: \
zoxide: zoxide:
@@ -46,12 +53,15 @@ set -g __fish_config_op_registry_values \
"overrides/key-bindings" \ "overrides/key-bindings" \
"aliases/filesystem" \ "aliases/filesystem" \
"aliases/dev-tools" \ "aliases/dev-tools" \
"integrations/notifications" \
"aliases/filesystem" \ "aliases/filesystem" \
"aliases/dev-tools" \ "aliases/dev-tools" \
"overrides/prompt" \ "overrides/prompt" \
"aliases/shell-tools" \ "aliases/shell-tools" \
"integrations/history-logs" \
"overrides/key-bindings" \ "overrides/key-bindings" \
"aliases/shell-tools" \ "aliases/shell-tools" \
"integrations/history-logs" \
"aliases/filesystem" \ "aliases/filesystem" \
"aliases/filesystem" \ "aliases/filesystem" \
"aliases/filesystem" \ "aliases/filesystem" \
@@ -59,10 +69,14 @@ set -g __fish_config_op_registry_values \
"overrides/key-bindings" \ "overrides/key-bindings" \
"aliases/search" \ "aliases/search" \
"aliases/filesystem" \ "aliases/filesystem" \
"integrations/window-mgmt" \
"integrations/window-mgmt" \
"aliases/network" \ "aliases/network" \
"overrides/prompt" \ "overrides/prompt" \
"integrations/window-mgmt" \
"overrides/prompt" \ "overrides/prompt" \
"aliases/monitor" \ "aliases/monitor" \
"integrations/pkg-upgrade" \
"aliases/network" \ "aliases/network" \
"aliases/filesystem" "aliases/filesystem"
+4 -1
View File
@@ -19,6 +19,9 @@
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE. # SOFTWARE.
#
# COMPONENT
# integrations/notifications
if not status is-interactive if not status is-interactive
exit exit
@@ -26,7 +29,7 @@ end
# Local modification: opinionated guard (AGENTS.md Task #3). Desktop # Local modification: opinionated guard (AGENTS.md Task #3). Desktop
# notifications assume a graphical session, classified as C4 integrations. # notifications assume a graphical session, classified as C4 integrations.
__fish_config_op_enabled __fish_config_op_integrations; or exit __fish_config_op_enabled (status basename); or exit
set -g __done_version 1.19.1 set -g __done_version 1.19.1
+4 -1
View File
@@ -4,6 +4,9 @@
# CATEGORY # CATEGORY
# 04-git-and-version-control # 04-git-and-version-control
# #
# COMPONENT
# integrations/history-logs
#
# SYNOPSIS # SYNOPSIS
# hist # hist
# #
@@ -15,7 +18,7 @@
# hist # hist
function hist --description 'Search fish history and put it in the prompt' function hist --description 'Search fish history and put it in the prompt'
# Opinionated guard (C4): integrations disabled # Opinionated guard (C4): integrations disabled
if not __fish_config_op_enabled __fish_config_op_integrations if not __fish_config_op_enabled (status current-function)
set -l c_err (set_color red) set -l c_err (set_color red)
set -l c_reset (set_color normal) set -l c_reset (set_color normal)
echo "$c_err"'hist: disabled by __fish_config_op_integrations'"$c_reset" >&2 echo "$c_err"'hist: disabled by __fish_config_op_integrations'"$c_reset" >&2
+4 -1
View File
@@ -4,6 +4,9 @@
# CATEGORY # CATEGORY
# 11-pager-and-logging # 11-pager-and-logging
# #
# COMPONENT
# integrations/history-logs
#
# SYNOPSIS # SYNOPSIS
# logs [-h] [-c <category>] # logs [-h] [-c <category>]
# #
@@ -35,7 +38,7 @@
# logs -c scrollback # logs -c scrollback
function logs --description 'Browse terminal log files interactively with fzf' function logs --description 'Browse terminal log files interactively with fzf'
# Opinionated guard (C4): integrations disabled # Opinionated guard (C4): integrations disabled
if not __fish_config_op_enabled __fish_config_op_integrations if not __fish_config_op_enabled (status current-function)
set -l c_err (set_color red) set -l c_err (set_color red)
set -l c_reset (set_color normal) set -l c_reset (set_color normal)
echo "$c_err"'logs: disabled by __fish_config_op_integrations'"$c_reset" >&2 echo "$c_err"'logs: disabled by __fish_config_op_integrations'"$c_reset" >&2
+4 -1
View File
@@ -4,6 +4,9 @@
# CATEGORY # CATEGORY
# 08-terminal-management # 08-terminal-management
# #
# COMPONENT
# integrations/window-mgmt
#
# SYNOPSIS # SYNOPSIS
# split [-h | -v] [command...] # split [-h | -v] [command...]
# #
@@ -27,7 +30,7 @@
# split -v nvim README.md # split -v nvim README.md
function split --description 'Run a command in a new terminal split' function split --description 'Run a command in a new terminal split'
# Opinionated guard (C4): integrations disabled # Opinionated guard (C4): integrations disabled
if not __fish_config_op_enabled __fish_config_op_integrations if not __fish_config_op_enabled (status current-function)
set -l c_err (set_color red) set -l c_err (set_color red)
set -l c_reset (set_color normal) set -l c_reset (set_color normal)
echo "$c_err"'split: disabled by __fish_config_op_integrations'"$c_reset" >&2 echo "$c_err"'split: disabled by __fish_config_op_integrations'"$c_reset" >&2
+4 -1
View File
@@ -4,6 +4,9 @@
# CATEGORY # CATEGORY
# 08-terminal-management # 08-terminal-management
# #
# COMPONENT
# integrations/window-mgmt
#
# SYNOPSIS # SYNOPSIS
# spwin [args...] # spwin [args...]
# #
@@ -22,7 +25,7 @@
# spwin # spwin
function spwin --wraps='~/.config/kitty/spawn-window.sh' --description 'spawn window in kitty or wezterm' function spwin --wraps='~/.config/kitty/spawn-window.sh' --description 'spawn window in kitty or wezterm'
# Opinionated guard (C4): integrations disabled # Opinionated guard (C4): integrations disabled
if not __fish_config_op_enabled __fish_config_op_integrations if not __fish_config_op_enabled (status current-function)
set -l c_err (set_color red) set -l c_err (set_color red)
set -l c_reset (set_color normal) set -l c_reset (set_color normal)
echo "$c_err"'spwin: disabled by __fish_config_op_integrations'"$c_reset" >&2 echo "$c_err"'spwin: disabled by __fish_config_op_integrations'"$c_reset" >&2
+4 -1
View File
@@ -4,6 +4,9 @@
# CATEGORY # CATEGORY
# 08-terminal-management # 08-terminal-management
# #
# COMPONENT
# integrations/window-mgmt
#
# SYNOPSIS # SYNOPSIS
# tab [args...] # tab [args...]
# #
@@ -23,7 +26,7 @@
# tab # tab
function tab --description 'Spawn a new tab in the current terminal' function tab --description 'Spawn a new tab in the current terminal'
# Opinionated guard (C4): integrations disabled # Opinionated guard (C4): integrations disabled
if not __fish_config_op_enabled __fish_config_op_integrations if not __fish_config_op_enabled (status current-function)
set -l c_err (set_color red) set -l c_err (set_color red)
set -l c_reset (set_color normal) set -l c_reset (set_color normal)
echo "$c_err"'tab: disabled by __fish_config_op_integrations'"$c_reset" >&2 echo "$c_err"'tab: disabled by __fish_config_op_integrations'"$c_reset" >&2
+4 -1
View File
@@ -4,6 +4,9 @@
# CATEGORY # CATEGORY
# 05-package-management # 05-package-management
# #
# COMPONENT
# integrations/pkg-upgrade
#
# SYNOPSIS # SYNOPSIS
# upgrade # upgrade
# #
@@ -19,7 +22,7 @@
# upgrade # upgrade
function upgrade --description 'Full system upgrade via paru or yay' function upgrade --description 'Full system upgrade via paru or yay'
# Opinionated guard (C4): integrations disabled # Opinionated guard (C4): integrations disabled
if not __fish_config_op_enabled __fish_config_op_integrations if not __fish_config_op_enabled (status current-function)
set -l c_err (set_color red) set -l c_err (set_color red)
set -l c_reset (set_color normal) set -l c_reset (set_color normal)
echo "$c_err"'upgrade: disabled by __fish_config_op_integrations'"$c_reset" >&2 echo "$c_err"'upgrade: disabled by __fish_config_op_integrations'"$c_reset" >&2