aboutsummaryrefslogtreecommitdiff
path: root/gnu/services
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2016-02-05 16:48:39 +0100
committerLudovic Courtès <ludo@gnu.org>2016-02-05 22:10:42 +0100
commitedc891fa7625cad07857f05a622448e4bbda5bb9 (patch)
treefb732d822dfd0a5e959d39be01a2358ac39fbceb /gnu/services
parent42c97811c973d41b752a9cc561d2544583cc5c71 (diff)
downloadguix-edc891fa7625cad07857f05a622448e4bbda5bb9.tar
guix-edc891fa7625cad07857f05a622448e4bbda5bb9.tar.gz
services: upower: Add upower to the global profile.
* gnu/services/desktop.scm (upower-service-type): Extend PROFILE-SERVICE-TYPE.
Diffstat (limited to 'gnu/services')
-rw-r--r--gnu/services/desktop.scm29
1 files changed, 16 insertions, 13 deletions
diff --git a/gnu/services/desktop.scm b/gnu/services/desktop.scm
index 9d6abc3867..71d0f58cd7 100644
--- a/gnu/services/desktop.scm
+++ b/gnu/services/desktop.scm
@@ -1,5 +1,5 @@
;;; GNU Guix --- Functional package management for GNU
-;;; Copyright © 2014, 2015 Ludovic Courtès <ludo@gnu.org>
+;;; Copyright © 2014, 2015, 2016 Ludovic Courtès <ludo@gnu.org>
;;; Copyright © 2015 Andy Wingo <wingo@igalia.com>
;;; Copyright © 2015 Mark H Weaver <mhw@netris.org>
;;;
@@ -182,18 +182,21 @@ is set to @var{value} when the bus daemon launches it."
(stop #~(make-kill-destructor))))))
(define upower-service-type
- (service-type (name 'upower)
- (extensions
- (list (service-extension dbus-root-service-type
- upower-dbus-service)
- (service-extension shepherd-root-service-type
- upower-shepherd-service)
- (service-extension activation-service-type
- (const %upower-activation))
- (service-extension udev-service-type
- (compose
- list
- upower-configuration-upower))))))
+ (let ((upower-package (compose list upower-configuration-upower)))
+ (service-type (name 'upower)
+ (extensions
+ (list (service-extension dbus-root-service-type
+ upower-dbus-service)
+ (service-extension shepherd-root-service-type
+ upower-shepherd-service)
+ (service-extension activation-service-type
+ (const %upower-activation))
+ (service-extension udev-service-type
+ upower-package)
+
+ ;; Make the 'upower' command visible.
+ (service-extension profile-service-type
+ upower-package))))))
(define* (upower-service #:key (upower upower)
(watts-up-pro? #f)