From d5e4874833054f1789289c433be292ae3e9bd7d0 Mon Sep 17 00:00:00 2001 From: Thomas Miedema Date: Tue, 23 Sep 2014 08:45:31 -0500 Subject: [PATCH] Change all hashbangs to /usr/bin/env (#9057) Summary: ``` git grep -l '#!' | xargs sed -i 's|#!.*/bin/\([^ ]*\)$|#!/usr/bin/env \1|' ``` and some manual tweaking Test Plan: harbormaster Reviewers: austin Subscribers: hvr, simonmar, ezyang, carter Differential Revision: https://phabricator.haskell.org/D237 GHC Trac Issues: #9057 --- compiler/count_bytes | 2 +- distrib/cross-port | 2 +- testsuite/tests/rename/prog006/Setup.lhs | 2 +- utils/count_lines/count_lines.lprl | 2 +- utils/runghc/runghc.hs | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/compiler/count_bytes b/compiler/count_bytes index bf6240228f..4b8aa37898 100644 --- a/compiler/count_bytes +++ b/compiler/count_bytes @@ -1,4 +1,4 @@ -#! /usr/local/bin/perl +#!/usr/bin/env perl # %DirCount = (); %ModCount = (); diff --git a/distrib/cross-port b/distrib/cross-port index 690e60b16a..7c54604ae6 100644 --- a/distrib/cross-port +++ b/distrib/cross-port @@ -1,4 +1,4 @@ -#! /bin/bash +#!/usr/bin/env bash # This script can be used to generate some unregisterised .hc files # for bootstrapping GHC on a new/unsupported platform. It involves a diff --git a/testsuite/tests/rename/prog006/Setup.lhs b/testsuite/tests/rename/prog006/Setup.lhs index b28a8234f9..a81e9d221b 100644 --- a/testsuite/tests/rename/prog006/Setup.lhs +++ b/testsuite/tests/rename/prog006/Setup.lhs @@ -1,4 +1,4 @@ -#!/usr/bin/runhaskell +#!/usr/bin/env runhaskell > module Main where > import Distribution.Simple > main :: IO () diff --git a/utils/count_lines/count_lines.lprl b/utils/count_lines/count_lines.lprl index 72b441384e..49b11ee0c7 100644 --- a/utils/count_lines/count_lines.lprl +++ b/utils/count_lines/count_lines.lprl @@ -1,4 +1,4 @@ -#! /usr/bin/perl +#!/usr/bin/env perl \begin{code} diff --git a/utils/runghc/runghc.hs b/utils/runghc/runghc.hs index e94c5503c0..42ddb83f25 100644 --- a/utils/runghc/runghc.hs +++ b/utils/runghc/runghc.hs @@ -7,7 +7,7 @@ -- runghc program, for invoking from a #! line in a script. For example: -- -- script.lhs: --- #!/usr/bin/env /usr/bin/runghc +-- #!/usr/bin/env runghc -- > main = putStrLn "hello!" -- -- runghc accepts one flag: -- GitLab