For Programmers: Free Programming Magazines  


Home > Archive > PERL Programming > April 2004 > Re: Stick Lines Between Text









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Re: Stick Lines Between Text
vjp2.at@at.BioStrategist.dot.dot.com

2004-04-09, 1:30 am

*+-I want to take a text file less than 80 chars across
*+-and break each line in two at the space neared the middle
*+-(I can use fold if the batch editor can't)

*+-Then I want to make it double spaced.

*+-Every second blank (fourth of the total) line should then
*+-be replace with a line of "-" characters..

*+-and then every second dashed line (every fourth blank aka every eighth
*+-actual) should be replace wit a line of "+" characters..

*+-anyone have any good ways to do this?

*+-I prefer SED but I'd take PERL or AWK

*+-pls cc email


- = -
Vasos-Peter John Panagiotopoulos II, Columbia'81+, Bio$trategist
BachMozart ReaganQuayle EvrytanoKastorian
http://ourworld.compuserve.com/homepages/vjp2/vasos.htm
---{Nothing herein constitutes advice. Everything fully disclaimed.}---
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com