2005-07-01 10:22:27 +04:00
|
|
|
#!/bin/sh
|
2005-06-15 01:28:42 +04:00
|
|
|
|
2005-08-06 18:43:12 +04:00
|
|
|
hg
|
|
|
|
hg -q
|
2005-07-03 23:47:45 +04:00
|
|
|
hg help
|
2005-06-18 19:32:41 +04:00
|
|
|
hg -q help
|
2009-12-21 13:18:43 +03:00
|
|
|
|
|
|
|
echo %% test short command list with verbose option
|
|
|
|
hg -v help shortlist | sed 's/[(]version [^)]*[)]/(version xxx)/'
|
|
|
|
|
2005-06-15 01:28:42 +04:00
|
|
|
hg add -h
|
2009-12-22 00:01:46 +03:00
|
|
|
|
2010-02-13 20:44:19 +03:00
|
|
|
echo %% verbose help for add
|
|
|
|
hg add -hv
|
|
|
|
|
2009-12-22 00:01:46 +03:00
|
|
|
echo %% test help option with version option
|
|
|
|
hg add -h --version | sed 's/[(]version [^)]*[)]/(version xxx)/'
|
|
|
|
|
2005-07-03 23:47:45 +04:00
|
|
|
hg add --skjdfks
|
2009-12-24 19:53:34 +03:00
|
|
|
|
|
|
|
echo %% test ambiguous command help
|
|
|
|
hg help ad
|
|
|
|
|
2009-12-24 19:53:35 +03:00
|
|
|
echo %% test command without options
|
|
|
|
hg help verify
|
|
|
|
|
2005-06-15 01:28:42 +04:00
|
|
|
hg help diff
|
2005-08-06 18:43:12 +04:00
|
|
|
hg help status
|
|
|
|
hg -q help status
|
2005-06-15 01:28:42 +04:00
|
|
|
hg help foo
|
2005-08-06 18:43:12 +04:00
|
|
|
hg skjdfks
|
2005-06-15 01:28:42 +04:00
|
|
|
|
2009-12-24 19:53:35 +03:00
|
|
|
cat > helpext.py <<EOF
|
|
|
|
import os
|
|
|
|
from mercurial import commands
|
|
|
|
|
|
|
|
def nohelp(ui, *args, **kwargs):
|
|
|
|
pass
|
|
|
|
|
|
|
|
cmdtable = {
|
|
|
|
"nohelp": (nohelp, [], "hg nohelp"),
|
|
|
|
}
|
|
|
|
|
|
|
|
commands.norepo += ' nohelp'
|
|
|
|
EOF
|
|
|
|
abspath=`pwd`/helpext.py
|
|
|
|
|
|
|
|
echo '[extensions]' >> $HGRCPATH
|
|
|
|
echo "helpext = $abspath" >> $HGRCPATH
|
|
|
|
|
|
|
|
echo %% test command with no help text
|
|
|
|
hg help nohelp
|
|
|
|
|
2009-12-24 19:53:35 +03:00
|
|
|
echo %% test that default list of commands omits extension commands
|
|
|
|
hg help
|
|
|
|
|
2009-12-24 19:53:35 +03:00
|
|
|
echo %% test list of commands with command with no help text
|
|
|
|
hg help helpext
|
|
|
|
|
2009-12-24 19:53:36 +03:00
|
|
|
echo %% test a help topic
|
|
|
|
hg help revs
|
|
|
|
|
2005-06-18 19:32:41 +04:00
|
|
|
exit 0
|