Support » Fixing WordPress » WP 1.2.1 file format: Unix to PC?

  • I’m just curious…
    Is there any reason all the files in “wordpress-1.2.1.tar.gz” (released Oct 6, 2004) are now in the PC file format (carriage return/line feed at the end of each line) while all the files in the previous “wordpress-1.2.tar.gz mingus” were in the UNIX file format (line feed at the end of each line)?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Actually, many of the lines end with two carriage returns then a single line feed, 0x0d 0x0d 0x0a. There seem to be two reasons for this:

    1. The CVS checkin to WordPress-Ver-1_2-Branch with the comment “Copied over Matts 1.2.1 changesâ€? added extra carriage returns before each line feed. I’m guessing the files were checked out under Windows and checked in under Unix, and/or that a seriously broken CVS client was used for one or the other.
    2. The ZIP and TAR files for WordPress 1.2.1 were created under Windows, unlike WordPress 1.2 which was created under Unix. You can check this by downloading the previous ZIP file from SourceForge and using ‘zipinfo’.

    I ran a simple Perl command from the wordpress directory to fix the lines endings:

    perl -p -i -e 's/\x0d+$//' *.css */*.css *.html *.txt *.php */*.php */*/*.php

    (I also had to resurrect xmlrpc.php from WordPress 1.2.)

    In my Perl command above, everything from the first ampersand to the last semicolon, including those characters, should be a single backslash.

    I wish they’d re-release using the same line endings as 1.2. It’s impossible to diff changes I’ve made to the files with the bad line endings as the whole file looks like a diff.
    Any chance for a quick release with fixed line endings?
    — Frank

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘WP 1.2.1 file format: Unix to PC?’ is closed to new replies.