From patchwork Wed Feb 26 21:07:44 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: dario X-Patchwork-Id: 20449 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 26C4A27BBEA; Wed, 26 Feb 2020 21:27:38 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, FREEMAIL_FROM,MAILING_LIST_MULTI,T_DKIM_INVALID,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.2 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTP id ADB1D27BBE4 for ; Wed, 26 Feb 2020 21:27:37 +0000 (GMT) Received: from localhost ([::1]:50308 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j74DQ-0004y0-Vr for patchwork@mira.cbaines.net; Wed, 26 Feb 2020 16:27:37 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:60057) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j74Cx-0004xm-3o for guix-patches@gnu.org; Wed, 26 Feb 2020 16:27:09 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1j74Cv-0003FN-RD for guix-patches@gnu.org; Wed, 26 Feb 2020 16:27:07 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:51885) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1j74Cv-0003Ds-Et for guix-patches@gnu.org; Wed, 26 Feb 2020 16:27:05 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1j74Cs-0000yb-Bt for guix-patches@gnu.org; Wed, 26 Feb 2020 16:27:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#39804] [PATCH] gnu: add emacs-exwm-next package (i.e. exwm for emacs-next) Resent-From: dakling Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 26 Feb 2020 21:27:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 39804 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 39804@debbugs.gnu.org X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.15827523983707 (code B ref -1); Wed, 26 Feb 2020 21:27:02 +0000 Received: (at submit) by debbugs.gnu.org; 26 Feb 2020 21:26:38 +0000 Received: from localhost ([127.0.0.1]:57856 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j74CU-0000xi-05 for submit@debbugs.gnu.org; Wed, 26 Feb 2020 16:26:38 -0500 Received: from lists.gnu.org ([209.51.188.17]:44570) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j741Y-0000ev-U3 for submit@debbugs.gnu.org; Wed, 26 Feb 2020 16:15:21 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:53780) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j741X-00069q-Bn for guix-patches@gnu.org; Wed, 26 Feb 2020 16:15:20 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1j741V-0000V3-Te for guix-patches@gnu.org; Wed, 26 Feb 2020 16:15:19 -0500 Received: from mout.web.de ([217.72.192.78]:53389) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1j741T-0000Go-6o for guix-patches@gnu.org; Wed, 26 Feb 2020 16:15:16 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=web.de; s=dbaedf251592; t=1582751711; bh=IKNNA5YiDhe4EIVC9ujnX63p8SvC+bqJ4lm998dH1vQ=; h=X-UI-Sender-Class:From:To:Subject:Date; b=lDSngoeHV9Kw5AMykmS8Oa8LjlvZiE3nXHLP+LTXA+dkzyrn73H+zHhK9+BRM3Uci UVSx9VMtXmY2Y5MnZj9nLwCU7xNCgjg5Yf3Oz1wrivdI/QiqJ0bjWHsIsVIkn0vx+X WdHnhay68NxirxLviKf24kxphwi87SX5MqHSnIS4= X-UI-Sender-Class: c548c8c5-30a9-4db5-a2e7-cb6cb037b8f9 Received: from klingenberg-tablet ([95.222.214.30]) by smtp.web.de (mrweb102 [213.165.67.124]) with ESMTPSA (Nemesis) id 0MOzsZ-1j1GSO0wHH-006QLd for ; Wed, 26 Feb 2020 22:15:11 +0100 User-agent: mu4e 1.2.0; emacs 27.0.50 From: dakling Date: Wed, 26 Feb 2020 22:07:44 +0100 Message-ID: <87blplqcdd.fsf@web.de> MIME-Version: 1.0 X-Provags-ID: V03:K1:atInNwPyqgiq3TcDMQZaAOyt1QqJSj4vvZk0uUXvWUKoEJBLn3L HCzIDs0tKg6HktpF7eh5mTS/ChMWLVkRbxh8ZpGwv8M/bg3EybaTW0Sj0qU9m2tdUvE+6tV 2WKFrx3g2wi0YF80rpO2SkFD74DFmq/ELRNQsfufV7NkyO7wa6KH+e9UYKv79Sdzg1Sy3DS WC1qH3Ou/2ZTCK61eS26g== X-UI-Out-Filterresults: notjunk:1;V03:K0:RVwRrgUGuIs=:sdJa4e8BX+mepVhgMIipX5 HMrN5b8AqFDn6JuARGGVmqjPoJll/5ByEMYJZIU2IUB4k5+9ekXRChoyKlKiNCgteTe/O+hGz UUqR/l7ICzkiPutwtmtbbzSxPMSMm323QRQKMMjNAQ5VYk9Ysuy/52tlYUSajTvnsRJv1LCSV bP/9O9HSvOfIdc2oE1zDYwsGtxoMPi6JOC19BLyfCML5Idd2+HIXRUNEz/2ciGsSV8WpzwIuw AMatdkVhM3Rx9HA5e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linux 2.2.x-3.x [generic] X-Mailman-Approved-At: Wed, 26 Feb 2020 16:26:36 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches --- gnu/packages/emacs-xyz.scm | 71 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 71 insertions(+) --- 2.25.1 diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 6b9027df8a..c6df469895 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -8601,6 +8601,77 @@ It should enable you to implement low-level X11 applications.") built on top of XELB.") (license license:gpl3+))) +(define-public emacs-exwm-next + (package + (name "emacs-exwm-next") + (version "0.23") + (synopsis "Emacs X window manager") + (source (origin + (method url-fetch) + (uri (string-append "https://elpa.gnu.org/packages/exwm-" + version ".tar")) + (sha256 + (base32 + "05w1v3wrp1lzz20zd9lcvr5nhk809kgy6svvkbs15xhnr6x55ad5")))) + (build-system emacs-build-system) + (propagated-inputs + `(("emacs-xelb" ,emacs-xelb))) + (inputs + `(("xhost" ,xhost) + ("emacs-next" ,emacs-next) + ("dbus" ,dbus))) + ;; The following functions and variables needed by emacs-exwm are + ;; not included in emacs-minimal: + ;; scroll-bar-mode, fringe-mode + ;; x-display-pixel-width, x-display-pixel-height + (arguments + `(#:emacs ,emacs + #:phases + (modify-phases %standard-phases + (add-after 'build 'install-xsession + (lambda* (#:key inputs outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (xsessions (string-append out "/share/xsessions")) + (bin (string-append out "/bin")) + (exwm-executable (string-append bin "/exwm"))) + ;; Add a .desktop file to xsessions + (mkdir-p xsessions) + (mkdir-p bin) + (with-output-to-file + (string-append xsessions "/exwm.desktop") + (lambda _ + (format #t "[Desktop Entry]~@ + Name=~a~@ + Comment=~a~@ + Exec=~a~@ + TryExec=~:*~a~@ + Type=Application~%" ,name ,synopsis exwm-executable))) + ;; Add a shell wrapper to bin + (with-output-to-file exwm-executable + (lambda _ + (format #t "#!~a ~@ + ~a +SI:localuser:$USER ~@ + exec ~a --exit-with-session ~a \"$@\" --eval '~s' ~%" + (string-append (assoc-ref inputs "bash") "/bin/sh") + (string-append (assoc-ref inputs "xhost") "/bin/xhost") + (string-append (assoc-ref inputs "dbus") "/bin/dbus-launch") + (string-append (assoc-ref inputs "emacs-next") "/bin/emacs") + '(cond + ((file-exists-p "~/.exwm") + (load-file "~/.exwm")) + ((not (featurep 'exwm)) + (require 'exwm) + (require 'exwm-config) + (exwm-config-default) + (message (concat "exwm configuration not found. " + "Falling back to default configuration..."))))))) + (chmod exwm-executable #o555) + #t)))))) + (home-page "https://github.com/ch11ng/exwm") + (description "EXWM is a full-featured tiling X window manager for Emacs +built on top of XELB.") + (license license:gpl3+))) + (define-public emacs-switch-window (package (name "emacs-switch-window")