3 # tg--index-merge-one-file-topmerge -- auto merge a file without touching working tree
4 # Copyright (C) 2017 Kyle J. McKay
8 # TG_INST_CMDDIR => location of tg--index-merge-one-file script
10 [ -n "$TG_INST_CMDDIR" ] ||
case "$0" in */?
*[!/]) TG_INST_CMDDIR
="${0%/*}"; esac
12 [ -n "$TG_INST_CMDDIR" ] && [ -d "$TG_INST_CMDDIR" ] &&
13 [ -f "$TG_INST_CMDDIR/tg--index-merge-one-file" ] &&
14 [ -r "$TG_INST_CMDDIR/tg--index-merge-one-file" ] ||
{
15 echo "fatal: missing tg--index-merge-one-file script" >&2
19 tg_index_mergetop_behavior
="merge"
20 .
"$TG_INST_CMDDIR/tg--index-merge-one-file"