fish_delta: fix spurious output in standalone builds

This commit is contained in:
Johannes Altmanninger
2025-10-14 08:40:05 +02:00
parent 40d772fde3
commit f72ebca1e4
2 changed files with 9 additions and 1 deletions

View File

@@ -111,7 +111,7 @@ function fish_delta
for file in $files
set -l bn (path basename -- $file)
set -l def (path filter -rf -- $default_var/$bn)[1]
or set -l def (set -q dir[1] && status get-file $dir/$bn >/dev/null && echo embedded)
or set -l def (set -q dir[1] && status get-file $dir/$bn &>/dev/null && echo embedded)
or begin
if test $all_changed = 0
set -ql _flag_n

View File

@@ -0,0 +1,8 @@
# RUN: %fish %s
fish_delta | grep -A1 '\bfunction __fish_print_help\b'
# CHECK: -function __fish_print_help --description "Print help for the specified fish function or builtin"
# CHECK: - set -l item $argv[1]
# CHECK: --
# CHECK: +function __fish_print_help
# CHECK: + echo Documentation for $argv >&2