Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
authorJohannes Sixt <j6t@kdbg.org>2016-11-06 22:31:19 +0300
committerJeff King <peff@peff.net>2016-11-08 23:26:40 +0300
commitec2e8b3da21c884325c9764abc62251fcfbe6208 (patch)
tree622fa9d5adecb81ee819df74ddb8cbde97adeca0 /t
parent038212c4c40c4cd9eb518fb1fbb5eb0d0d7d8f67 (diff)
t0021: compute file size with a single process instead of a pipeline
Avoid unwanted coding patterns (prodigal use of pipelines), and in particular a useless use of cat. Signed-off-by: Johannes Sixt <j6t@kdbg.org> Signed-off-by: Jeff King <peff@peff.net>
Diffstat (limited to 't')
-rwxr-xr-xt/t0021-conversion.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/t/t0021-conversion.sh b/t/t0021-conversion.sh
index db71acacb3..cb72fa49de 100755
--- a/t/t0021-conversion.sh
+++ b/t/t0021-conversion.sh
@@ -22,7 +22,7 @@ generate_random_characters () {
}
file_size () {
- cat "$1" | wc -c | sed "s/^[ ]*//"
+ perl -e 'print -s $ARGV[0]' "$1"
}
filter_git () {