Saturday, 5 February 2011

end-of-line character conversion: unix2mac dos2unix mac2unix

All these scripts are one liners:


"mac2unix"
cat $1 | tr '\r' '\n'

"unix2mac"
cat $1 | tr '\n' '\r'

"dos2unix"
cat $1 | tr -d '\r'

NOTE: "tr" (translate character) utility.

No comments:

Post a Comment

Executive Summary: Anthropic's Claude Mythos Model

  What Happened Anthropic announced  Claude Mythos Preview , a new AI model it describes as its most capable ever — and so powerful in cyber...