From unknown Sat Aug 16 16:00:10 2025 X-Loop: bug-gnu-emacs@gnu.org Subject: bug#5366: (un)comment-line macros Mail-Followup-To: Mads Jensen , 5366@debbugs.gnu.org Resent-From: Mads Jensen Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 12 Jan 2010 20:38:01 +0000 Resent-Message-ID: Resent-Sender: bug-gnu-emacs@gnu.org X-Emacs-PR-Message: report 5366 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Received: via spool by submit@debbugs.gnu.org id=B.126332862920741 (code B ref -1); Tue, 12 Jan 2010 20:38:01 +0000 Received: (at submit) by debbugs.gnu.org; 12 Jan 2010 20:37:09 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1NUnU0-0005O9-Ko for submit@debbugs.gnu.org; Tue, 12 Jan 2010 15:37:09 -0500 Received: from fencepost.gnu.org ([140.186.70.10]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1NUmbI-0004hN-1b for submit@debbugs.gnu.org; Tue, 12 Jan 2010 14:40:26 -0500 Received: from mx10.gnu.org ([199.232.76.166]:36231) by fencepost.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1NUmbD-00015v-P2 for submit@debbugs.gnu.org; Tue, 12 Jan 2010 14:40:19 -0500 Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1NUmbC-0005AQ-1U for submit@debbugs.gnu.org; Tue, 12 Jan 2010 14:40:18 -0500 X-Spam-Checker-Version: SpamAssassin 3.1.0 (2005-09-13) on monty-python X-Spam-Level: X-Spam-Status: No, score=-2.0 required=5.0 tests=AWL,BAYES_00, UNPARSEABLE_RELAY autolearn=ham version=3.1.0 Received: from lists.gnu.org ([199.232.76.165]:48048) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1NUmbB-0005AG-QM for submit@debbugs.gnu.org; Tue, 12 Jan 2010 14:40:17 -0500 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NUmbB-0007ob-9a for bug-gnu-emacs@gnu.org; Tue, 12 Jan 2010 14:40:17 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NUmb6-0007nk-FF for bug-gnu-emacs@gnu.org; Tue, 12 Jan 2010 14:40:16 -0500 Received: from [199.232.76.173] (port=50181 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NUmb6-0007nf-Au for bug-gnu-emacs@gnu.org; Tue, 12 Jan 2010 14:40:12 -0500 Received: from fitch7.uni2.net ([129.142.225.149]:55368) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NUmb5-00054I-UU for bug-gnu-emacs@gnu.org; Tue, 12 Jan 2010 14:40:12 -0500 Received: from [10.0.10.211] (unknown [130.227.120.134]) by fitch7.uni2.net (Postfix) with ESMTP id 6F9922A02C9F for ; Tue, 12 Jan 2010 20:40:02 +0100 (CET) Message-ID: <4B4CCFFB.6020404@inducks.org> Date: Tue, 12 Jan 2010 20:39:39 +0100 From: Mads Jensen User-Agent: Thunderbird 2.0.0.23 (X11/20090817) MIME-Version: 1.0 To: bug-gnu-emacs@gnu.org X-Enigmail-Version: 0.95.7 OpenPGP: id=7E775BDA Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enigB65D5F490517F2D7590FE49E" X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.4-2.6 X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) X-Spam-Score: -6.6 (------) X-Mailman-Approved-At: Tue, 12 Jan 2010 15:36:55 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.6 (------) This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enigB65D5F490517F2D7590FE49E Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: quoted-printable Hi, I wrote the following two very simple macros. Nevertheless, I find them very useless, and would be pleased if you could include them in a future version of emacs. (defun comment-line () "comments the line" (interactive) (let ((start (point-at-bol)) (end (point-at-eol))) (save-excursion (indent-region start end) (comment-region start end) (if (not (string=3D major-mode "text-mode")) (indent-for-tab-command))))) (defun uncomment-line () "uncomments the current line" (interactive) (let ((start (point-at-bol)) (end (point-at-eol))) (save-excursion (uncomment-region start end) (if (not (string=3D major-mode "text-mode")) (indent-region start end))))) I bound them to "C-c l" and "C-c u" respectively. Yours sincerely, Mads Jensen --------------enigB65D5F490517F2D7590FE49E Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iEYEARECAAYFAktMz/sACgkQPOK1Nn53W9r9GgCdEWcxUJY3U2ZpfDuvKrdU4BFT rlYAn157ifbI+nTcj5SPhXEKmsdddlTc =ODSL -----END PGP SIGNATURE----- --------------enigB65D5F490517F2D7590FE49E-- From debbugs-submit-bounces@debbugs.gnu.org Wed Jan 13 12:39:30 2010 Received: (at control) by debbugs.gnu.org; 13 Jan 2010 17:39:30 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1NV7Bq-0005Bi-2S for submit@debbugs.gnu.org; Wed, 13 Jan 2010 12:39:30 -0500 Received: from fencepost.gnu.org ([140.186.70.10]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1NV7Bn-0005Bb-KB for control@debbugs.gnu.org; Wed, 13 Jan 2010 12:39:27 -0500 Received: from rgm by fencepost.gnu.org with local (Exim 4.69) (envelope-from ) id 1NV7Bi-00008A-3m; Wed, 13 Jan 2010 12:39:22 -0500 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <19278.1354.66161.232229@fencepost.gnu.org> Date: Wed, 13 Jan 2010 12:39:22 -0500 From: Glenn Morris To: control Subject: control X-Attribution: GM X-Mailer: VM (www.wonderworks.com/vm), GNU Emacs (www.gnu.org/software/emacs) X-Hue: green X-Ran: Br14aVx1s"b%XZBACFejP="95+225[b<2X;?d6*Zi5tg3`Ay]KueFAKm`1I_ List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.4 (---) reassign 1184 emacs forcemerge 1184 5351 reassign 5367 emacs,gnus severity 5366 wishlist severity 5325 minor From debbugs-submit-bounces@debbugs.gnu.org Thu Oct 06 03:50:34 2011 Received: (at control) by debbugs.gnu.org; 6 Oct 2011 07:50:34 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1RBiiv-0004jv-St for submit@debbugs.gnu.org; Thu, 06 Oct 2011 03:50:34 -0400 Received: from fencepost.gnu.org ([140.186.70.10]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1RBiit-0004ji-EM; Thu, 06 Oct 2011 03:50:31 -0400 Received: from rgm by fencepost.gnu.org with local (Exim 4.71) (envelope-from ) id 1RBiik-00020k-UF; Thu, 06 Oct 2011 03:50:23 -0400 From: Glenn Morris To: 5366-done@debbugs.gnu.org Subject: Re: bug#5366: (un)comment-line macros References: <4B4CCFFB.6020404@inducks.org> X-Spook: AMW analyzer Echelon AK-47 unclassified CESID counter X-Ran: `xZvbhsta9D5S"j2`rG45{pjY`#;birz(oXY!vGEf!{?W.%~u[r=kew52IOloQ$"?Ir&{p X-Hue: blue X-Attribution: GM Date: Thu, 06 Oct 2011 03:50:22 -0400 In-Reply-To: <4B4CCFFB.6020404@inducks.org> (Mads Jensen's message of "Tue, 12 Jan 2010 20:39:39 +0100") Message-ID: User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Score: -6.4 (------) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.4 (------) tags 5366 wontfix stop Thanks for sending them, but I don't think Emacs needs these commands. From unknown Sat Aug 16 16:00:10 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.427 (Entity 5.427) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Mads Jensen Subject: bug#5366: closed (Re: bug#5366: (un)comment-line macros) Message-ID: References: <4B4CCFFB.6020404@inducks.org> X-Gnu-PR-Message: they-closed 5366 X-Gnu-PR-Package: emacs X-Gnu-PR-Keywords: wontfix Reply-To: 5366@debbugs.gnu.org Date: Thu, 06 Oct 2011 07:51:02 +0000 Content-Type: multipart/mixed; boundary="----------=_1317887462-18272-1" This is a multi-part message in MIME format... ------------=_1317887462-18272-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #5366: (un)comment-line macros which was filed against the emacs package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 5366@debbugs.gnu.org. --=20 5366: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D5366 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1317887462-18272-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 5366-done) by debbugs.gnu.org; 6 Oct 2011 07:50:34 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1RBiiv-0004js-B5 for submit@debbugs.gnu.org; Thu, 06 Oct 2011 03:50:33 -0400 Received: from fencepost.gnu.org ([140.186.70.10]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1RBiit-0004ji-EM; Thu, 06 Oct 2011 03:50:31 -0400 Received: from rgm by fencepost.gnu.org with local (Exim 4.71) (envelope-from ) id 1RBiik-00020k-UF; Thu, 06 Oct 2011 03:50:23 -0400 From: Glenn Morris To: 5366-done@debbugs.gnu.org Subject: Re: bug#5366: (un)comment-line macros References: <4B4CCFFB.6020404@inducks.org> X-Spook: AMW analyzer Echelon AK-47 unclassified CESID counter X-Ran: `xZvbhsta9D5S"j2`rG45{pjY`#;birz(oXY!vGEf!{?W.%~u[r=kew52IOloQ$"?Ir&{p X-Hue: blue X-Attribution: GM Date: Thu, 06 Oct 2011 03:50:22 -0400 In-Reply-To: <4B4CCFFB.6020404@inducks.org> (Mads Jensen's message of "Tue, 12 Jan 2010 20:39:39 +0100") Message-ID: User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Score: -6.4 (------) X-Debbugs-Envelope-To: 5366-done X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.4 (------) tags 5366 wontfix stop Thanks for sending them, but I don't think Emacs needs these commands. ------------=_1317887462-18272-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 12 Jan 2010 20:37:09 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1NUnU0-0005O9-Ko for submit@debbugs.gnu.org; Tue, 12 Jan 2010 15:37:09 -0500 Received: from fencepost.gnu.org ([140.186.70.10]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1NUmbI-0004hN-1b for submit@debbugs.gnu.org; Tue, 12 Jan 2010 14:40:26 -0500 Received: from mx10.gnu.org ([199.232.76.166]:36231) by fencepost.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1NUmbD-00015v-P2 for submit@debbugs.gnu.org; Tue, 12 Jan 2010 14:40:19 -0500 Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1NUmbC-0005AQ-1U for submit@debbugs.gnu.org; Tue, 12 Jan 2010 14:40:18 -0500 X-Spam-Checker-Version: SpamAssassin 3.1.0 (2005-09-13) on monty-python X-Spam-Level: X-Spam-Status: No, score=-2.0 required=5.0 tests=AWL,BAYES_00, UNPARSEABLE_RELAY autolearn=ham version=3.1.0 Received: from lists.gnu.org ([199.232.76.165]:48048) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1NUmbB-0005AG-QM for submit@debbugs.gnu.org; Tue, 12 Jan 2010 14:40:17 -0500 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NUmbB-0007ob-9a for bug-gnu-emacs@gnu.org; Tue, 12 Jan 2010 14:40:17 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NUmb6-0007nk-FF for bug-gnu-emacs@gnu.org; Tue, 12 Jan 2010 14:40:16 -0500 Received: from [199.232.76.173] (port=50181 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NUmb6-0007nf-Au for bug-gnu-emacs@gnu.org; Tue, 12 Jan 2010 14:40:12 -0500 Received: from fitch7.uni2.net ([129.142.225.149]:55368) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NUmb5-00054I-UU for bug-gnu-emacs@gnu.org; Tue, 12 Jan 2010 14:40:12 -0500 Received: from [10.0.10.211] (unknown [130.227.120.134]) by fitch7.uni2.net (Postfix) with ESMTP id 6F9922A02C9F for ; Tue, 12 Jan 2010 20:40:02 +0100 (CET) Message-ID: <4B4CCFFB.6020404@inducks.org> Date: Tue, 12 Jan 2010 20:39:39 +0100 From: Mads Jensen User-Agent: Thunderbird 2.0.0.23 (X11/20090817) MIME-Version: 1.0 To: bug-gnu-emacs@gnu.org Subject: (un)comment-line macros X-Enigmail-Version: 0.95.7 OpenPGP: id=7E775BDA Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enigB65D5F490517F2D7590FE49E" X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.4-2.6 X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) X-Spam-Score: -6.6 (------) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Tue, 12 Jan 2010 15:36:55 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.6 (------) This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enigB65D5F490517F2D7590FE49E Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: quoted-printable Hi, I wrote the following two very simple macros. Nevertheless, I find them very useless, and would be pleased if you could include them in a future version of emacs. (defun comment-line () "comments the line" (interactive) (let ((start (point-at-bol)) (end (point-at-eol))) (save-excursion (indent-region start end) (comment-region start end) (if (not (string=3D major-mode "text-mode")) (indent-for-tab-command))))) (defun uncomment-line () "uncomments the current line" (interactive) (let ((start (point-at-bol)) (end (point-at-eol))) (save-excursion (uncomment-region start end) (if (not (string=3D major-mode "text-mode")) (indent-region start end))))) I bound them to "C-c l" and "C-c u" respectively. Yours sincerely, Mads Jensen --------------enigB65D5F490517F2D7590FE49E Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iEYEARECAAYFAktMz/sACgkQPOK1Nn53W9r9GgCdEWcxUJY3U2ZpfDuvKrdU4BFT rlYAn157ifbI+nTcj5SPhXEKmsdddlTc =ODSL -----END PGP SIGNATURE----- --------------enigB65D5F490517F2D7590FE49E-- ------------=_1317887462-18272-1--