From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:470:142:3::10]:42922) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iwacO-0002C6-7c for guix-patches@gnu.org; Tue, 28 Jan 2020 18:50:05 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1iwacM-0005Xi-66 for guix-patches@gnu.org; Tue, 28 Jan 2020 18:50:03 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:55295) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1iwacM-0005XU-3M for guix-patches@gnu.org; Tue, 28 Jan 2020 18:50:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1iwacM-0002hR-1O for guix-patches@gnu.org; Tue, 28 Jan 2020 18:50:02 -0500 Subject: [bug#39333] [PATCH 1/2] gnu: Add emacs-switch-buffer-functions. Resent-Message-ID: Received: from eggs.gnu.org ([2001:470:142:3::10]:42549) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iwabm-0002Bc-Vs for guix-patches@gnu.org; Tue, 28 Jan 2020 18:49:28 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:37972) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1iwabm-0003og-SW for guix-patches@gnu.org; Tue, 28 Jan 2020 18:49:26 -0500 From: Amin Bandali Date: Tue, 28 Jan 2020 18:49:11 -0500 Message-Id: <20200128234911.8601-1-mab@gnu.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: 39333@debbugs.gnu.org Cc: Amin Bandali * gnu/packages/emacs-xyz.scm (emacs-switch-buffer-functions): New variable. --- gnu/packages/emacs-xyz.scm | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index e834dfffb3..6cd463d582 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -21237,3 +21237,26 @@ mode-line text (lighter) of major and minor modes.") (description "@code{unkillable-scratch} helps prevent killing buffers matching a given regexp.") (license license:gpl2+)))) + +(define-public emacs-switch-buffer-functions + (package + (name "emacs-switch-buffer-functions") + (version "0.0.1") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/10sr/switch-buffer-functions-el.git") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0pq53b8wrjbrxd5hnrcdi0z7mffp4bax55hn90k9ca3j76lhbn1k")))) + (build-system emacs-build-system) + (home-page "https://github.com/10sr/switch-buffer-functions-el") + (synopsis "Hooks run when switching current buffer") + (description "This package provides a hook variable +@code{switch-buffer-functions}. The hooks will be run when the +current buffer is changed after an interactive command, i.e. when +@code{post-command-hook} hooks are run. The hooked functions will be +called with both the previous and the current buffer.") + (license license:unlicense))) -- 2.25.0