Substring replacement in ash doesn't support slashes

Denys Vlasenko vda.linux at googlemail.com
Tue Jan 9 16:09:19 UTC 2018


On Wed, Dec 13, 2017 at 9:56 AM, Rafał Miłecki <zajec5 at gmail.com> wrote:
> Oh, I accidentally used some shortcut for sending an e-mail.
>
> On 13 December 2017 at 09:54, Rafał Miłecki <zajec5 at gmail.com> wrote:
>> I wanted to replace all slashes in my string with some other char.
>>
>> Example:
>> dir=foo/bar/qux
>> echo "${dir//\//-}"
>>
>> It works well in GNU bash (it produces "foo-bar-qux"), but doesn't in ash.
>
> I tried busybox 1.25.1 and 1.27.2.
>
> Could someone take a look at this, please?

Fixed in git just now, please try and let me know whether it works.


More information about the busybox mailing list