From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Emanuel Berg Newsgroups: gmane.emacs.help Subject: Re: How to do a massive unfill paragraph operation over several hundred files? Date: Tue, 02 Oct 2018 17:11:15 +0200 Organization: Aioe.org NNTP Server Message-ID: <86d0ss8ju4.fsf@zoho.com> References: <8636ts4jz3.fsf@zoho.com> <86zhvyzq4c.fsf@zoho.com> <86muryype2.fsf@zoho.com> <87in2lvikf.fsf@tu-berlin.de> <875zyl1yls.fsf@gmail.com> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1538493352 21744 195.159.176.226 (2 Oct 2018 15:15:52 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Tue, 2 Oct 2018 15:15:52 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.4 (gnu/linux) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Oct 02 17:15:48 2018 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1g7MOp-0005ZW-Pv for geh-help-gnu-emacs@m.gmane.org; Tue, 02 Oct 2018 17:15:47 +0200 Original-Received: from localhost ([::1]:44220 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1g7MQv-0006Kn-Vg for geh-help-gnu-emacs@m.gmane.org; Tue, 02 Oct 2018 11:17:57 -0400 X-Received: by 2002:a1c:4b04:: with SMTP id y4-v6mr327699wma.7.1538493077142; Tue, 02 Oct 2018 08:11:17 -0700 (PDT) Original-Path: usenet.stanford.edu!143-v6no1197630wmm.0!news-out.google.com!z184-v6ni3505wmz.0!nntp.google.com!proxad.net!feeder1-2.proxad.net!news.mixmin.net!aioe.org!.POSTED!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 29 Original-NNTP-Posting-Host: xQsFb8j6c/kdg9AvIrnVFA.user.gioia.aioe.org Original-X-Complaints-To: abuse@aioe.org X-Notice: Filtered by postfilter v. 0.8.3 Cancel-Lock: sha1:SFOwHIbpsPJsZazWDipcgv9aF0A= Mail-Copies-To: never Original-Xref: usenet.stanford.edu gnu.emacs.help:223966 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.21 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" Xref: news.gmane.org gmane.emacs.help:118092 Archived-At: Gerald Wildgruber wrote: > (dolist (f argv) (find-file f) > (mark-whole-buffer) (unfill-paragraph t) > (org-forward-paragraph) (save-buffer)) This looks a bit wierd but I'm unsure because I'm not as close to whatever it is you're trying to do. What does `org-forward-paragraph' do? Shouldn't you have a loop for that as well if you you want to do this to several paragraphs? But then, isn't `mark-whole-buffer' something that runs contradictory to this? Even so, something should happen what I can see. Like the FIRST paragraph getting unfilled at the very least. Try to replace it with something simpler. Like adding a single char to each file: (insert ?a) If this works, your problem is with the `dolist' stuff and you just need the details figured out. -- underground experts united http://user.it.uu.se/~embe8573