We're a community of 1.1M IT Pros here for help, advice, solutions, professional growth and fun. Join us!
1,080,599 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Start New Discussion Reply to this Discussion

Small Script to convert CRLF to LF

I wrote this small script to convert all sh files in a directory and all sub-directories to resolve a compilation error I was getting with cygwin...

SETLOCAL
@echo off
:: Locate all sh files in the target directory and then
:: Convert CRLF to Unix Style LF
echo Converting Line Feed Carriage Returns to Unix Style Line Feeds...
echo Please Wait...
For /F "tokens=2 delims=:" %%A in ('Find %~dp0 -name "*.sh"') Do dos2unix %%A
echo.
echo Completed!
echo.
pause
1
Contributor
0
Replies
1
View
Satyrn
Newbie Poster
21 posts since Aug 2011
Reputation Points: 10
Solved Threads: 2
Skill Endorsements: 0

This article has been dead for over three months: Start a new discussion instead

Post: Markdown Syntax: Formatting Help
 
You
 
© 2013 DaniWeb® LLC
Page generated in 0.0485 seconds using 2.63MB