t5562: fix perl path
diff mbox series

Message ID 20181122233821.17871-1-max@max630.net
State New
Headers show
Series
  • t5562: fix perl path
Related show

Commit Message

Max Kirillov Nov. 22, 2018, 11:38 p.m. UTC
From: Jeff King <peff@peff.net>

Some systems do not have perl installed to /usr/bin. Use the variable
from the build settiings, and call perl directly than via shebang.

Signed-off-by: Max Kirillov <max@max630.net>
---
Submitting. Could you sign-off? Also removed shebang from the script as it is not needed
 t/t5562-http-backend-content-length.sh | 1 +
 t/t5562/invoke-with-content-length.pl  | 1 -
 2 files changed, 1 insertion(+), 1 deletion(-)
 mode change 100755 => 100644 t/t5562/invoke-with-content-length.pl

Comments

Carlo Arenas Nov. 23, 2018, 2:31 p.m. UTC | #1
Tested-by: Carlo Marcelo Arenas Belón <carenas@gmail.com>

IMHO leaving the shebang might be better if only for consistency but
could go eitherway

Carlo
Jeff King Nov. 24, 2018, 12:10 p.m. UTC | #2
On Fri, Nov 23, 2018 at 01:38:21AM +0200, Max Kirillov wrote:

> From: Jeff King <peff@peff.net>
> 
> Some systems do not have perl installed to /usr/bin. Use the variable
> from the build settiings, and call perl directly than via shebang.
> 
> Signed-off-by: Max Kirillov <max@max630.net>
> ---
> Submitting. Could you sign-off? Also removed shebang from the script as it is not needed

Yep:

  Signed-off-by: Jeff King <peff@peff.net>

As Carlos mentioned, I think you could leave the shebang as
documentation, but I'm OK either way.

-Peff

Patch
diff mbox series

diff --git a/t/t5562-http-backend-content-length.sh b/t/t5562-http-backend-content-length.sh
index b24d8b05a4..90d890d02f 100755
--- a/t/t5562-http-backend-content-length.sh
+++ b/t/t5562-http-backend-content-length.sh
@@ -31,6 +31,7 @@  test_http_env() {
 		PATH_TRANSLATED="$PWD/.git/git-$handler_type-pack" \
 		GIT_HTTP_EXPORT_ALL=TRUE \
 		REQUEST_METHOD=POST \
+		"$PERL_PATH" \
 		"$TEST_DIRECTORY"/t5562/invoke-with-content-length.pl \
 		    "$request_body" git http-backend >act.out 2>act.err
 }
diff --git a/t/t5562/invoke-with-content-length.pl b/t/t5562/invoke-with-content-length.pl
old mode 100755
new mode 100644
index 6c2aae7692..0943474af2
--- a/t/t5562/invoke-with-content-length.pl
+++ b/t/t5562/invoke-with-content-length.pl
@@ -1,4 +1,3 @@ 
-#!/usr/bin/perl
 use 5.008;
 use strict;
 use warnings;