Hello, Ricardo Wurmus <rek...@elephly.net> skribis:
> requesting that a shepherd service (e.g. ’foo’) that has already been > stopped be stopped again produces the error "service 'foo' could not be > found". This is confusing because it implies that ’foo’ is not a valid > name. Indeed. > From c285d0f085e8e9c6a4ad347643f7186807735189 Mon Sep 17 00:00:00 2001 > From: Ricardo Wurmus <rek...@elephly.net> > Date: Sun, 3 Feb 2019 23:25:22 +0100 > Subject: [PATCH] service: Don't raise error when stopping an already stopped > service. > > * modules/shepherd/service.scm (stop): If a service by the given name exists > and is already stopped, then don't raise an error. LGTM, though could you add a test? There are already tests that grep the output of “herd stop foo”; you’d just grep it a second time and ensure it’s empty, and also ensure that $? is zero. Thanks! Ludo’.