* %desktop-services
@ 2015-05-06 21:03 Ludovic Courtès
2015-05-06 22:10 ` %desktop-services David Thompson
0 siblings, 1 reply; 2+ messages in thread
From: Ludovic Courtès @ 2015-05-06 21:03 UTC (permalink / raw)
To: Guix-devel
[-- Attachment #1: Type: text/plain, Size: 505 bytes --]
I thought it would be helpful to have a ‘%desktop-services’ variable
that would provide the things most “desktop” users typically want in
addition to what ‘%base-services’ provides. See attached patch.
Someone using ‘%desktop-services’ still need to add, say, Xfce to the
declaration’s ‘packages’ field, but that’s already an improvement. We
could have ‘%desktop-packages’, but I’d rather not choose a specific DE
or WM to put in there.
Thoughts?
Ludo’.
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: Type: text/x-patch, Size: 2882 bytes --]
diff --git a/gnu/services/desktop.scm b/gnu/services/desktop.scm
index 5945f7a..910dc1f 100644
--- a/gnu/services/desktop.scm
+++ b/gnu/services/desktop.scm
@@ -19,17 +19,25 @@
(define-module (gnu services desktop)
#:use-module (gnu services)
+ #:use-module (gnu services base)
+ #:use-module (gnu services avahi)
+ #:use-module (gnu services xorg)
+ #:use-module (gnu services networking)
+ #:use-module (gnu services ssh)
#:use-module (gnu system shadow)
#:use-module (gnu packages glib)
#:use-module (gnu packages admin)
#:use-module (gnu packages gnome)
+ #:use-module (gnu packages avahi)
+ #:use-module (gnu packages wicd)
#:use-module (guix monads)
#:use-module (guix store)
#:use-module (guix gexp)
#:use-module (ice-9 match)
#:export (dbus-service
upower-service
- colord-service))
+ colord-service
+ %desktop-services))
;;; Commentary:
;;;
@@ -267,4 +275,26 @@ site} for more information."
(shell
#~(string-append #$shadow "/sbin/nologin")))))))))
+(define %desktop-services
+ ;; List of services typically useful for a "desktop" use case.
+ (cons* (slim-service)
+
+ (avahi-service)
+ (wicd-service)
+ (upower-service)
+ (colord-service)
+ (dbus-service (list avahi wicd upower colord))
+
+ (ntp-service)
+ (lsh-service)
+
+ (map (lambda (mservice)
+ ;; Provide an nscd ready to use nss-mdns.
+ (mlet %store-monad ((service mservice))
+ (if (memq 'nscd (service-provision service))
+ (nscd-service (nscd-configuration)
+ #:name-services (list nss-mdns))
+ mservice)))
+ %base-services)))
+
;;; desktop.scm ends here
diff --git a/gnu/system/os-config.tmpl b/gnu/system/os-config.tmpl
index e14c957..9b0a77c 100644
--- a/gnu/system/os-config.tmpl
+++ b/gnu/system/os-config.tmpl
@@ -1,8 +1,8 @@
;; This is an operating system configuration template.
(use-modules (gnu))
-(use-service-modules xorg networking dbus avahi)
-(use-package-modules xorg avahi)
+(use-service-modules desktop)
+(use-package-modules xorg xfce)
(operating-system
(host-name "antelope")
@@ -36,12 +36,8 @@
(home-directory "/home/alice"))))
;; Globally-installed packages.
- (packages (cons xterm %base-packages))
+ (packages (cons* xterm xfce %base-packages))
;; Add services to the baseline: the SLiM log-in manager
;; for Xorg sessions, a DHCP client, Avahi, and D-Bus.
- (services (cons* (slim-service)
- (dhcp-client-service)
- (avahi-service)
- (dbus-service (list avahi))
- %base-services)))
+ (services %desktop-services))
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: %desktop-services
2015-05-06 21:03 %desktop-services Ludovic Courtès
@ 2015-05-06 22:10 ` David Thompson
0 siblings, 0 replies; 2+ messages in thread
From: David Thompson @ 2015-05-06 22:10 UTC (permalink / raw)
To: Ludovic Courtès, Guix-devel
Ludovic Courtès <ludo@gnu.org> writes:
> I thought it would be helpful to have a ‘%desktop-services’ variable
> that would provide the things most “desktop” users typically want in
> addition to what ‘%base-services’ provides. See attached patch.
>
> Someone using ‘%desktop-services’ still need to add, say, Xfce to the
> declaration’s ‘packages’ field, but that’s already an improvement. We
> could have ‘%desktop-packages’, but I’d rather not choose a specific DE
> or WM to put in there.
>
> Thoughts?
Looks great! Less work for the user.
--
David Thompson
Web Developer - Free Software Foundation - http://fsf.org
GPG Key: 0FF1D807
Support the FSF: https://fsf.org/donate
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2015-05-06 22:10 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-05-06 21:03 %desktop-services Ludovic Courtès
2015-05-06 22:10 ` %desktop-services David Thompson
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).