ci: Prevent fish from creating tempfiles

This commit is contained in:
Ethan P 2021-03-30 20:11:23 -07:00
parent fa311d5119
commit 0cefe6efe1
No known key found for this signature in database
GPG Key ID: 6963FD04F6CF35EA
2 changed files with 16 additions and 3 deletions

5
.gitignore vendored
View File

@ -8,9 +8,8 @@
# Project
/.circleci/.config.yml
.download
bin
man
/bin
/man
# Side-Effects
/test/data/.config/fish

14
test/shimexec/fish Executable file
View File

@ -0,0 +1,14 @@
#!/usr/bin/env bash
# Find the real fish.
HERE="$(cd "$(dirname "$0")" && pwd)"
while read -d ':' -r dir; do
if [[ "$dir" == "$HERE" || -z "$dir" ]]; then continue; fi
if [[ -f "${dir}/fish" ]]; then
TMPDIR= "${dir}/fish" "$@"
exit $?
fi
done <<<"$PATH:"
# Print error and exit.
echo "fish was not found on \$PATH" 1>&2
exit 127