Skip to content
Snippets Groups Projects
  1. Apr 16, 2016
  2. Apr 14, 2016
    • Pierre-Yves David's avatar
      hook: report untrusted hooks as failure (issue5110) (BC) · ea1fec3e
      Pierre-Yves David authored
      Before this patch, there was no way for a repository owner to ensure that
      validation hooks would be run by people with write access. If someone had write
      access but did not trust the user owning the repository, the config and its hook
      would simply be ignored.
      
      After this patch, hooks from untrusted configs are taken into account but never
      actually run. Instead they are reported as failures right away. This will ensure
      validation performed by a hook is not ignored.
      
      As a side effect writer can be forced to trust a repository hgrc by adding a
      'pretxnopen.trust=true' hook to the file.
      
      This was discussed during the 3.8 sprint with Matt Mackall, Augie Fackler and
      Kevin Bullock.
      ea1fec3e
  3. Apr 15, 2016
    • Pierre-Yves David's avatar
      hook: split config reading further · 3112c5e1
      Pierre-Yves David authored
      We want an easy way to fetch the hook config with and without honoring
      "trusted" so that we can compare the values. So we extract the part
      retrieving raw hook data from the config to be able to call it twice
      in the next patch.
      3112c5e1
  4. Apr 14, 2016
  5. Apr 15, 2016
  6. Apr 14, 2016
    • Pierre-Yves David's avatar
      crecord: cleanup the remains of commit confirmation · 0411b799
      Pierre-Yves David authored
      The confirmation screen is now only used for the 'review' option we simplify
      the code and rename the function.
      0411b799
    • Pierre-Yves David's avatar
      crecord: drop the extra confirmation screen · ee56a86e
      Pierre-Yves David authored
      The commit confirmation is not very useful -- it gives no way to view what you
      have selected, so you're blindly choosing whether to proceed or not, and it adds
      a lot of unnecessary friction to committing. In addition, we now have a working
      'review' choice for those who really want to review the final change.
      
      Ryan McElroy initially submitted a config option to make this optional, but we
      never saw a V2. However as the freeze is near and curses have never been
      officially out of the door, I think it is worth skipping the config and trying
      getting it right for this release.
      ee56a86e
  7. Apr 15, 2016
    • Yuya Nishihara's avatar
      update: resurrect bare update from null parent to tip-most branch head · d9539959
      Yuya Nishihara authored
      The situation is tricky if repository has no "default" branch, because "null"
      revision belongs to non-existent "default" branch.
      
      Before e1dd0de26557, bare update from null would bring us to the tip-most
      non-closed branch head. e1dd0de26557 removed the special handling of missing
      "default" branch since we wanted to stick to the uncommitted branch in that
      case. But, if the parent is "null" revision, and if the missing branch is
      "default", it shouldn't be an uncommitted branch. In this case, bare update
      should bring us to the tip-most head as before.
      
      This should fix the test breakage introduced by e1dd0de26557.
      d9539959
  8. Apr 12, 2016
  9. Apr 13, 2016
  10. Apr 11, 2016
  11. Apr 13, 2016
  12. Mar 27, 2016
  13. Mar 29, 2016
    • Yuya Nishihara's avatar
      parser: factor out _trygetfunc() that extracts function name and arguments · 1203159c
      Yuya Nishihara authored
      This provides a customization point for templater. In templater, there are
      two ways to call a unary function: func(x) and x|func. They are processed
      differently in templater due to historical reasons, but they should be
      handled in the same way while expanding aliases. In short, x|func should be
      processed as syntactic sugar for func(x).
      
      _funcnode and _getlist() are replaced by _trygetfunc().
      1203159c
    • Yuya Nishihara's avatar
      parser: make _getalias() return (alias, pattern-args) pair · edbffdc7
      Yuya Nishihara authored
      This allows us to factor out a function that extracts a function (name, args)
      pair. See the next patch for why.
      edbffdc7
    • Yuya Nishihara's avatar
      parser: drop redundant comparison between alias declaration tree and pattern · 7a772def
      Yuya Nishihara authored
      Since _getalias() explicitly tests the type and name of the pattern tree, we
      don't need to compare "a.tree == tree" for 'symbol', and "a.tree == tree[:2]"
      for 'func', where tree is either ('symbol', name) or ('func', ('symbol', name)).
      
      This change helps implementing better handling of template aliases. See the
      subsequent patches for details.
      
      The alias.tree field is removed as it is no longer used.
      7a772def
Loading