Make an unix file in windows

This is a discussion on Make an unix file in windows within the A Brief History of Cprogramming.com forums, part of the Community Boards category; Hi, I've got a program in ansi C that I can compile with DJGPP in my PC windows XP to ...

  1. #1
    Registered User
    Join Date
    Sep 2003
    Posts
    5

    Make an unix file in windows

    Hi,

    I've got a program in ansi C that I can compile with DJGPP in my PC windows XP to dos format.
    Meanwhile, someone told me that there is a way of converting, in an automatic way, a file in dos to unix format using something called dos2unix.

    Does anyone knows anything about this?


    Best regards,

  2. #2
    and the hat of wrongness Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    32,659
    Yeah, you type

    man dos2unix

    on your unix box
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.
    I support http://www.ukip.org/ as the first necessary step to a free Europe.

  3. #3
    Registered User
    Join Date
    Nov 2002
    Posts
    46
    Just curious, what is the difference? CRLF in dos as opposed to CR in unix?
    mooooo@cooowwww.com

  4. #4
    End Of Line Hammer's Avatar
    Join Date
    Apr 2002
    Posts
    6,231
    Originally posted by thedumbmutt
    Just curious, what is the difference? CRLF in dos as opposed to CR in unix?
    They're end of line markers.

    CRLF (carriage return/line feed) for Windows.
    LF for Unix.
    When all else fails, read the instructions.
    If you're posting code, use code tags: [code] /* insert code here */ [/code]

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. opening empty file causes access violation
    By trevordunstan in forum C Programming
    Replies: 10
    Last Post: 10-21-2008, 11:19 PM
  2. help with text input
    By Alphawaves in forum C Programming
    Replies: 8
    Last Post: 04-08-2007, 04:54 PM
  3. how to make a windows application
    By crvenkapa in forum C++ Programming
    Replies: 3
    Last Post: 03-26-2007, 09:59 AM
  4. C++ std routines
    By siavoshkc in forum C++ Programming
    Replies: 33
    Last Post: 07-28-2006, 12:13 AM
  5. Simple File encryption
    By caroundw5h in forum C Programming
    Replies: 2
    Last Post: 10-13-2004, 10:51 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21