Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 11 Jul 2001 13:50:12 -0400
From:      Louis LeBlanc <leblanc+freebsd@acadia.ne.mediaone.net>
To:        questions@FreeBSD.ORG, freebsd-questions@FreeBSD.org
Subject:   Re: Removing the "^M" s from files created on Windows machines
Message-ID:  <20010711135010.B2041@acadia.ne.mediaone.net>
In-Reply-To: <qnuoktg6cfq356r97sgbhs5q8lh5rtjaqi@4ax.com>
References:  <911D8F660DF6D411B61F00500462BA01BE5DBA@exchange.twowaytv.co.uk> <qnuoktg6cfq356r97sgbhs5q8lh5rtjaqi@4ax.com>

next in thread | previous in thread | raw e-mail | index | archive | help

--k+w/mQv8wyuph6w0
Content-Type: text/plain; charset=iso-8859-1
Content-Disposition: inline
Content-Transfer-Encoding: 8bit

You could just whack out a quick C filter to change all instances of
'\r\n\' to '\n'.  If I remember correctly, there is a way in (g)vim to
apply filters to text on the fly.  I don't know about adding it in a
dropdown, but there may be a way.

Just for the hell of it, here is just such a filter I wrote a year or
so ago.  Don't ask for support if you want to use it, I am hereby
releasing it on an OPEN licence, meaning you can do any damn thing you
want with it, except hack the nsa :)

There is a script that basically just executes the gcc commands, I
didn't bother to build up a legit makefile.  This builds fine on
Linux, but I never tried it on FreeBSD.  Maybe if someone wants to put
it together right, it can get added to the ports as a file tool?

HTH
Lou
On 07/11/01 05:20 PM, John Murphy sat at the `puter and typed:
> Alex Dyas <ADyas@twowaytv.com> wrote:
> >:%s/[CTRL-V][CTRL-M]//g
> 
> Tim McCullagh wrote:
> >:%s/^V^M//
> 
> Dru <genisis@istar.ca> wrote:
> >Or a third way of doing it:
> >
> >:%! col -bx
> 
> I've just started using gvim.
> How could I have this function available in one of the drop down menus?
> 
> Thanks
> John.
> 
> To Unsubscribe: send mail to majordomo@FreeBSD.org
> with "unsubscribe freebsd-questions" in the body of the message
> 

-- 
Louis LeBlanc
Fully Funded Hobbyist, KeySlapper Extrordinaire :)
leblanc@acadia.ne.mediaone.net
http://acadia.ne.mediaone.net                ԿԬ

--k+w/mQv8wyuph6w0
Content-Type: application/octet-stream
Content-Disposition: attachment; filename="rmcr.tgz"
Content-Transfer-Encoding: base64

H4sIAOKQTDsAA+1XbU/jRhDms3/FHO0JJ5cEO4mJSjg+nHpIV9F+6AlVKkTIsddhhb1rrdcE
VPHfO/uSxIYA114T7lQPSN7MztvuPGs/K7JI7O9sVjxv6I2CAJ+e5x8cmOdwqJ9WdrzRoO95
B/6oj3rfHwyDHQg2XJeWspChANhJyTQNWfSMHRHFNgrargjV/zCOI9F7eu1fKZ6PCLD9XtP/
QdD3sf9eEHj94UBhwe8HwXAHvE0VVJX/ef/32wC/0kjwH3kiQZJbCRHP8lDSKU2pvAPJeQpd
MBBxoI3/AP4AfgkZ4In1AE55SQs4JR/U/i0spiVNY5hTeQXyikDC05TPKZsd6tlZFEF3Bt0/
whSDRzY66rgdcm1WSEFz6H5eKMGIWzJGIlIUobjrYCYJVEIWXpMCQigyjEkEkFsSlTKcpqS1
SmnDQyXLvuP8QFmUljGBo0LGlPeujiuqklHU1nWoSOm0rovkXU6UylGDmCQA0RUi68PZycnH
38/x8fnTn5Oxo5VK2u0ivCGXoZjdjB3nhtMYyiKcEbfl/OUAJLmgTCYu5iJCdGD3TE0ewtsC
jhKakuPFo6f/zgWZXZLbfHLBdjuwjHzuTVpjjEZuqXR9HN47DobF3aLMVQM0ijqm0rZ2mJj0
pmxdKJ6PGZGXXNDZGCqyvw8szAjwBNQcZWGK2MnvemvdZZbXvKvukmQ5F9jNZ/yn4fWT/tMw
ui7zpfPJp9OPxqadPM67dCZzg3e1jQ+91ILgPfx2dno6rnkhJEmY4akAfMY2gOBZz1lVTdm0
TB4Vi7oEcZlwoXHNZmiXI3ZDFkMuuMIzKlX9qi/YFKYaZzqDvpe5FFjRKjaGxHdSrEqx7jZu
0Vv64dZZv9VKnvNDxyV00MliE33a6q2QqVJTyoiaKDPCZHEIBoaqE8eQqTM5I3pHe+pogVqu
G2EofwwRHGm44ejdOzyUoHAGsKpxhdpootOi+6ITCc8Jc60tngaxq3GN9dpzUkEpTr8t8BRY
6/WGiAtt18PBS7aIPWOLg0e2GmLLCmvR56pIbUQTcN+YxbS0wqx9zTE/wb3Tp5xxRBYvWdzT
R7qeFBvMmaSsJOb3vUmDffq5xGrUK3fRjCmP7xSkuK0UB1MCcy6uEQScQRpKhKVuFsD8CtO7
kOAaChcs7Dpg3l6dRTta8MYgCuqLYaqJUiAcXOu6LNcEpkWRhxFx1aunZU3OWdeftFqLZOfd
LptgHG/8YIeSZcsuhN6Regq7A0mU8oK4dqvHdR0GWDREaMjWUbPqtnWsG+n0FQdtpNMKIkvB
VMn3zmt/0P+haP4XCfWVL3rqG7qBHIr/Bc/w/8FwoPnfKBj2D4YjtB+MvIOG/21DvoCJPWRh
znoq9TCSQpYJpEeVOPa3DaN+QU1XD4Lvk1Uc/aMeyqpW0ZQCKjOvvcXftOjzb1q1sRwv3v/8
UeX+56v73zDwmvO/DWnuf839r7n/Nfe/5v7X3P/ge7n/Nbe//0wW/M+w7M3keIn/jfx+hf/1
1f3PHzX8byvybfC/J655NQ64VNtP6tewwDW3xK0xwaH300HDA9e6NzzwEQ+knfVU0G+4YMMF
X4EL+h3AF1jwL6ig/wVc0H9ABv0KG1xsEp4bl2oVUEQRw4eBUDW92eVlFIox3sPehdhrLQ0A
atM4y/YWFd4/yT1XzNNvqGcjjTTyXcvftRCbDAAoAAA=

--k+w/mQv8wyuph6w0--

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20010711135010.B2041>