Skip to content

Commit

Permalink
[finagle]: Portable shebang
Browse files Browse the repository at this point in the history
Problem:

/bin/bash is not available on non-FHS distros, such as NixOS

Solution:

Replace /bin/bash with /usr/bin/env bash

Result:

Closes #959

Differential Revision: https://phabricator.twitter.biz/D1107565
  • Loading branch information
andreoss authored and jenkins committed Oct 31, 2023
1 parent 83e31f8 commit 7d6a556
Show file tree
Hide file tree
Showing 8 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion doc/src/sphinx/code/client-server-anatomy/sbt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash

sbtver=1.3.10
sbtjar=sbt-launch.jar
Expand Down
2 changes: 1 addition & 1 deletion doc/src/sphinx/code/protocols/sbt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash

sbtver=1.3.10
sbtjar=sbt-launch.jar
Expand Down
2 changes: 1 addition & 1 deletion doc/src/sphinx/code/quickstart/sbt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash

sbtver=1.3.10
sbtjar=sbt-launch.jar
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash

./sbt 'project finagle-benchmark' \
'run-main com.twitter.finagle.loadbalancer.Simulation -dur=60.seconds -bal=rr -qps=1000 -showprogress=false -showsummary=false -coldstart=false' 2>&1 |gawk 'match($0, /BinaryAnnotation\(balancer,([0-9]+).*\)/, a){print a[1]}' > all_good_1000_rr.txt
Expand Down
2 changes: 1 addition & 1 deletion link-netty.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash

if [ $# -ne 1 ]; then
echo 'usage: '$0' nettyjarpath' 1>&2
Expand Down
2 changes: 1 addition & 1 deletion netty-snapshot-env.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash

print_env () {
echo "FINAGLE_USE_NETTY_4_SNAPSHOT=$FINAGLE_USE_NETTY_4_SNAPSHOT"
Expand Down
2 changes: 1 addition & 1 deletion pushsite.bash
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash

set -e

Expand Down
2 changes: 1 addition & 1 deletion sbt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/usr/bin/env bash

set -eo pipefail

Expand Down

0 comments on commit 7d6a556

Please sign in to comment.