Skip to content
Snippets Groups Projects
  1. Feb 07, 2015
    • Gregory Szorc's avatar
      ui: represent paths as classes · 9c32eea2
      Gregory Szorc authored
      Many have long wanted for paths to have expanded functionality and
      flexibility.
      
      In order to make that transition possible, we need to start
      representing paths as something more than simple strings.
      
      This patch introduces two classes:
      
      1) "path" for representing a single path instance
      2) "paths" for representing a collection of "paths"
      
      Since we don't like patches that introduce new code without any
      consumers, we convert ui.expandpath() to use the new APIs internally.
      Upcoming patches will start exposing "path" instances to consumers
      that currently interface with string paths.
      
      The new "paths" attribute of ui is populated from config data the first
      time it is accessed. Since it isn't updated when the configs are
      modified, this could lead to some inaccurate caching behavior. It
      shouldn't be an issue, as paths information is typically not accessed
      until command dispatch, which occurs after the repository config
      and extensions have been loaded. Time will tell if we need to refresh
      paths information when the underlying config changes.
      9c32eea2
  2. Mar 10, 2015
    • Jordi Gutiérrez Hermoso's avatar
      color: omit terminfo/win32 warning if non-interactive (issue4543) · 5058e696
      Jordi Gutiérrez Hermoso authored
      It's pretty annoying to be getting this warning when already the
      colour extension has no hope of working. If there isn't a human on the
      other end to to see the colours, there probably isn't a human either
      who cares about this warning. More likely, some script somewhere is
      gonna get confused with the warning output.
      
      Of course, if we still want to see the warning for some reason, we can
      always set --config ui.interactive=True.
      5058e696
  3. Feb 26, 2015
  4. Mar 07, 2015
  5. Feb 18, 2015
  6. Mar 08, 2015
  7. Feb 18, 2015
  8. Mar 06, 2015
    • Laurent Charignon's avatar
      record: allow editing new files (issue4304) · 79fceed6
      Laurent Charignon authored
      While using the record extension to select changes, the user couldn't see the
      content of newly added files and had to select/reject them based on filename.
      The test is changed accordingly in two places.
      79fceed6
  9. Mar 05, 2015
  10. Mar 09, 2015
  11. Jan 25, 2015
  12. Mar 08, 2015
  13. Jan 31, 2015
    • Augie Fackler's avatar
      lazymanifest: use a binary search to do an insertion · 542c8912
      Augie Fackler authored
      This makes insertions log(n) plus some memmove() overhead, rather than
      doing an append followed by an n*log(n) sort. There's probably a lot
      of performance to be gained by adding a batch-add method, which could
      be smarter about the memmove()s performed.
      
      Includes a couple of extra tests that should help prevent bugs.
      
      Thanks to Martin for some significant pre-mail cleanup of this change.
      542c8912
  14. Nov 17, 2014
  15. Mar 07, 2015
    • Augie Fackler's avatar
      manifest: use custom C implementation of lazymanifest · b992769d
      Augie Fackler authored
      This version is actually lazy, unlike the pure-python version. The
      latter could stand to be optimized if anyone actually wants to use it
      seriously. I put no work into it.
      
      Before any of my related changes on mozilla-central:
      
      perfmanifest tip
      ! wall 0.268805 comb 0.260000 user 0.260000 sys 0.000000 (best of 37)
      perftags
      ! result: 162
      ! wall 0.007099 comb 0.000000 user 0.000000 sys 0.000000 (best of 401)
      perfstatus
      ! wall 0.415680 comb 0.420000 user 0.260000 sys 0.160000 (best of 24)
      hgperf export tip
      ! wall 0.142118 comb 0.140000 user 0.140000 sys 0.000000 (best of 67)
      
      after all of my changes on mozilla-central:
      
      ./hg:
      perfmanifest tip
      ! wall 0.232640 comb 0.230000 user 0.220000 sys 0.010000 (best of 43)
      perftags
      ! result: 162
      ! wall 0.007057 comb 0.010000 user 0.000000 sys 0.010000 (best of 395)
      perfstatus
      ! wall 0.415503 comb 0.420000 user 0.280000 sys 0.140000 (best of 24)
      hgperf export tip
      ! wall 0.025096 comb 0.030000 user 0.030000 sys 0.000000 (best of 102)
      
      so it's no real change in performance on perf{manifest,tags,status},
      but is a huge win on 'hgperf export tip'.
      
      There's a little performance work that could still be done here:
      fastdelta() could be done significantly more intelligently by using
      the internal state of the lazymanifest type in C, but that seems like
      good future work.
      b992769d
    • Augie Fackler's avatar
      manifest: split manifestdict into high-level and low-level logic · 3e5c4af6
      Augie Fackler authored
      The low-level logic type (_lazymanifest) matches the behavior of the C
      implementation introduced in a5f1bccd2996. A future patch will use that
      when available.
      3e5c4af6
    • Augie Fackler's avatar
      manifest: do parsing inside manifestdict contstructor · d71837d0
      Augie Fackler authored
      This shape to the code will make using a C implementation of the
      manifest storage easier.
      d71837d0
    • Augie Fackler's avatar
      manifest: move parsing functions up in file · b4df0d0c
      Augie Fackler authored
      These functions are about to change signature and be hidden inside the
      manifestdict constructor. Doing the code motion now as an isolated
      change to make things easier to review.
      b4df0d0c
  16. Feb 10, 2015
  17. Jan 26, 2015
  18. Nov 24, 2014
    • Jordi Gutiérrez Hermoso's avatar
      log: display closing-branch nodes as "_" (BC) · 4bb348ae
      Jordi Gutiérrez Hermoso authored
      In plain `hg log` there is no indication that a commit closes a
      branch. You can use hg log --debug, but this is too verbose. A simple
      idea copied from thg and other graphical viewers is to display the
      node for a closing-branch commit as a horizontal line.
      
      I think this technically is a BC if we consider the graphlog to be
      part of the stdout API, but I really can't imagine who the hell is
      parsing the graphlog to determine information about commits.
      4bb348ae
  19. Mar 06, 2015
  20. Jan 13, 2015
    • Augie Fackler's avatar
      manifest.c: new extension code to lazily parse manifests · a5f1bccd
      Augie Fackler authored
      This lets us iterate manifests in order, but do a _lot_ less work in
      the common case when we only care about a few manifest entries.
      
      Many thanks to Mike Edgar for reviewing this in advance of it going
      out to the list, which caught many things I missed.
      
      This version of the patch includes C89 fixes from Sean Farley and
      many correctness/efficiency cleanups from Martin von
      Zweigbergk. Thanks to both!
      a5f1bccd
  21. Mar 06, 2015
    • Durham Goode's avatar
      workingctx: use normal dirs() instead of dirstate.dirs() · e0c1328d
      Durham Goode authored
      The workingctx class was using dirstate.dirs() as it's implementation. The
      sparse extension maintains a pruned down version of the dirstate, so this
      resulted in the workingctx reporting an incorrect listing of directories
      during merge calculations (it was detecting directory renames when it
      shouldn't have).
      
      The fix is to use the default implementation, which uses workingctx._manifest,
      which unions the manifest with the dirstate to produce the correct overall
      picture. This also produces more accurate output since it will no longer
      return directories that have been entirely deleted in the dirstate.
      
      Tests will be added to the sparse extension to detect regressions for this.
      e0c1328d
  22. Mar 05, 2015
  23. Mar 04, 2015
Loading