accumulo-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Christopher Tubbs (JIRA)" <>
Subject [jira] [Commented] (ACCUMULO-2423) Converge Shell scripts on single implementation
Date Fri, 28 Feb 2014 19:36:25 GMT


Christopher Tubbs commented on ACCUMULO-2423:

I prefer {code}#! /usr/bin/env bash{code} because bash could be in /bin or /usr/bin, and I
don't think we should care. I think bash is common enough, we don't need to care about using
standard "bashisms", unless it's very new (bash >= 4.0), which may not exist on a Mac (OS
X 10.8.5 has bash 3.2) or another likely supported platform.

Example: bash 3.x doesn't support {code}${x^^}{code} and doesn't properly do (at least on
OS X 10.8.5) {code}x=abc echo ${x}{code} instead requiring something like {code}export x=abc
&& echo ${x}{code}

> Converge Shell scripts on single implementation
> -----------------------------------------------
>                 Key: ACCUMULO-2423
>                 URL:
>             Project: Accumulo
>          Issue Type: Improvement
>    Affects Versions: 1.6.0
>            Reporter: Mike Drob
> Do we want to have a stated dependency on a particular shell? Most of our scripts explicitly
use bash, but some use sh. Most scripts invoke {{#\!/usr/bin/env bash}} but some do {{#\!/bin/bash}}
or other crazy things.
> I don't have a particular preference which way we go, but I'd like to see us standardize
one way or the other.
> If we use {{/bin/sh}}, then we can run everything through the [checkbashisms|]
script (also available for other distros)
> If we go the other way, and switch everything to bash, then we can run them through {{ksh
-n}} for deprecation warnings. I know that's a different shell, but they're still moderately

This message was sent by Atlassian JIRA

View raw message