##// END OF EJS Templates
help: add/fix docstrings for a bunch of extensions
Dirkjan Ochtman -
r8873:e872ef2e default
parent child Browse files
Show More
@@ -1,4 +1,5 b''
1 # perf.py - performance test routines
1 # perf.py - performance test routines
2 '''helper extension to measure performance'''
2
3
3 from mercurial import cmdutil, match, commands
4 from mercurial import cmdutil, match, commands
4 import time, os, sys
5 import time, os, sys
@@ -5,45 +5,45 b''
5 # This software may be used and distributed according to the terms of the
5 # This software may be used and distributed according to the terms of the
6 # GNU General Public License version 2, incorporated herein by reference.
6 # GNU General Public License version 2, incorporated herein by reference.
7 #
7 #
8 # this hook allows to allow or deny access to parts of a repo when
8
9 # taking incoming changesets.
9 '''provide simple hooks for access control
10 #
10
11 # authorization is against local user name on system where hook is
11 Authorization is against local user name on system where hook is run, not
12 # run, not committer of original changeset (since that is easy to
12 committer of original changeset (since that is easy to spoof).
13 # spoof).
13
14 #
14 The acl hook is best to use if you use hgsh to set up restricted shells for
15 # acl hook is best to use if you use hgsh to set up restricted shells
15 authenticated users to only push to / pull from. It's not safe if user has
16 # for authenticated users to only push to / pull from. not safe if
16 interactive shell access, because they can disable the hook. It's also not
17 # user has interactive shell access, because they can disable hook.
17 safe if remote users share one local account, because then there's no way to
18 # also not safe if remote users share one local account, because then
18 tell remote users apart.
19 # no way to tell remote users apart.
19
20 #
20 To use, configure the acl extension in hgrc like this:
21 # to use, configure acl extension in hgrc like this:
21
22 #
22 [extensions]
23 # [extensions]
23 hgext.acl =
24 # hgext.acl =
24
25 #
25 [hooks]
26 # [hooks]
26 pretxnchangegroup.acl = python:hgext.acl.hook
27 # pretxnchangegroup.acl = python:hgext.acl.hook
27
28 #
28 [acl]
29 # [acl]
29 sources = serve # check if source of incoming changes in this list
30 # sources = serve # check if source of incoming changes in this list
30 # ("serve" == ssh or http, "push", "pull", "bundle")
31 # # ("serve" == ssh or http, "push", "pull", "bundle")
31
32 #
32 Allow and deny lists have a subtree pattern (default syntax is glob) on the
33 # allow and deny lists have subtree pattern (default syntax is glob)
33 left and user names on right. The deny list is checked before the allow list.
34 # on left, user names on right. deny list checked before allow list.
34
35 #
35 [acl.allow]
36 # [acl.allow]
36 # if acl.allow not present, all users allowed by default
37 # # if acl.allow not present, all users allowed by default
37 # empty acl.allow = no users allowed
38 # # empty acl.allow = no users allowed
38 docs/** = doc_writer
39 # docs/** = doc_writer
39 .hgtags = release_engineer
40 # .hgtags = release_engineer
40
41 #
41 [acl.deny]
42 # [acl.deny]
42 # if acl.deny not present, no users denied by default
43 # # if acl.deny not present, no users denied by default
43 # empty acl.deny = all users allowed
44 # # empty acl.deny = all users allowed
44 glob pattern = user4, user5
45 # glob pattern = user4, user5
45 ** = user6
46 # ** = user6
46 '''
47
47
48 from mercurial.i18n import _
48 from mercurial.i18n import _
49 from mercurial import util, match
49 from mercurial import util, match
@@ -8,6 +8,8 b''
8 # This software may be used and distributed according to the terms of the
8 # This software may be used and distributed according to the terms of the
9 # GNU General Public License version 2, incorporated herein by reference.
9 # GNU General Public License version 2, incorporated herein by reference.
10
10
11 '''provides children command to show children changesets'''
12
11 from mercurial import cmdutil
13 from mercurial import cmdutil
12 from mercurial.commands import templateopts
14 from mercurial.commands import templateopts
13 from mercurial.i18n import _
15 from mercurial.i18n import _
@@ -5,7 +5,8 b''
5 # This software may be used and distributed according to the terms of the
5 # This software may be used and distributed according to the terms of the
6 # GNU General Public License version 2, incorporated herein by reference.
6 # GNU General Public License version 2, incorporated herein by reference.
7
7
8 '''
8 '''allow external programs to compare revisions
9
9 The `extdiff' Mercurial extension allows you to use external programs
10 The `extdiff' Mercurial extension allows you to use external programs
10 to compare revisions, or revision with working directory. The external diff
11 to compare revisions, or revision with working directory. The external diff
11 programs are called with a configurable set of options and two
12 programs are called with a configurable set of options and two
@@ -1,10 +1,10 b''
1 # GnuPG signing extension for Mercurial
2 #
3 # Copyright 2005, 2006 Benoit Boissinot <benoit.boissinot@ens-lyon.org>
1 # Copyright 2005, 2006 Benoit Boissinot <benoit.boissinot@ens-lyon.org>
4 #
2 #
5 # This software may be used and distributed according to the terms of the
3 # This software may be used and distributed according to the terms of the
6 # GNU General Public License version 2, incorporated herein by reference.
4 # GNU General Public License version 2, incorporated herein by reference.
7
5
6 '''GnuPG signing extension for Mercurial'''
7
8 import os, tempfile, binascii
8 import os, tempfile, binascii
9 from mercurial import util, commands, match
9 from mercurial import util, commands, match
10 from mercurial import node as hgnode
10 from mercurial import node as hgnode
@@ -5,8 +5,7 b''
5 # This software may be used and distributed according to the terms of the
5 # This software may be used and distributed according to the terms of the
6 # GNU General Public License version 2, incorporated herein by reference.
6 # GNU General Public License version 2, incorporated herein by reference.
7
7
8 '''\
8 '''use suffixes to refer to ancestor revisions
9 use suffixes to refer to ancestor revisions
10
9
11 This extension allows you to use git-style suffixes to refer to the
10 This extension allows you to use git-style suffixes to refer to the
12 ancestors of a specific revision.
11 ancestors of a specific revision.
@@ -23,6 +23,8 b''
23 # along with this program; if not, write to the Free Software
23 # along with this program; if not, write to the Free Software
24 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
24 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
25
25
26 '''enable removing untracked files only'''
27
26 from mercurial import util, commands, cmdutil
28 from mercurial import util, commands, cmdutil
27 from mercurial.i18n import _
29 from mercurial.i18n import _
28 import os, stat
30 import os, stat
@@ -1,10 +1,10 b''
1 # Mercurial extension to provide the 'hg share' command
2 #
3 # Copyright 2006, 2007 Matt Mackall <mpm@selenic.com>
1 # Copyright 2006, 2007 Matt Mackall <mpm@selenic.com>
4 #
2 #
5 # This software may be used and distributed according to the terms of the
3 # This software may be used and distributed according to the terms of the
6 # GNU General Public License version 2, incorporated herein by reference.
4 # GNU General Public License version 2, incorporated herein by reference.
7
5
6 '''provides the hg share command'''
7
8 import os
8 import os
9 from mercurial.i18n import _
9 from mercurial.i18n import _
10 from mercurial import hg, commands
10 from mercurial import hg, commands
@@ -4,31 +4,34 b''
4 #
4 #
5 # This software may be used and distributed according to the terms of the
5 # This software may be used and distributed according to the terms of the
6 # GNU General Public License version 2, incorporated herein by reference.
6 # GNU General Public License version 2, incorporated herein by reference.
7 #
7
8 # To perform automatic newline conversion, use:
8 '''LF <-> CRLF/CR translation utilities
9 #
9
10 # [extensions]
10 To perform automatic newline conversion, use:
11 # hgext.win32text =
11
12 # [encode]
12 [extensions]
13 # ** = cleverencode:
13 hgext.win32text =
14 # # or ** = macencode:
14 [encode]
15 # [decode]
15 ** = cleverencode:
16 # ** = cleverdecode:
16 # or ** = macencode:
17 # # or ** = macdecode:
17
18 #
18 [decode]
19 # If not doing conversion, to make sure you do not commit CRLF/CR by
19 ** = cleverdecode:
20 # accident:
20 # or ** = macdecode:
21 #
21
22 # [hooks]
22 If not doing conversion, to make sure you do not commit CRLF/CR by accident:
23 # pretxncommit.crlf = python:hgext.win32text.forbidcrlf
23
24 # # or pretxncommit.cr = python:hgext.win32text.forbidcr
24 [hooks]
25 #
25 pretxncommit.crlf = python:hgext.win32text.forbidcrlf
26 # To do the same check on a server to prevent CRLF/CR from being
26 # or pretxncommit.cr = python:hgext.win32text.forbidcr
27 # pushed or pulled:
27
28 #
28 To do the same check on a server to prevent CRLF/CR from being
29 # [hooks]
29 pushed or pulled:
30 # pretxnchangegroup.crlf = python:hgext.win32text.forbidcrlf
30
31 # # or pretxnchangegroup.cr = python:hgext.win32text.forbidcr
31 [hooks]
32 pretxnchangegroup.crlf = python:hgext.win32text.forbidcrlf
33 # or pretxnchangegroup.cr = python:hgext.win32text.forbidcr
34 '''
32
35
33 from mercurial.i18n import _
36 from mercurial.i18n import _
34 from mercurial.node import short
37 from mercurial.node import short
General Comments 0
You need to be logged in to leave comments. Login now