[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Help-bash] Weird error of bash "/bin/sh: line 1: `BASH_FUNC_f%%': not a
From: |
Peng Yu |
Subject: |
[Help-bash] Weird error of bash "/bin/sh: line 1: `BASH_FUNC_f%%': not a valid identifier" |
Date: |
Sat, 4 Oct 2014 11:05:23 -0500 |
Hi,
A script like main.sh used to work on my Mac OS X. But somehow it
stops working. Can anybody see what is wrong? Where is "BASH_FUNC_f%%"
defined?
/tmp$ /bin/sh --version
GNU bash, version 3.2.51(1)-release (x86_64-apple-darwin13)
Copyright (C) 2007 Free Software Foundation, Inc.
/tmp$ bash --version
GNU bash, version 4.3.28(1)-release (x86_64-apple-darwin13.2.0)
Copyright (C) 2013 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software; you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
/tmp$ function f {
> :
> }
/tmp$ export -f f
/tmp$ ./main.sh
/bin/sh: line 1: `BASH_FUNC_f%%': not a valid identifier
/tmp$ echo $SHELL
/opt/local/bin/bash
/tmp$ which bash
/opt/local/bin/bash
--
Regards,
Peng
- [Help-bash] Weird error of bash "/bin/sh: line 1: `BASH_FUNC_f%%': not a valid identifier",
Peng Yu <=