Saturday, 12 November 2011

How to change file type in CVS

When working with CVS there might be times where files get added in the wrong format (binary or ascii). To convert between these two there are a couple of commands you can use.

  • Convert from binary to ascii
    • Using CVSNT
      Remove all files and then execute in a shell:
      cvs update -ktkv <FILES>
      cvs commit -fm "Changed format to ascii" <FILES>
    • Using CVS
      cvs admin -kkv <FILES>
      cvs update -A <FILES>
      cvs commit -fm "Changed format to ascii" <FILES>
  • Convert from ascii to binary
    • Using CVSNT
      Remove all files and then execute in a shell:
      cvs update -kb <FILES>
      cvs commit -fm "Changed format to binary" <FILES>
    • Using CVS
      cvs admin -kb <FILES>
      cvs update -A <FILES>
      cvs commit -fm "Changed format to binary" <FILES>

1 comment:

  1. Wow, thank y for sharing, it's very useful.
    Keep going with your blog.
    security online

    ReplyDelete