Skip to content

Commit f2946d6

Browse files
committed
more comfortable mktemp
1 parent 999f11a commit f2946d6

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

test/init.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ cat << EOS > .pre-commit-config.yaml
1313
- id: shell-lint
1414
EOS
1515

16-
tmpdir=$(mktemp -t pre-commit-shell -d)
16+
tmpdir=$(mktemp -t pre-commit-shell.XXXXXX -d)
1717
cp test/test.sh "$tmpdir"
1818
cp test/.pre-commit-config.yaml "$tmpdir"
1919
pushd "$tmpdir"
@@ -22,7 +22,7 @@ git add .pre-commit-config.yaml; git commit -a -m "init test case"
2222
pre-commit install
2323
pre-commit run
2424
git add . --all
25-
tmpfile=$(mktemp -t pre-commit-shell)
25+
tmpfile=$(mktemp -t pre-commit-shell.XXX)
2626
git commit -a -m "let begin test" &> "$tmpfile"
2727
popd
2828
rm -rf "$tmpdir"

0 commit comments

Comments
 (0)