From mboxrd@z Thu Jan 1 00:00:00 1970 From: "pelzflorian (Florian Pelz)" Subject: Re: How to specify custom remappings with keyboard-layout? Date: Tue, 7 Apr 2020 03:50:38 +0200 Message-ID: <20200407015038.adayciaclc4l7t74@pelzflorian.localdomain> References: <20200405221822.opk7w7f6uxpdfjxd@gravity> <20200406010524.ao2hcdoczejyaamc@pelzflorian.localdomain> <20200406012229.7nfpgnfjytrby2mz@pelzflorian.localdomain> <20200406110502.unkhcuhx6m6mzta6@gravity> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="4akvi5cepbh4tj6j" Content-Transfer-Encoding: 7bit Return-path: Received: from eggs.gnu.org ([2001:470:142:3::10]:37048) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jLdO5-00050b-6n for help-guix@gnu.org; Mon, 06 Apr 2020 21:50:53 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jLdNy-00089f-Vo for help-guix@gnu.org; Mon, 06 Apr 2020 21:50:46 -0400 Received: from pelzflorian.de ([5.45.111.108]:40582 helo=mail.pelzflorian.de) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1jLdNy-00088m-DR for help-guix@gnu.org; Mon, 06 Apr 2020 21:50:42 -0400 Content-Disposition: inline In-Reply-To: <20200406110502.unkhcuhx6m6mzta6@gravity> List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-guix-bounces+gcggh-help-guix=m.gmane-mx.org@gnu.org Sender: "Help-Guix" To: Jakub =?utf-8?B?S8SFZHppb8WCa2E=?= Cc: help-guix@gnu.org --4akvi5cepbh4tj6j Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Apr 06, 2020 at 01:05:02PM +0200, Jakub K=C4=85dzio=C5=82ka wrote= : > On Mon, Apr 06, 2020 at 03:22:29AM +0200, pelzflorian (Florian Pelz) wr= ote: > > On Mon, Apr 06, 2020 at 03:05:24AM +0200, pelzflorian (Florian Pelz) = wrote: > > > You could probably use an .xinitrc file like Arch or you could patc= h > > > xorg-server to use your xkbcomp map by default. > >=20 > > That is, instead of patching xorg-server, you would patch > > xkeyboard-config=E2=80=99s xkb/symbols. I have not tried. Maybe bet= ter use > > .xinitrc? >=20 > That's not a terrible idea, though I'd rather have it apply even before > I'm logged in. (I previously mentioned GDM, though I now realize that I > actually use SLiM.) Is there an equivalent file I could use to run a > command when the login manager is starting? >=20 > Regards, > Jakub K=C4=85dzio=C5=82ka I thought it was sufficient to add the files both to your home directory and to root=E2=80=99s because SLIM is run as root. But: Actually it seems the gnu/services/xorg.scm is defined in a way that does not run ~/.xinitrc. Sorry for not being helpful. I tried but was *not* able to modify gnu/services/xorg.scm to run xkbcomp on a custom ~/.Xkeymap file, although manual execution after the session started works fine. Changing the xinitrc does not appear to work. The attached changes are insufficient. Regards, Florian --4akvi5cepbh4tj6j Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="xkeymap.patch" diff --git a/gnu/services/xorg.scm b/gnu/services/xorg.scm index d0196a299e..5ddf41dafd 100644 --- a/gnu/services/xorg.scm +++ b/gnu/services/xorg.scm @@ -403,8 +403,13 @@ desktop session from the system or user profile will be used." ;; The '--login' option is supported at least by Bash and zsh. (execl shell shell "--login" "-c" - (string-join (cons command args))))) - + (string-join (cons* + #$(file-append xkbcomp "/bin/xkbcomp") + (string-append (getenv "HOME") "/.Xkeymap") + (getenv "DISPLAY") + ";" + command args))))) + (define system-profile "/run/current-system/profile") --4akvi5cepbh4tj6j--