#1030·watchexec

Command killed by Custom(4)

Author: injustCreated Mar 3, 2026Updated Apr 9, 2026
Labelsbug

I use this script to sync a Git repo to a remote:

fish
#! /usr/bin/env fish

set -l repo_root (git rev-parse --show-toplevel); or exit

if not set -q argv[1]
    echo 'Usage: git watch-sync [user@]<host> [dest]' >&2
    exit 2
end
set -l remote $argv[1]

set -l dest $argv[2]
if not set -q argv[2]
    set dest "~/code/$(basename $repo_root)/"
end

watchexec --interactive --exit-on-error --on-busy-update=queue --clear -- \
    git ls-files -z --cached --others --exclude-standard --full-name \| \
    rsync -avz --mkpath --ignore-missing-args --files-from=- --from0 (string escape -- $repo_root $remote:$dest | string join ' ')

Every now and then, watchexec fails with:

Command killed by Custom(4)

I don't have a logfile yet, but I've updated my script to capture it.


watchexec 2.5.0 (2026-02-25) +pid1 OS: macOS Sequoia 15.7.4 Shell: fish 4.5.0