Rev 3627: (robertc) Disable reading .bzrrules from the working tree. in file:///home/pqm/archives/thelove/bzr/%2Btrunk/

Canonical.com Patch Queue Manager pqm at pqm.ubuntu.com
Thu Aug 14 04:53:31 BST 2008


At file:///home/pqm/archives/thelove/bzr/%2Btrunk/

------------------------------------------------------------
revno: 3627
revision-id: pqm at pqm.ubuntu.com-20080814035325-ikgddts7pv17l23e
parent: pqm at pqm.ubuntu.com-20080814032324-mhfk4rggo7hgxeuf
parent: john at arbash-meinel.com-20080814030842-fuc2xackfdyatf42
committer: Canonical.com Patch Queue Manager <pqm at pqm.ubuntu.com>
branch nick: +trunk
timestamp: Thu 2008-08-14 04:53:25 +0100
message:
  (robertc) Disable reading .bzrrules from the working tree.
modified:
  bzrlib/help_topics/en/rules.txt rules.txt-20080516063844-ghr5l6pvvrhiycun-1
  bzrlib/tests/tree_implementations/test_iter_search_rules.py test_iter_search_rul-20080528065532-1ml1ttb12az20cxf-1
  bzrlib/tree.py                 tree.py-20050309040759-9d5f2496be663e77
  doc/en/user-guide/configuring_bazaar.txt configuring_bazaar.t-20071128000722-ncxiua259xwbdbg7-1
    ------------------------------------------------------------
    revno: 3606.2.5
    revision-id: john at arbash-meinel.com-20080814030842-fuc2xackfdyatf42
    parent: pqm at pqm.ubuntu.com-20080813185456-kn2cq6pkj6h52z9k
    author: Robert Collins <robertc at robertcollins.net>
    committer: John Arbash Meinel <john at arbash-meinel.com>
    branch nick: jam-integration
    timestamp: Wed 2008-08-13 22:08:42 -0500
    message:
      Cherry pick Robert's 'disable .bzrrules in-tree' patch
    modified:
      bzrlib/help_topics/en/rules.txt rules.txt-20080516063844-ghr5l6pvvrhiycun-1
      bzrlib/tests/tree_implementations/test_iter_search_rules.py test_iter_search_rul-20080528065532-1ml1ttb12az20cxf-1
      bzrlib/tree.py                 tree.py-20050309040759-9d5f2496be663e77
      doc/en/user-guide/configuring_bazaar.txt configuring_bazaar.t-20071128000722-ncxiua259xwbdbg7-1
=== modified file 'bzrlib/help_topics/en/rules.txt'
--- a/bzrlib/help_topics/en/rules.txt	2008-07-02 01:40:02 +0000
+++ b/bzrlib/help_topics/en/rules.txt	2008-08-14 03:08:42 +0000
@@ -21,11 +21,8 @@
 Files
 -----
 
-Branch-specific rules are defined in ``.bzrrules`` in the root of the
-working tree. Default rules for all branches are defined in
-``BZR_HOME/rules``. Either or both files may be missing. If a rule is
-matched by a pattern in the branch level file, searching stops.
-
+Default rules for all branches are defined in the optional file
+``BZR_HOME/rules``. 
 
 Rule Patterns
 -------------

=== modified file 'bzrlib/tests/tree_implementations/test_iter_search_rules.py'
--- a/bzrlib/tests/tree_implementations/test_iter_search_rules.py	2008-06-26 06:53:18 +0000
+++ b/bzrlib/tests/tree_implementations/test_iter_search_rules.py	2008-08-14 03:08:42 +0000
@@ -32,6 +32,7 @@
     def make_tree_with_rules(self, text):
         tree = self.make_branch_and_tree('.')
         if text is not None:
+            self.fail("No method for in-tree rules agreed on yet.")
             text_utf8 = text.encode('utf-8')
             self.build_tree_contents([(rules.RULES_TREE_FILENAME, text_utf8)])
             tree.add(rules.RULES_TREE_FILENAME)
@@ -51,7 +52,7 @@
         self.assertEquals((('foo', 'baz'),), result[0])
         self.assertEquals((('foo', 'bar'), ('a', 'True')), result[1])
 
-    def test_iter_search_rules_just_tree(self):
+    def _disabled_test_iter_search_rules_just_tree(self):
         per_user = self.make_per_user_searcher('')
         tree = self.make_tree_with_rules(
             "[name ./a.txt]\n"
@@ -64,7 +65,7 @@
         self.assertEquals((('foo', 'baz'),), result[0])
         self.assertEquals((('foo', 'bar'), ('a', 'True')), result[1])
 
-    def test_iter_search_rules_tree_and_per_user(self):
+    def _disabled_test_iter_search_rules_tree_and_per_user(self):
         per_user = self.make_per_user_searcher(
             "[name ./a.txt]\nfoo=baz\n"
             "[name *.txt]\nfoo=bar\na=True\n")

=== modified file 'bzrlib/tree.py'
--- a/bzrlib/tree.py	2008-08-01 18:19:44 +0000
+++ b/bzrlib/tree.py	2008-08-14 03:08:42 +0000
@@ -557,11 +557,6 @@
     def _get_rules_searcher(self, default_searcher):
         """Get the RulesSearcher for this tree given the default one."""
         searcher = default_searcher
-        file_id = self.path2id(rules.RULES_TREE_FILENAME)
-        if file_id is not None:
-            ini_file = self.get_file(file_id)
-            searcher = rules._StackedRulesSearcher(
-                [rules._IniBasedRulesSearcher(ini_file), default_searcher])
         return searcher
 
 

=== modified file 'doc/en/user-guide/configuring_bazaar.txt'
--- a/doc/en/user-guide/configuring_bazaar.txt	2008-06-25 07:32:46 +0000
+++ b/doc/en/user-guide/configuring_bazaar.txt	2008-08-14 03:08:42 +0000
@@ -52,8 +52,8 @@
 ----------------------
 
 Some commands and plugins provide custom processing on files matching
-certain patterns. Branch-specific and per-user rule-based preferences
-are defined in ``.bzrrules`` and ``BZR_HOME/rules`` respectively.
+certain patterns. Per-user rule-based preferences are defined in
+``BZR_HOME/rules``.
 
 For further information on how rules are searched and the detailed syntax of
 the relevant files, see `Rules <../user-reference/bzr_man.html#rules>`_




More information about the bazaar-commits mailing list