Date: Fri, 23 Oct 2015 03:35:27 +0000 (UTC) From: Hiroki Sato <hrs@FreeBSD.org> To: doc-committers@freebsd.org, svn-doc-all@freebsd.org, svn-doc-svnadmin@freebsd.org Subject: svn commit: r47643 - in svnadmin/hooks: . scripts Message-ID: <201510230335.t9N3ZRLS086592@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: hrs Date: Fri Oct 23 03:35:26 2015 New Revision: 47643 URL: https://svnweb.freebsd.org/changeset/doc/47643 Log: Add text/troff to the list of allowed binary files. Approved by: doceng (implicit) Modified: svnadmin/hooks/pre-commit svnadmin/hooks/scripts/verify.py Modified: svnadmin/hooks/pre-commit ============================================================================== --- svnadmin/hooks/pre-commit Thu Oct 22 21:23:02 2015 (r47642) +++ svnadmin/hooks/pre-commit Fri Oct 23 03:35:26 2015 (r47643) @@ -78,7 +78,8 @@ sizelimit.py "$REPO" "$TXN" 1024000 || e # POLICY: mime-type must be unset, text/*, application/* or image/* # POLICY: if a file does has fbsd:nokeywords, then svn:keywords must not be set # POLICY: if a file has binary chars and no fbsd:notbinary, then pretend its not binary -# POLICY: if a file is binary, then it must have mime application/* or image/* +# POLICY: if a file is binary, then it must have mime application/*, image/*, +# or text/{sgml,xml,troff}. # POLICY: if a file does not have fbsd:nokeywords, or is binary then svn:keywords must be set # POLICY: if svn:keywords is set, $ FreeBSD $ must be present and condensed. # POLICY: If a file has text/*, then it must have eol-style Modified: svnadmin/hooks/scripts/verify.py ============================================================================== --- svnadmin/hooks/scripts/verify.py Thu Oct 22 21:23:02 2015 (r47642) +++ svnadmin/hooks/scripts/verify.py Fri Oct 23 03:35:26 2015 (r47643) @@ -13,7 +13,8 @@ from svn import core, fs, delta, repos # POLICY: mime-type must be unset, text/*, application/* or image/* # POLICY: if a file does has fbsd:nokeywords, then svn:keywords must not be set # POLICY: if a file has binary chars and no fbsd:notbinary, then pretend its not binary -# POLICY: if a file is binary, then it must have mime application/* or image/* +# POLICY: if a file is binary, then it must have mime application/*, image/*, +# or text/{sgml,xml,troff}. # POLICY: if a file does not have fbsd:nokeywords, or is binary then svn:keywords must be set # POLICY: if svn:keywords is set, $ FreeBSD $ must be present and condensed. @@ -186,7 +187,7 @@ class ChangeReceiver(delta.Editor): # POLICY: if a file is binary, then it must have mime application/* or image/* if binary: - if not mimetype.startswith('application/') and not mimetype.startswith('image/') and not mimetype.startswith('text/sgml') and not mimetype.startswith('text/html') and not mimetype.startswith('text/xml'): + if not mimetype.startswith('application/') and not mimetype.startswith('image/') and not mimetype.startswith('text/sgml') and not mimetype.startswith('text/html') and not mimetype.startswith('text/xml') and not mimetype.startswith('text/troff'): self.do_fail('Path "%s" contains binary but has svn:mime-type "%s"\n' % (path, mimetype)) sys.stderr.write('Try application/* (application/octet-stream) or image/* instead.\n')
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201510230335.t9N3ZRLS086592>