From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Drew Adams Newsgroups: gmane.emacs.help Subject: RE: How to quit? Date: Wed, 25 Feb 2015 15:21:56 -0800 (PST) Message-ID: References: <87y4nm3svs.fsf@wmi.amu.edu.pl> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1424906558 5485 80.91.229.3 (25 Feb 2015 23:22:38 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 25 Feb 2015 23:22:38 +0000 (UTC) To: Marcin Borkowski , Help Gnu Emacs mailing list Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu Feb 26 00:22:26 2015 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1YQlHe-0001w8-9Y for geh-help-gnu-emacs@m.gmane.org; Thu, 26 Feb 2015 00:22:26 +0100 Original-Received: from localhost ([::1]:56719 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YQlHd-0005Pi-Ku for geh-help-gnu-emacs@m.gmane.org; Wed, 25 Feb 2015 18:22:25 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:52313) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YQlHN-0005JP-7x for help-gnu-emacs@gnu.org; Wed, 25 Feb 2015 18:22:10 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YQlHJ-0006hQ-Uy for help-gnu-emacs@gnu.org; Wed, 25 Feb 2015 18:22:09 -0500 Original-Received: from aserp1040.oracle.com ([141.146.126.69]:48740) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YQlHJ-0006h4-P4 for help-gnu-emacs@gnu.org; Wed, 25 Feb 2015 18:22:05 -0500 Original-Received: from acsinet21.oracle.com (acsinet21.oracle.com [141.146.126.237]) by aserp1040.oracle.com (Sentrion-MTA-4.3.2/Sentrion-MTA-4.3.2) with ESMTP id t1PNM3HQ011973 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Wed, 25 Feb 2015 23:22:04 GMT Original-Received: from aserv0122.oracle.com (aserv0122.oracle.com [141.146.126.236]) by acsinet21.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id t1PNM20S004748 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 25 Feb 2015 23:22:03 GMT Original-Received: from abhmp0002.oracle.com (abhmp0002.oracle.com [141.146.116.8]) by aserv0122.oracle.com (8.13.8/8.13.8) with ESMTP id t1PNM20J026568; Wed, 25 Feb 2015 23:22:02 GMT In-Reply-To: <87y4nm3svs.fsf@wmi.amu.edu.pl> X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.8.2 (807160) [OL 12.0.6691.5000 (x86)] X-Source-IP: acsinet21.oracle.com [141.146.126.237] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] X-Received-From: 141.146.126.69 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:102897 Archived-At: > OK, so I have a problem, and it doesn't show up when I do emacs -Q. So > I take a deep breath and bisect my 900-line init.el... >=20 > In LaTeX, however, when I have some weird problem, I can put \endinput > in a file, and everything past that is ignored. Is there anything like > that in Elisp? > > It just occured to me that (debug) /might/ work, and so might > (keyboard-quit). Is this a good idea? Are there any others? Just put `(top-level)' in your init file where you want it to stop. Command `top-level' returns to, well, Emacs top-level. ;-) But really you will find, I think, that commenting-out blocks of the file is the handiest. I bind `C-x C-;' to `comment-region', which comments or (with `C-u') uncomments the region, and which nests and unnests such commented blocks (unlike `comment-dwim'). Actually, I bind `C-x C-;' to this command, from `misc-cmds.el' (http://www.emacswiki.org/emacs/download/misc-cmds.el). (defun comment-region-lines (beg end &optional arg) "Like `comment-region' (which see), but comment/uncomment whole lines." (interactive "*r\nP") (if (> beg end) (let (mid) (setq mid beg beg end end mid))) (let ((bol (save-excursion (goto-char beg) (line-beginning-position))) (eol (save-excursion (goto-char end) (if (bolp) (point) (line-end-position))))) (comment-region bol eol arg)))