From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 75277158090 for ; Sun, 1 May 2022 17:36:00 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 44C9CE0B8B; Sun, 1 May 2022 17:35:58 +0000 (UTC) Received: from smtp.gentoo.org (dev.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 28E3AE0B8B for ; Sun, 1 May 2022 17:35:58 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 08707341111 for ; Sun, 1 May 2022 17:35:57 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 942E9430 for ; Sun, 1 May 2022 17:35:55 +0000 (UTC) From: "Ulrich Müller" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Ulrich Müller" Message-ID: <1651425338.2052ab77d3856593ae6c41d305377058d22ed0d2.ulm@gentoo> Subject: [gentoo-commits] proj/eselect:master commit in: misc/, / X-VCS-Repository: proj/eselect X-VCS-Files: ChangeLog misc/eselect-mode.el X-VCS-Directories: / misc/ X-VCS-Committer: ulm X-VCS-Committer-Name: Ulrich Müller X-VCS-Revision: 2052ab77d3856593ae6c41d305377058d22ed0d2 X-VCS-Branch: master Date: Sun, 1 May 2022 17:35:55 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 7ff18e4a-78d7-47f5-8aa3-5b776ce9feae X-Archives-Hash: fca5bd1d84c0696d936193ae90f8f766 commit: 2052ab77d3856593ae6c41d305377058d22ed0d2 Author: Ulrich Müller gentoo org> AuthorDate: Sun May 1 17:15:38 2022 +0000 Commit: Ulrich Müller gentoo org> CommitDate: Sun May 1 17:15:38 2022 +0000 URL: https://gitweb.gentoo.org/proj/eselect.git/commit/?id=2052ab77 Drop XEmacs compatibility code in eselect-mode * misc/eselect-mode.el (eselect-mode-before-save): Call delete-trailing-whitespace which exists in XEmacs 21.5. Signed-off-by: Ulrich Müller gentoo.org> ChangeLog | 2 ++ misc/eselect-mode.el | 6 +----- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/ChangeLog b/ChangeLog index 83b0289..4ef1610 100644 --- a/ChangeLog +++ b/ChangeLog @@ -2,6 +2,8 @@ * misc/eselect-mode.el (eselect-mode): For GNU Emacs, use write-contents-functions instead of obsolete write-contents-hooks. + (eselect-mode-before-save): Call delete-trailing-whitespace which + exists in XEmacs 21.5. 2022-01-08 Ulrich Müller diff --git a/misc/eselect-mode.el b/misc/eselect-mode.el index 50e88d6..3bdac81 100644 --- a/misc/eselect-mode.el +++ b/misc/eselect-mode.el @@ -96,11 +96,7 @@ ;;; Mode definitions. (defun eselect-mode-before-save () - ;;(delete-trailing-whitespace) ; doesn't exist in XEmacs - (save-excursion - (goto-char (point-min)) - (while (re-search-forward "[ \t]+$" nil t) - (delete-region (match-beginning 0) (point)))) + (delete-trailing-whitespace) ;; return nil, otherwise the file is presumed to be written nil)