From mboxrd@z Thu Jan 1 00:00:00 1970 From: Joshua Branson Subject: Re: Deleting unnecessary services from %desktop-services Date: Sat, 01 Dec 2018 08:47:18 -0500 Message-ID: <87bm65l5p5.fsf@fastmail.com> References: > <87bm6am94n.fsf@ambrevar.xyz> > <87efb32s1f.fsf@elephly.net> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:35951) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gT5bR-0006Zz-Hq for help-guix@gnu.org; Sat, 01 Dec 2018 08:46:38 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gT5bM-0001Jo-NT for help-guix@gnu.org; Sat, 01 Dec 2018 08:46:37 -0500 Received: from out4-smtp.messagingengine.com ([66.111.4.28]:42109) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gT5bM-0001Ja-KC for help-guix@gnu.org; Sat, 01 Dec 2018 08:46:32 -0500 Received: from compute6.internal (compute6.nyi.internal [10.202.2.46]) by mailout.nyi.internal (Postfix) with ESMTP id 1A23922101 for ; Sat, 1 Dec 2018 08:46:32 -0500 (EST) Received: from dobby (unknown [72.12.220.132]) by mail.messagingengine.com (Postfix) with ESMTPA id 830DA102DD for ; Sat, 1 Dec 2018 08:46:31 -0500 (EST) In-Reply-To: (znavko's message of "Sat, 1 Dec 2018 06:06:59 +0100 (CET)") List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-guix-bounces+gcggh-help-guix=m.gmane.org@gnu.org Sender: "Help-Guix" To: help-guix@gnu.org writes: > Hello, Ricardo Wurmus! ok, thank you. But now I've not achieved what I ne= ed. avahi-damon, ntpd, networking rest in my system.=20 I thought that Pierre answered that for you: > guix system: error: service 'ntpd' requires 'networking', which is not > provided by any service This is telling you that you can't have the ntpd service if you remove the network stack, so - either remove ntpd - or add another network stack that provides 'networking' (maybe wicd or the like). > > (services (cons* ;;(tor-service) > (service postgresql-service-type) > (xfce-desktop-service) > (modify-services=20=20=20=20=20=20 > (remove (lambda (service) > (eq? (service-kind service)=20 > avahi-service-type ntp-service-type networ= king)) > %desktop-services > );end of remove > (elogind-service-type > c =3D> (elogind-configuration (handle-lid-switch = 'ignore))) > );;end of modify desktop-services > ));;end of services > > Also they are mentioned in use-modules: > > (use-modules (gnu) (gnu system nss) > (gnu services desktop) > (srfi srfi-1) ;;for remove function > (gnu services networking) ;;for remove ntp > (gnu services avahi) ;;for remove avahi > (gnu services xorg) > (gnu services databases);;for postgres > ) > (use-service-modules desktop) > (use-package-modules certs gnome) > > But if I delete this use-modules lines, remove line will give the errors:= unbound variable avahi-service-type, ntp-service-type, networking.=20 > So, how to correct I do not know. I think that you have to have those modules defined so you can remove the services. Having that use modules line won't mean those services are run. > > Nov 30, 2018, 5:55 AM by rekado@elephly.net: > > znavko@tutanota.com writes: > > Guile Manual says 'remove' returns elements. But I need to remove elemen= ts. > > =E2=80=9Cremove=E2=80=9D does what you want. The =E2=80=9Cservices=E2=80= =9D field expects a list of > services. When using =E2=80=9Cremove=E2=80=9D on a list of services it r= eturns a new > list of (possibly fewer) services. That=E2=80=99s exactly what you want. > > =E2=80=9Cremove!=E2=80=9D, on the other hand, mutates an existing value;= you would need > to have it operate on an existing variable to mutate it. =E2=80=9Cremove= =E2=80=9D is > much more elegant. > > -- > Ricardo