From ca0c43ecf02a5451ab0dd2f855032e316b4a4792 Mon Sep 17 00:00:00 2001 From: Mathieu Othacehe Date: Wed, 5 Dec 2018 14:13:38 +0900 Subject: services: herd: Allow to pass arguments to start-service. * gnu/services/herd.scm (start-service)[arguments]: New optional argument. --- gnu/services/herd.scm | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'gnu') diff --git a/gnu/services/herd.scm b/gnu/services/herd.scm index 8ff817759d..9fe757fb73 100644 --- a/gnu/services/herd.scm +++ b/gnu/services/herd.scm @@ -252,9 +252,10 @@ when passed a service with an already-registered name." services (remove registered? services)))))) -(define (start-service name) - (with-shepherd-action name ('start) result - result)) +(define* (start-service name #:optional (arguments '())) + (invoke-action name 'start arguments + (lambda (result) + result))) (define (stop-service name) (with-shepherd-action name ('stop) result -- cgit v1.2.3