Commit 1af59b31 authored by Mike Gabriel's avatar Mike Gabriel

Add Jan's reasoning for using string_rep() instead of bash based string…

Add Jan's reasoning for using string_rep() instead of bash based string substitutions as comment to /debian/Makefile.replaces.sh.
parent 1b4092e0
# from http://mywiki.wooledge.org/BashFAQ/021 # from http://mywiki.wooledge.org/BashFAQ/021
# The ${a/b/c} substitution is not POSIX compatible. Additionally, in
# bash 3.x, quotes do not escape slashes. This causes screwed up
# installation paths.
#
# SLES 11, bash-3.2-147.9.13
# $ dirname="foo/bar"
# $ echo ${dirname//"foo/bar"/"omg/nei"}
# bar/omg/nei/bar
#
# openSUSE 12.2, bash-4.2-51.6.1
# $ dirname="foo/bar"
# $ echo ${dirname//"foo/bar"/"omg/nei"}
# omg/nei
#
# openSUSE 12.2, dash-0.5.7-5.1.2.x86_64
# $ dirname="foo/bar"
# $ echo ${dirname//"foo/bar"/"omg/nei"}
# dash: 2: Bad substitution
#
# Source this file into your bash scripts to make available
# a replacement (the string_rep function) for this substitution
# mess.
#
string_rep() string_rep()
{ {
# initialize vars # initialize vars
......
nx-libs (2:3.5.0.19-0) UNRELEASED; urgency=low
* Add Jan's reasoning for using string_rep() instead of bash based
string substitutions as comment to /debian/Makefile.replaces.sh.
-- Mike Gabriel <sunweaver@debian.org> Sat, 23 Mar 2013 00:42:01 +0100
nx-libs (2:3.5.0.18-0) unstable; urgency=low nx-libs (2:3.5.0.18-0) unstable; urgency=low
[ Mike Gabriel ] [ Mike Gabriel ]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment