[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[no subject]
- <!--x-content-type: text/plain -->
- <!--x-date: Thu May 6 16:00:31 2004 -->
- <!--x-from-r13: wfurrgf ng lnubb.pbz (Xrenyq Eurrgf) -->
- <!--x-message-id: 000601c433a4$98845900$0500a8c0@wagon -->
- <!--x-reference: [email protected] --> "http://www.w3.org/TR/html4/loose.dtd">
- <!--x-subject: [ale] VI question -->
- <li><em>date</em>: Thu May 6 16:00:31 2004</li>
- <li><em>from</em>: jsheets at yahoo.com (Jerald Sheets)</li>
- <li><em>in-reply-to</em>: <<a href="msg00215.html">[email protected]</a>></li>
- <li><em>subject</em>: [ale] VI question</li>
------------------%<snip>%----------------------
Joining Lines
Since vi does not use automatic word wrap, it is not unusual in editing
lines to end up with lines that are too short and that might be improved
if joined together. To do this, place your cursor on the first line to
be joined and type J. As with other commands, you can precede J with a
number to join multiple lines (4J joins 4 lines).
------------------%<snip>%----------------------
So then, cursoring to the first line and typing "500J" in the command
mode should do ya. Now, if it's random throughout the file, you'll need
your %s thingie, though.
--jms
-----Original Message-----
From: ale-bounces at ale.org [<a rel="nofollow" href="mailto:ale-bounces">mailto:ale-bounces</a> at ale.org] On Behalf Of
Robert L. Harris
Sent: Thursday, May 06, 2004 3:54 PM
To: Atlanta Linux Enthusiasts
Subject: [ale] VI question
Ok, the problem is long solved using perl but how the heck can you use
":%s" to join multiple lines? Yes, it can be done with "J" but we
wanted to join about 500 lines and I've done it with a substitution
before but can't remember how.
Anyone know?
:wq!
------------------------------------------------------------------------
---
Robert L. Harris | GPG Key ID: E344DA3B
@ x-hkp://pgp.mit.edu
DISCLAIMER:
These are MY OPINIONS ALONE. I speak for no-one else.
With Dreams To Be A King First One Should Be A Man
- Manowar
---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (<a rel="nofollow" href="http://www.grisoft.com">http://www.grisoft.com</a>).
Version: 6.0.676 / Virus Database: 438 - Release Date: 5/3/2004
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (<a rel="nofollow" href="http://www.grisoft.com">http://www.grisoft.com</a>).
Version: 6.0.676 / Virus Database: 438 - Release Date: 5/3/2004
</pre>
<!--X-Body-of-Message-End-->
<!--X-MsgBody-End-->
<!--X-Follow-Ups-->
<hr>
<!--X-Follow-Ups-End-->
<!--X-References-->
<ul><li><strong>References</strong>:
<ul>
<li><strong><a name="00215" href="msg00215.html">[ale] VI question</a></strong>
<ul><li><em>From:</em> Robert.L.Harris at rdlg.net (Robert L. Harris)</li></ul></li>
</ul></li></ul>
<!--X-References-End-->
<!--X-BotPNI-->
<ul>
<li>Prev by Date:
<strong><a href="msg00216.html">[ale] VI question</a></strong>
</li>
<li>Next by Date:
<strong><a href="msg00218.html">[ale] Re: Suse 9.1 Pro posted to tux.org, please be considerate!!</a></strong>
</li>
<li>Previous by thread:
<strong><a href="msg00216.html">[ale] VI question</a></strong>
</li>
<li>Next by thread:
<strong><a href="msg00219.html">[ale] VI question</a></strong>
</li>
<li>Index(es):
<ul>
<li><a href="maillist.html#00217"><strong>Date</strong></a></li>
<li><a href="threads.html#00217"><strong>Thread</strong></a></li>
</ul>
</li>
</ul>
<!--X-BotPNI-End-->
<!--X-User-Footer-->
<!--X-User-Footer-End-->
</body>
</html>