From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: shirish Newsgroups: gmane.emacs.help Subject: Regarding replacing regexp Date: Thu, 10 May 2012 15:07:40 +0530 Message-ID: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=e89a8f3ba95b262fdb04bfab60ec X-Trace: dough.gmane.org 1336666914 11386 80.91.229.3 (10 May 2012 16:21:54 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Thu, 10 May 2012 16:21:54 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu May 10 18:21:53 2012 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 1SSW7d-0003J9-WF for geh-help-gnu-emacs@m.gmane.org; Thu, 10 May 2012 18:21:46 +0200 Original-Received: from localhost ([::1]:32806 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SSW7d-0004Js-AW for geh-help-gnu-emacs@m.gmane.org; Thu, 10 May 2012 12:21:45 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:55151) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SSPp4-0001sA-1p for help-gnu-emacs@gnu.org; Thu, 10 May 2012 05:38:15 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SSPox-0000RR-Mf for help-gnu-emacs@gnu.org; Thu, 10 May 2012 05:38:09 -0400 Original-Received: from mail-yw0-f41.google.com ([209.85.213.41]:60090) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SSPox-0000Qw-Fx for help-gnu-emacs@gnu.org; Thu, 10 May 2012 05:38:03 -0400 Original-Received: by yhr47 with SMTP id 47so1550095yhr.0 for ; Thu, 10 May 2012 02:38:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:from:date:message-id:subject:to:content-type; bh=+zDiPC+GrZBXhfI96N59IsBFNP5DmCc2S1pc9uTO0TE=; b=hv4yphiHVYPHaYNocUdpVyXFDhh4VQqTC2tHs47QbCqMkDEaNdaiHt4X+1Ab0yMgpI xXfUR40qQtw60lmzZtiNlsbEpi5fz4YCKZXr6h4dB3Eqfh9kJQZcqJjenCGWbuAdbCzu YRXkLCm0Py8gzQ2QaZ1LeNENL3ekv4wRGM8KqjeAfrAyDEXjyjijX2n3lje0AnoerNdU dXFOVKOkCZ9MxS5FMviP1prb7PtwD0HQzfIfXl8pfXMGBsRnZxeB6cwFZQJ9LSqA4znv AQTTQkEAzLRHT+hvWRRv9jfDxeWOFgsS58ZTrGIR4mGW2r3ZOcwvMrP4W/gBCCmuEGfw enDg== Original-Received: by 10.50.77.138 with SMTP id s10mr1835027igw.48.1336642680270; Thu, 10 May 2012 02:38:00 -0700 (PDT) Original-Received: by 10.231.36.203 with HTTP; Thu, 10 May 2012 02:37:40 -0700 (PDT) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 209.85.213.41 X-Mailman-Approved-At: Thu, 10 May 2012 12:21:41 -0400 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:84798 Archived-At: --e89a8f3ba95b262fdb04bfab60ec Content-Type: text/plain; charset=ISO-8859-1 Hi, I am in the process of learning how to use emacs. I know about the replace-regexp but I am unable to create a regular expression to do the below. Any help is much appreciated. public static final String SUCCESS //Successmesg public static final String FAILURE //failuremessage I need to replace that with public static final String SUCCESS = "SUCCESS";//Successmesg public static final String FAILURE = "FAILURE"; //failuremessage Thanks, Shirish. --e89a8f3ba95b262fdb04bfab60ec Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
Hi,=A0

I a= m in the process of learning how to use emacs. I know about the replace-reg= exp but I am unable to create a regular expression to do the below.
Any help is much appreciated.=A0

public static fin= al String SUCCESS //Successmesg
public static final String FAILUR= E =A0//failuremessage

I need to replace that with= =A0

public static final String SUCCESS =3D "SUCCE= SS";//Successmesg
public static final String FAILURE =A0=3D = "FAILURE"; //failuremessage

Thanks,
Shirish.


=
--e89a8f3ba95b262fdb04bfab60ec--