Re: DOS to Windows format tr/\n\r\t/ /

2007-02-13 Thread Dr.Ruud
[EMAIL PROTECTED] schreef:

> I had tried it.

What?

-- 
Affijn, Ruud

"Gewoon is een tijger."

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




Re: DOS to Windows format tr/\n\r\t/ /

2007-02-13 Thread vjp2

I had tried it. It gave me an error on the "use" line already.
It also doesn't like the "split".

I can dig up my GNU DJGPP CD and install version 5, but the problem is
v5 is an entire system, while v4 is just a one-file program, so there
are computers (not mine, heck those machines don't even allow java,
xome not even cookies) where I'll get all sorts of restrictions.  So
I'd kill portability.  The blessing of using old DOS stuff is you
don't have to wait two months to get permission to use them on a
machine you only plan on spending one hour.  You can even run DOS
commands from the URL box.
-- 
- = -
 Vasos Panagiotopoulos, Columbia'81+, Reagan, Mozart, Pindus, BioStrategist
   http://ourworld.compuserve.com/homepages/vjp2/vasos.htm
  ---{Nothing herein constitutes advice.  Everything fully disclaimed.}---
   [Homeland Security means private firearms not lazy obstructive guards]
 [Urb sprawl confounds terror] [Remorse begets zeal] [Windows is for Bimbos]

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




Re: DOS to Windows format tr/\n\r\t/ /

2007-02-12 Thread D. Bolliger
[EMAIL PROTECTED] am Montag, 12. Februar 2007 14:11:
> >I am not sure I understand the problem, but do you know the
> >Text::Wrap standard module in any case?
>
>  I used it on Unix, but I'm not sure it runs on my DOS version.

Sounds as if it might be worth trying. It won't hurt your box if it doesn't.

Dani

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




Re: DOS to Windows format tr/\n\r\t/ /

2007-02-12 Thread vjp2

>I am not sure I understand the problem, but do you know the
>Text::Wrap standard module in any case?

 I used it on Unix, but I'm not sure it runs on my DOS version.
So I found a one liner on the net. It works ALMOST right.
-- 
- = -
 Vasos Panagiotopoulos, Columbia'81+, Reagan, Mozart, Pindus, BioStrategist
   http://ourworld.compuserve.com/homepages/vjp2/vasos.htm
  ---{Nothing herein constitutes advice.  Everything fully disclaimed.}---
   [Homeland Security means private firearms not lazy obstructive guards]
 [Urb sprawl confounds terror] [Remorse begets zeal] [Windows is for Bimbos]

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




Re: DOS to Windows format tr/\n\r\t/ /

2007-02-11 Thread Xavier Noria

On Feb 11, 2007, at 9:39 PM, [EMAIL PROTECTED] wrote:


Well, here's my problem: I have found a way to wrap a text file down
to a narrower column width. But it looses paragraph formatting.   
What I need

is the same thing as converting a file from DOS (line break after each
line) to Windows (line break after each paragraph) format, no?


I am not sure I understand the problem, but do you know the  
Text::Wrap standard module in any case?


-- fxn




--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




Re: DOS to Windows format tr/\n\r\t/ /

2007-02-11 Thread vjp2
Well, here's my problem: I have found a way to wrap a text file down
to a narrower column width. But it looses paragraph formatting.  What I need
is the same thing as converting a file from DOS (line break after each
line) to Windows (line break after each paragraph) format, no?

>   From: [EMAIL PROTECTED] (Xavier Noria)
>On Feb 11, 2007, at 1:36 AM, [EMAIL PROTECTED] wrote:
>> I wonder if there is a format that preserves paragraph breaks while it
>> kills line breaks?
>How do you define a paragraph break. Why does the subject mentions
>DOS to Windows.
-- 
- = -
 Vasos Panagiotopoulos, Columbia'81+, Reagan, Mozart, Pindus, BioStrategist
   http://ourworld.compuserve.com/homepages/vjp2/vasos.htm
  ---{Nothing herein constitutes advice.  Everything fully disclaimed.}---
   [Homeland Security means private firearms not lazy obstructive guards]
 [Urb sprawl confounds terror] [Remorse begets zeal] [Windows is for Bimbos]

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




Re: DOS to Windows format tr/\n\r\t/ /

2007-02-11 Thread Xavier Noria

On Feb 11, 2007, at 1:36 AM, [EMAIL PROTECTED] wrote:


I wonder if there is a format that preserves paragraph breaks while it
kills line breaks?


How do you define a paragraph break. Why does the subject mentions  
DOS to Windows.


-- fxn




--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




DOS to Windows format tr/\n\r\t/ /

2007-02-11 Thread vjp2
I wonder if there is a format that preserves paragraph breaks while it
kills line breaks?



speach () { cat $1 | perl -n00e'tr/\t\r\n/ /s; print qq($1\n) while 
s/^(.{0,36}\S)\s+//;print qq(\n)' | perl -pe 'if ($.%4==2) {$_ .= qq(\n).(q(-) 
x 37).qq(\n)} elsif ($.%4==0) {$_ .= qq(\n).(q(=) x 37).qq(\n)} else {$_ .= 
qq(\n)}' ;}



-- 
- = -
 Vasos Panagiotopoulos, Columbia'81+, Reagan, Mozart, Pindus, BioStrategist
   http://ourworld.compuserve.com/homepages/vjp2/vasos.htm
  ---{Nothing herein constitutes advice.  Everything fully disclaimed.}---
   [Homeland Security means private firearms not lazy obstructive guards]
 [Urb sprawl confounds terror] [Remorse begets zeal] [Windows is for Bimbos]

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/