Skip to content
Snippets Groups Projects
  1. May 22, 2015
  2. May 19, 2015
  3. May 26, 2015
  4. May 22, 2015
    • Martin von Zweigbergk's avatar
      copies: document hack for adding '' to set of dirs · 947771ad
      Martin von Zweigbergk authored
      The root directory is not normally added to 'dirs' instances (although
      I think it should be). In copies.mergecopies, we call dirname() to get
      the directory of a path and then check for containment in the 'dirs'
      instances ('d1' and 'd2'). In order to easily handle files in the root
      directory, '/' is added to d1/d2. This results in the empty string
      being added to the sets, since what comes before the slash in '/' is
      an empty string. This seems less than obvious, so let's document it.
      947771ad
  5. May 26, 2015
  6. May 20, 2015
  7. May 16, 2015
    • Durham Goode's avatar
      match: enable 'subinclude:' syntax · 19d0e5ef
      Durham Goode authored
      This adds a new rule syntax that allows the user to include a pattern file, but
      only have those patterns match against files underneath the subdirectory of the
      pattern file.
      
      This is useful when you have nested projects in a repository and the inner
      projects wants to set up ignore rules that won't affect other projects in the
      repository. It is also useful in high commit rate repositories for removing the
      root .hgignore as a point of contention.
      19d0e5ef
  8. May 22, 2015
  9. May 21, 2015
  10. May 26, 2015
  11. May 22, 2015
  12. May 19, 2015
  13. May 21, 2015
  14. May 26, 2015
  15. May 25, 2015
  16. May 24, 2015
    • Katsunori FUJIWARA's avatar
      localrepo: pass hook argument txnid to pretxnopen hooks · a973b050
      Katsunori FUJIWARA authored
      Before this patch, hook argument `txnid` isn't passed to `pretxnopen`
      hooks, even though `hooks` section of `hg help config` describes so.
      
        ``pretxnopen``
          Run before any new repository transaction is open. The reason for the
          transaction will be in ``$HG_TXNNAME`` and a unique identifier for the
          transaction will be in ``HG_TXNID``. A non-zero status will prevent the
          transaction from being opened.
      a973b050
    • Katsunori FUJIWARA's avatar
      transaction: separate calculating TXNID from creating transaction object · 69c5cab0
      Katsunori FUJIWARA authored
      Before this patch, transaction ID (TXNID) is calculated from
      `transaction` object itself by `id()`, but this prevents TXNID from
      being passed to `pretxnopen` hooks, which should be executed before
      starting transaction processing (also any preparations for it, like
      writing journal files out).
      
      As a preparation for passing TXNID to `pretxnopen` hooks, this patch
      separates calculation of TXNID from creation of `transaction` object.
      
      This patch uses "random" library for reasonable unique ID. "uuid"
      library can't be used, because it was introduced since Python 2.5 and
      isn't suitable for Mercurial 3.4.x stable line.
      
      `%f` formatting for `random.random()` is used with explicit precision
      number 40, because default precision for `%f` is 6. 40 should be long
      enough, even if 10**9 transactions are executed in a short time (a
      second or less).
      
      On the other hand, `time.time()` is used to ensures uniqueness of
      TXNID in a long time, for safety.
      
      BTW, platform not providing `/dev/urandom` or so may cause failure of
      `import random` itself with some Python versions (see Python
      issue15340 for detail http://bugs.python.org/issue15340).
      
      But this patch uses "random" without any workaround, because:
      
        - "random" is already used directly in some code paths,
        - such platforms are very rare (e.g. Tru64 and HPUX), and
          http://bugs.python.org/issue15340#msg170000
        - updating Python runtime can avoid this issue
      69c5cab0
  17. May 23, 2015
    • Yuya Nishihara's avatar
      revbranchcache: return uncached branchinfo for nullrev (issue4683) · 38117278
      Yuya Nishihara authored
      This fixes the crash caused by "branch(null)" revset. No cache should be
      necessary for nullrev because changelog.branchinfo(nullrev) does not involve
      IO operation.
      
      Note that the problem of "branch(wdir())" isn't addressed by this patch.
      "wdir()" will raise TypeError in many places because of None. This is the
      reason why "wdir()" is still experimental.
      38117278
  18. May 24, 2015
    • Yuya Nishihara's avatar
      revset: drop magic of fullreposet membership test (issue4682) · e1645683
      Yuya Nishihara authored
      This patch partially backs out d2de20e1451f and adds an alternative workaround
      to functions that evaluate "null" and "wdir()". Because the new workaround is
      incomplete, "first(null)" and "min(null)" don't work as expected. But they were
      not usable until 3.4 and "null" isn't commonly used, we can postpone a complete
      fix for 3.5.
      
      The issue4682 was caused because "branch(default)" is evaluated to
      "<filteredset <fullreposet>>", keeping fullreposet magic. The next patch will
      fix crash on "branch(null)", but without this patch, it would make
      "null in <branch(default)>" be True, which means "children(branch(default))"
      would return all revisions but merge (p2 != null).
      
      I believe the right fix is to stop propagating fullreposet magic on filter(),
      but it wouldn't fit to stable release. Also, we should discuss how to handle
      "null" and "wdir()" in revset before.
      e1645683
  19. May 23, 2015
  20. May 22, 2015
  21. May 23, 2015
  22. May 21, 2015
  23. Apr 26, 2015
Loading