sbc_compliant: (Default)
[personal profile] sbc_compliant
tr '\015' '\012' < acl-update.txt > vi-happy-output.txt

My uber-geek friend just explained, after looking at a hex dump of the original file, that there are dos style line feeds (ASCII 13 or \015 or 0x0d), that should have been translated into (ACSII 10, \012 or 0x0a). TextWrangler and TextEdit are smart enough to do this automagically, but vi needs a hand. Hence the tr command above.

Now I need to learn more about tr and the magical world of hex dumps.

Cool!

Date: 2006-04-19 11:20 pm (UTC)
From: [identity profile] manlym1k3.livejournal.com
Or you could just run dos2unix on the file.

Date: 2006-04-19 11:26 pm (UTC)
From: [identity profile] sbc-compliant.livejournal.com
for some odd reason, the dos2unix, that I downloaded from www.osxgnu.org, was only rming the ^M and leaving the file as one long line.

Mind you, I still haven't ruled out PEBKAC, but as least I have a working solution, now.

Profile

sbc_compliant: (Default)
sbc_compliant

November 2019

S M T W T F S
     12
3456789
10111213141516
17181920212223
24252627282930

Most Popular Tags

Style Credit

Expand Cut Tags

No cut tags
Page generated Feb. 10th, 2026 10:05 pm
Powered by Dreamwidth Studios