Re: Problem expanding environment variables

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Sep 6, 2024 at 1:40 PM Thomas Köller <thomas@xxxxxxxxxxxxxxxxxx> wrote:
>
> Am 06.09.24 um 11:04 schrieb Andrei Borzenkov:
> > You need to quote $ to pass it to the shell.
> > ExecStart = sh -c 'echo Res: $${VAR#abc-}'
>
> Yes, this works. However, I didn't find this anywhere in the systemd man
> pages. What I found was escaping using a backslash, but that didn't work.
>
>

"man systemd.service", section "Command lines", scroll down.

To pass a literal dollar sign, use "$$".




[Index of Archives]     [LARTC]     [Bugtraq]     [Yosemite Forum]     [Photo]

  Powered by Linux