Massive property update - PLEASE READ
At this very moment I am committing a bunch of changes to properties. Unfortunately it's going to come across as... wow, 39 commits (assuming there are changes in every category, which there probably are). That's because I'm committing once per category because of issues I had trying to commit the entire thing at once. In any case, here's the change log: Massive update to svn properties on files: All patchfiles have svn:eol-style removed. All files that are not in fact able to be executed have svn:executable removed All binary files have svn:eol-style removed (and are probably corrupt) All binary files have svn:mime-type set to application/octet-stream All files which are not patchfiles or binary files have svn:eol-style set to native All Portfiles have svn:eol-style set to native and svn:executable removed In the future, please try and use the right properties. svn:eol-style native belongs on files which are line-ending-agnostic, like text files, shell scripts, tcl scripts, and other source files. Patchfiles must *NOT* have svn:eol-style set, as line endings are important in them. Additionally, be careful about svn:executable - there were some patch files with that set. Only set it if your file really needs to be executable. There are still a bunch of svn:executable shell scripts, but not all of them need it (most of them, for example, are passed as an argument to bash). I didn't bother removing it from scripts, but I did remove it from the patchfiles. Oh, and when adding patches, please don't create a folder structure like you can find in lang/gwydion-dylan/files. If you need to specify path, do something like patch-dir_dir2_dir3_filename. All patchfiles should be at the top level of the files/ folder. Oh, and this is a biggie. There are a handful of binary files in there that had svn:eol-style set. They are probably corrupt. I looked at 2 of them (both pngs) and those 2 definitely were corrupt, but I haven't checked any of the others. I don't know if there's any possibility of recovering these files, it depends on if the svn history has a copy of them before svn:eol-style was applied. When adding a binary file to the repository, make sure it does *NOT* have svn:eol-style set, and please do set svn:mime-type to application/ octet-stream (or you can use a more specific mime type if you know it). Speaking of mime types, when adding non-binary files I would recommend against setting the mime type. If you must, go with text/ plain. Setting something like e.g. application/x-tcl on a Portfile will probably prevent svn from display linewise diffs (svn is documented as treating all non-text/* mime types as binary, with known exceptions, but it doesn't list what the exceptions are). -Kevin Ballard -- Kevin Ballard http://kevin.sb.org eridius@macports.org http://www.tildesoft.com
Kevin Ballard <eridius@macports.org> on Thursday, January 25, 2007 at 6:54 PM -0800 wrote:
In the future, please try and use the right properties. svn:eol-style native belongs on files which are line-ending-agnostic, like text files, shell scripts, tcl scripts, and other source files. Patchfiles must *NOT* have svn:eol-style set, as line endings are important in them. Additionally, be careful about svn:executable - there were some patch files with that set. Only set it if your file really needs to be executable. There are still a bunch of svn:executable shell scripts, but not all of them need it (most of them, for example, are passed as an argument to bash). I didn't bother removing it from scripts, but I did remove it from the patchfiles.
Please explain how I can follow your recommendations, or documents I can read to understand this issue. I am totally unfamiliar with this issue and so I won't be able to follow these guidelines. Mark
On Jan 25, 2007, at 10:04 PM, Mark Duling wrote:
Kevin Ballard <eridius@macports.org> on Thursday, January 25, 2007 at 6:54 PM -0800 wrote:
In the future, please try and use the right properties. svn:eol-style native belongs on files which are line-ending-agnostic, like text files, shell scripts, tcl scripts, and other source files. Patchfiles must *NOT* have svn:eol-style set, as line endings are important in them. Additionally, be careful about svn:executable - there were some patch files with that set. Only set it if your file really needs to be executable. There are still a bunch of svn:executable shell scripts, but not all of them need it (most of them, for example, are passed as an argument to bash). I didn't bother removing it from scripts, but I did remove it from the patchfiles.
Please explain how I can follow your recommendations, or documents I can read to understand this issue. I am totally unfamiliar with this issue and so I won't be able to follow these guidelines.
If you create a new Portfile, you should set svn:eol-style to native on it (`svn propset svn:eol-style native Portfile`). If you add any patches to the repository, don't set any properties on them. If you add files which aren't patches or Portfiles.. is the file a binary file? if yes, set svn:mime-type to application/octet-stream if no, do the line endings matter? if they don't, set svn:eol- style to native If you don't want to worry about properties, it's not a big deal if you set none of them, but if possible I'd like the repository to be consistent about this. If you want extra reading material about properties, try <http:// svnbook.red-bean.com/en/1.1/ch07s02.html>. HTH, Kevin Ballard -- Kevin Ballard http://kevin.sb.org kevin@sb.org http://www.tildesoft.com -- Kevin Ballard http://kevin.sb.org eridius@macports.org http://www.tildesoft.com
Ok, turns out I wasn't paying enough attention. The "handful" of binary files were actually all the binary files, whether or not they had svn:eol-style set. It turns out that the 2 image files I looked at were the only files that actually had it set ;) In any case, avoid doing this in the future. Those 2 image files are irreparable. On Jan 25, 2007, at 9:54 PM, Kevin Ballard wrote:
Oh, and this is a biggie. There are a handful of binary files in there that had svn:eol-style set. They are probably corrupt. I looked at 2 of them (both pngs) and those 2 definitely were corrupt, but I haven't checked any of the others. I don't know if there's any possibility of recovering these files, it depends on if the svn history has a copy of them before svn:eol-style was applied. When adding a binary file to the repository, make sure it does *NOT* have svn:eol-style set, and please do set svn:mime-type to application/octet-stream (or you can use a more specific mime type if you know it).
-- Kevin Ballard http://kevin.sb.org eridius@macports.org http://www.tildesoft.com
Suggest I Twiki entry about this in big letters right near how add a new port. -- Sal smile. -------------- Salvatore Domenick Desiano Doctoral Candidate Robotics Institute Carnegie Mellon University On Thu, 25 Jan 2007, Kevin Ballard wrote: o Ok, turns out I wasn't paying enough attention. The "handful" of binary files o were actually all the binary files, whether or not they had svn:eol-style set. o It turns out that the 2 image files I looked at were the only files that o actually had it set ;) o o In any case, avoid doing this in the future. Those 2 image files are o irreparable. o o On Jan 25, 2007, at 9:54 PM, Kevin Ballard wrote: o o > Oh, and this is a biggie. There are a handful of binary files in there that o > had svn:eol-style set. They are probably corrupt. I looked at 2 of them o > (both pngs) and those 2 definitely were corrupt, but I haven't checked any o > of the others. I don't know if there's any possibility of recovering these o > files, it depends on if the svn history has a copy of them before o > svn:eol-style was applied. When adding a binary file to the repository, make o > sure it does *NOT* have svn:eol-style set, and please do set svn:mime-type o > to application/octet-stream (or you can use a more specific mime type if you o > know it). o o -- o Kevin Ballard o http://kevin.sb.org o eridius@macports.org o http://www.tildesoft.com o o
Kevin Ballard <eridius@macports.org> on Thursday, January 25, 2007 at 7:10 PM -0800 wrote:
If you create a new Portfile, you should set svn:eol-style to native on it (`svn propset svn:eol-style native Portfile`).
If you add any patches to the repository, don't set any properties on them.
If you add files which aren't patches or Portfiles..
is the file a binary file? if yes, set svn:mime-type to application/octet-stream if no, do the line endings matter? if they don't, set svn:eol-style to native
If you don't want to worry about properties, it's not a big deal if you set none of them, but if possible I'd like the repository to be consistent about this.
If you want extra reading material about properties, try <[ http://svnbook.red-bean.com/en/1.1/ch07s02.html ]http://svnbook.red-bean.com/en/1.1/ch07s02.html>.
Ok, I see. Thanks for stating it very clearly. I'll see if I can add this to the Wiki. Mark
On Jan 25, 2007, at 20:54, Kevin Ballard wrote:
At this very moment I am committing a bunch of changes to properties. Unfortunately it's going to come across as... wow, 39 commits (assuming there are changes in every category, which there probably are). That's because I'm committing once per category because of issues I had trying to commit the entire thing at once.
In any case, here's the change log:
Massive update to svn properties on files: All patchfiles have svn:eol-style removed. All files that are not in fact able to be executed have svn:executable removed All binary files have svn:eol-style removed (and are probably corrupt) All binary files have svn:mime-type set to application/octet-stream All files which are not patchfiles or binary files have svn:eol- style set to native All Portfiles have svn:eol-style set to native and svn:executable removed
In the future, please try and use the right properties. svn:eol- style native belongs on files which are line-ending-agnostic, like text files, shell scripts, tcl scripts, and other source files. Patchfiles must *NOT* have svn:eol-style set, as line endings are important in them. Additionally, be careful about svn:executable - there were some patch files with that set. Only set it if your file really needs to be executable. There are still a bunch of svn:executable shell scripts, but not all of them need it (most of them, for example, are passed as an argument to bash). I didn't bother removing it from scripts, but I did remove it from the patchfiles.
Oh, and when adding patches, please don't create a folder structure like you can find in lang/gwydion-dylan/files. If you need to specify path, do something like patch-dir_dir2_dir3_filename. All patchfiles should be at the top level of the files/ folder.
Oh, and this is a biggie. There are a handful of binary files in there that had svn:eol-style set. They are probably corrupt. I looked at 2 of them (both pngs) and those 2 definitely were corrupt, but I haven't checked any of the others. I don't know if there's any possibility of recovering these files, it depends on if the svn history has a copy of them before svn:eol-style was applied. When adding a binary file to the repository, make sure it does *NOT* have svn:eol-style set, and please do set svn:mime-type to application/octet-stream (or you can use a more specific mime type if you know it).
Speaking of mime types, when adding non-binary files I would recommend against setting the mime type. If you must, go with text/ plain. Setting something like e.g. application/x-tcl on a Portfile will probably prevent svn from display linewise diffs (svn is documented as treating all non-text/* mime types as binary, with known exceptions, but it doesn't list what the exceptions are).
If these are the rules (and I think I agree that they should be), then the repository needs a pre-commit hook that will reject any commits that do not obey these rules. Would you like me to write one?
On Jan 25, 2007, at 21:10, Kevin Ballard wrote:
If you create a new Portfile, you should set svn:eol-style to native on it (`svn propset svn:eol-style native Portfile`).
If you add any patches to the repository, don't set any properties on them.
If you add files which aren't patches or Portfiles..
is the file a binary file? if yes, set svn:mime-type to application/octet-stream if no, do the line endings matter? if they don't, set svn:eol- style to native
If you don't want to worry about properties, it's not a big deal if you set none of them, but if possible I'd like the repository to be consistent about this.
The committer must also ensure that they have not already set up Subversion auto-props definitions which conflict with these guidelines, or must remember to undo what their auto-props did before committing. For example, I cannot imagine anyone deliberately setting svn:eol-style on PNG images before committing, but I can very well imagine someone inadvertently configuring an auto-props rule which sets svn:eol-style on all files (à la "* = svn:eol-style=native").
That might be a good idea. On Jan 26, 2007, at 3:05 AM, Ryan Schmidt wrote:
If these are the rules (and I think I agree that they should be), then the repository needs a pre-commit hook that will reject any commits that do not obey these rules. Would you like me to write one?
-- Kevin Ballard http://kevin.sb.org eridius@macports.org http://www.tildesoft.com
participants (4)
-
Kevin Ballard
-
Mark Duling
-
Ryan Schmidt
-
Salvatore Domenick Desiano