From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: David Kastrup Newsgroups: gmane.emacs.help Subject: Re: query-replace-regexp ... "Invalid repacement string '\.'" Date: Mon, 25 Sep 2006 08:55:13 +0200 Organization: Organization?!? Message-ID: <85zmcol9ke.fsf@lola.goethe.zz> References: NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1159170204 17005 80.91.229.2 (25 Sep 2006 07:43:24 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Mon, 25 Sep 2006 07:43:24 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon Sep 25 09:43:23 2006 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1GRl78-0008Gk-FG for geh-help-gnu-emacs@m.gmane.org; Mon, 25 Sep 2006 09:42:54 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1GRl77-0008Ij-OI for geh-help-gnu-emacs@m.gmane.org; Mon, 25 Sep 2006 03:42:53 -0400 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!news.tele.dk!news.tele.dk!small.news.tele.dk!news-fra1.dfn.de!news-stu1.dfn.de!news.belwue.de!newsfeed.arcor.de!newsspool4.arcor-online.net!news.arcor.de.POSTED!not-for-mail Original-Newsgroups: gnu.emacs.help X-Face: 2FEFf>]>q>2iw=B6, xrUubRI>pR&Ml9=ao@P@i)L:\urd*t9M~y1^:+Y]'C0~{mAl`oQuAl \!3KEIp?*w`|bL5qr,H)LFO6Q=qx~iH4DN; i"; /yuIsqbLLCh/!U#X[S~(5eZ41to5f%E@'ELIi$t^ Vc\LWP@J5p^rst0+('>Er0=^1{]M9!p?&:\z]|;&=NP3AhB!B_bi^]Pfkw User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux) Cancel-Lock: sha1:CrihMz2F/jj0cR4dzp/HhmrhPDk= Original-Lines: 24 Original-NNTP-Posting-Date: 25 Sep 2006 08:55:17 CEST Original-NNTP-Posting-Host: 29fed084.newsspool3.arcor-online.net Original-X-Trace: DXC=OVd=PS60`TEI7\_^6>c20JMcF=Q^Z^V3H4Fo<]lROoRA4nDHegD_]REhG0[5oA8>AOCV`H8_`hhQD^9QSCVg3dOFlR6Na@UfK Original-X-Complaints-To: usenet-abuse@arcor.de Original-Xref: shelby.stanford.edu gnu.emacs.help:141980 Original-To: help-gnu-emacs@gnu.org X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:37601 Archived-At: "s. keeling" writes: > Hi. I was trying to make it easy on myself using q-r-r replacing > '[^\]\.' (not a backslash, followed by a literal dot/period) with the > string (sans quotes) '\.', essentially "escaping" every dot/period in > the file. "M-x query-replace" had no trouble with it but M-x > query-replace-regexp refused, spouting the error message in the > subject. > > So how do you replace '.' with '\.' in emacs? Googling's > (groups.google.com) turned up nothing useful (interesting, but not > useful). I tried variations of '\\\.' (literal backslash followed by > literal period) to no effect. > > Suggestions or pointers welcome. Thanks. M-x query-replace-regexp RET \. RET \\. RET . is not special in the replacement string. You can also write M-x query-replace-regexp RET \. RET \\\& RET -- David Kastrup, Kriemhildstr. 15, 44793 Bochum