Commit Graph

31 Commits

Author SHA1 Message Date
timeless
0dcdb26a9d debuginstall: expose modulepolicy
With this, you can check for pure easily:
$ HGMODULEPOLICY=py ./hg debuginstall -T "{hgmodulepolicy}"
py
2016-03-09 19:55:45 +00:00
timeless
0c82fc02cd tests: silence test-repo obsolete warning
refactoring test-check-commit.t HGRCPATH bits as helpers-testrepo.sh
2016-05-11 04:49:27 +00:00
timeless
bd5be422b3 debuginstall: add mercurial version 2016-05-10 22:45:45 +00:00
Sean Farley
dc865d7f73 hg-ssh: copy doc string to man page
This corrects a warning from lintian that we're shipping an executable without
a man page. Since there is a doc string in the text, let's use that for the man
page.
2016-05-06 23:03:41 -07:00
Matt Harbison
0f04af5785 test-install: fix output on Windows
See 388e9591df04.
2016-03-15 21:45:32 -04:00
Sean Farley
6c01155b0a tests: python executable should always be globbed
Similar to d892d0231a82, the python executable could be python2.X, Python,
pypy, or maybe something futuristic like pyston or nuitka.
2016-03-24 16:35:24 -07:00
Danek Duvall
38ac6bfb8a tests: python executable path should always be globbed
Although this is coming in under the guise of consistency, part of the
desire for this is that at least as part of the official Solaris builds,
we build with a versioned python interpreter, such as "python2.7", which
doesn't match "*python".
2016-03-15 15:50:57 -07:00
timeless
c4098a81cc debuginstall: convert to formatter
commit editor now reports its editor
default template is now reported

a broken vi editor (vi not in path) is still not considered a problem (!!)
2016-03-09 18:58:51 +00:00
Matt Harbison
59bfa8869d wix: add help for current internal topics
This makes the changes in 68b7b759ebff and 71a3703364df available on Windows.

I'm not setup to make the installer, so someone with experience in this area
should probably give it a look.  In looking around to try to figure out how to
build the installer, it looks like the Makefile may need an update to $DOCFILES.
2015-12-17 21:24:08 -05:00
Gregory Szorc
8e5f315fff internals: document revlog format
It seems like a good idea to document the revlog format.

There is a lot more that could be added to this documentation.
But you have to start somewhere.
2015-12-30 16:21:57 -07:00
Yuya Nishihara
75e54f0d1a test-install: embed wix namespace for Python 2.6 compatibility
According to doc, the syntax is "{uri}tag".

https://docs.python.org/2.7/library/xml.etree.elementtree.html#parsing-xml-with-namespaces
2015-12-23 22:48:48 +09:00
Matt Harbison
85a68ab949 test-install: perform the wix checking on wdir() instead of "."
This allows catching problems before they are committed.
2015-12-17 21:18:02 -05:00
Matt Mackall
bfb407a6ed wix: add missing template 2015-12-16 17:17:12 -06:00
Matt Harbison
3be931ee49 tests: add coverage to ensure Wix tracks 'help' and 'templates' files
This would have caught the problem fixed by 47bcbe06a48d. There are
other *.wxs files that can be checked, but they appear to be more
complicated. For example, locale.wxs has what appears to be foreach
loop support, as well as variable substitution.

By checking `hg files` to determine tracked file, this is able to avoid false
failures when other junk is present in the filesystem, like *.orig files.

I can't tell if the map-cmdline.status file is not included on purpose, but I
don't see the purpose of excluding it.  The missing help files seem reasonable
for Windows.
2015-09-13 22:54:51 -04:00
Matt Harbison
f2ad8f39e0 debuginstall: expand the editor path before searching for it (issue4380)
The editor launches without expanding the path with commits because the shell
does that for us.

If the path isn't an executable, the expanded path is displayed, which is
probably more useful than the unexpanded path.  For example, in cmd.exe, '~'
expands to C:\Users\$user.  But it expands to C:/mingw/msys/1.0/home/$user in
MinGW.
2015-04-30 23:02:52 -04:00
Matt Mackall
521c4ac54d debuginstall: change showing to checking for consistency and future checking 2014-03-14 16:00:11 -05:00
Chris Jerdonek
53c61a10f1 debuginstall: add Python information to debuginstall output (issue4128)
This change adds to the output of "hg debuginstall" information about the
Python being used by Mercurial.  It adds both the path to the Python
executable (i.e. the value of sys.executable) and the version of Python
(specifically the major, minor, and micro versions).

Below is an example of what the output looks like after this change.
The marked lines are the new output lines:

    $ hg debuginstall
    checking encoding (UTF-8)...
 -->showing Python executable (/Users/chris/.virtualenvs/default/bin/python)
 -->showing Python version (2.7.6)
    checking Python lib (/Users/chris/.virtualenvs/default/lib/python2.7)...
    checking installed modules (/Users/chris/mercurial)...
    checking templates (/Users/chris/mercurial/templates)...
    checking commit editor...
    checking username...
    no problems detected

Note that we use the word "showing" without an ellipsis for the new lines
because, unlike the other lines (except for "Python lib" which will be
adjusted in a subsequent commit), no check follows the display of this
information.
2013-12-31 00:37:16 -08:00
Matt Mackall
6ba3cc7397 ui: suggest config --edit when no username is set 2014-02-27 14:46:29 -06:00
Adrian Buehlmann
5b16379fd5 debuginstall: show directory for Python lib
Example new output

on Windows:

  $ hg debuginstall
  checking encoding (cp1252)...
  checking Python lib (C:\Users\adi\hgrepos\hg-main\hg-python\lib)...
  checking installed modules (C:\Users\adi\hgrepos\hg-main\mercurial)...
  checking templates (C:\Users\adi\hgrepos\hg-main\mercurial\templates)...
  checking commit editor...
  C:\Program Files (x86)\Notepad++\notepad++.exe
  checking username...
  no problems detected

on Linux:

  adi@kork-ubuntu64:~/hgrepos/hg-main$ ./hg debuginstall
  checking encoding (UTF-8)...
  checking Python lib (/usr/lib/python2.7)...
  checking installed modules (/home/adi/hgrepos/hg-main/mercurial)...
  checking templates (/home/adi/hgrepos/hg-main/mercurial/templates)...
  checking commit editor...
  checking username...
  no problems detected
2012-08-06 12:59:47 +02:00
Martin Geisler
7b0a61680f debuginstall: lowercase status messages 2012-06-12 14:18:18 +02:00
Mads Kiilerich
8c22a0ec28 tests: make (glob) on windows accept \ instead of /
Globbing is usually used for filenames, so on windows it is reasonable and very
convenient that glob patterns accepts '\' or '/' when the pattern specifies
'/'.
2011-11-07 03:25:10 +01:00
Matt Mackall
f315765fd4 debuginstall: report the template path 2011-10-07 15:36:50 -05:00
Patrick Mezard
92074cd441 patch: deprecate ui.patch / external patcher feature
Why?
- Mercurial internal patcher works correctly for regular patches and git
  patches, is much faster at least on Windows and is more extensible.
- In theory, the external patcher can be used to handle exotic patch formats. I
  do not know any and have not heard about any such use in years.
- Most patch programs cannot handle git format patches, which makes the API
  caller to decide either to ignore ui.patch by calling patch.internalpatch()
  directly, or take the risk of random failures with valid inputs.
- One thing a patch program could do Mercurial patcher cannot is applying with
  --reverse. Apparently several shelve like extensions try to use that,
  including passing the "reverse" option to Mercurial patcher, which has been
  removed mid-2009. I never heard anybody complain about that, and would prefer
  reimplementing it anyway.

And from the technical perspective:
- The external patcher makes everything harder to maintain and implement. EOL
  normalization is not implemented, and I would bet file renames, if supported
  by the patcher, are not correctly recorded in the dirstate.
- No tests.

How?
- Remove related documentation
- Clearly mark patch.externalpatch() as private
- Remove the debuginstall check. This deprecation request was actually
  triggered by this last point. debuginstall is the only piece of code patching
  without a repository. When migrating to an integrated patch() + updatedir()
  call, this was really a showstopper, all workarounds were either ugly or
  uselessly complicated to implement. If we do not support external patcher
  anymore, the debuginstall check is not useful anymore.
- Remove patch.externalpatch() after 1.9 release.
2011-03-24 10:28:29 +01:00
Brodie Rao
b5fe0d906e tests: add glob matching for unified tests
This adds a " (glob)" marker that works like a simpler version of
(re): "*" is converted to ".*", and "?" is converted to ".".

Both special characters can be escaped using "\", and the backslash
itself can be escaped as well.

Other glob-style syntax, like "**", "[chars]", or "[!chars]", isn't
supported.
2010-09-22 16:06:02 -05:00
Brodie Rao
7d7d96bd74 tests: require regexes in unified tests to be marked with " (re)"
Consider this test:

  $ hg glog --template '{rev}:{node|short} "{desc}"\n'
  @  2:20c4f79fd7ac "3"
  |
  | o  1:38f24201dcab "2"
  |/
  o  0:2a18120dc1c9 "1"

Because each line beginning with "|" can be compiled as a regular
expression (equivalent to ".*|"), they will match any output.

Similarly:

  $ echo foo


The blank output line can be compiled as a regular expression and will
also match any output.

With this patch, none of the above output lines will be matched as
regular expressions. A line must end in " (re)" in order to be matched
as one.

Lines are still matched literally first, so the following will pass:

  $ echo 'foo (re)'
  foo (re)
2010-09-22 16:06:00 -05:00
Brodie Rao
3ed54dfa3d tests: improve regexes in unified tests 2010-09-22 16:05:58 -05:00
Matt Mackall
32de98afbd tests: drop final true command from unified tests 2010-09-20 16:00:15 -05:00
Matt Mackall
08439e0f2d tests: add exit codes to unified tests 2010-09-16 17:51:32 -05:00
Martin Geisler
c3c7fa090f Merge with stable 2010-08-30 13:00:22 +02:00
Matt Mackall
fa11c5cbae debuginstall: report installpath 2010-08-20 15:31:05 -05:00
Pradeepkumar Gayam
4a2f44d4b0 tests: unify test-install 2010-08-17 17:48:59 +05:30