NyQuest logo
HomeBanner 7 FAQTips & Tricksnavtab
menubar
Converting Files from Dos to Unix (dos2unix)

Older Banner® upgrades used edread to extract the files, however this program is only available on DOS systems, while most upgrades needed to be done on Unix Environments. This meant Banner® admins needed to extract files on a Dos box, then needed to ftp the files over the a unix system before actually applying each upgrade.

The problem here is that Unix and Dos use different values to represent the carriage character. Dos carriage returns show up as ^M in Unix.

The following script fixes this problem.

#!/bin/ksh
#
# begin dos2unix
#
# Usage: dos2unix [file]
cat $1 | tr -d "\015" > .tmp
mv .tmp $1
#
# end dos2unix



The contents of www.nyquest.com are Copyright © 2007 by Nyquest Consulting.
Sungard® and Banner® are registered trademarks of Sungard® Corporation.
Nyquest is not affiliated in any way with Sungard®.
All Rights Reserved.