svnbinary-datacorrupt-data

How can I mass-convert images saved as text/ascii in svn to binary?


Somehow images got saved as text/ascii and I need to recursively do this for hundreds of directories of images, all under one root images directory.

I got some instructions here which tell me to:

svn proplist <yourfile>
svn propdel svn:eol-style <yourfile>
svn propset svn:mime-type application/octet-stream <yourfile>

Is there some native svn recursive way I can do this? If not, could someone advise how I could recursively apply this with a bash script?


Solution

  • On the shell:

    find -name '*.png' -exec \
    sh -c "svn propdel svn:eol-style {} && svn propset svn:mime-type image/png {}" \;