[systemd-devel] one shot service exit-code

Matt Zagrabelny mzagrabe at d.umn.edu
Tue Oct 31 16:37:15 UTC 2017


On Tue, Oct 31, 2017 at 11:29 AM, Reindl Harald <h.reindl at thelounge.net>
wrote:

>
>
>> Any ideas why the terminal exit code is 0 from another terminal, but when
>> systemd spawns it, it is 255?
>>
>
> that's a question for gnome developers and i din't touch anything from
> them until i am forced so, they probalby don't gasp the 0 is the default
> return code on unix/linux


Hmmm... the return code is 0 when I start the mate-terminal from another
mate-terminal. ???

Oh, well.

Thanks for the help. It works like a charm:

Oct 31 11:32:22 eruke systemd[1274]: Starting
download-photos at SAMSUNG_SAMSUNG_Android_17b765cc.service...
Oct 31 11:32:25 eruke systemd[1274]: Started
download-photos at SAMSUNG_SAMSUNG_Android_17b765cc.service.

and the unit for posterity:

cat ~/.config/systemd/user/download-photos at .service
[Service]
Type=oneshot
ExecStart=/usr/bin/mate-terminal --maximize --command '/usr/bin/imagdo
--config-file %h/.imagdo/%I.yaml'
SuccessExitStatus=0 255

Cheers!

-m
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/systemd-devel/attachments/20171031/2d88d800/attachment-0001.html>


More information about the systemd-devel mailing list