MCPcopy Create free account
hub / github.com/gitless-vcs/gitless / parser

Function parser

gitless/cli/gl_commit.py:25–41  ·  view source on GitHub ↗

Adds the commit parser to the given subparsers object.

(subparsers, repo)

Source from the content-addressed store, hash-verified

23
24
25def parser(subparsers, repo):
26 """Adds the commit parser to the given subparsers object."""
27 desc = 'save changes to the local repository'
28 commit_parser = subparsers.add_parser(
29 'commit', help=desc, description=(
30 desc.capitalize() + '. ' +
31 'By default all tracked modified files are committed. To customize the'
32 ' set of files to be committed use the only, exclude, and include '
33 'flags'))
34 commit_parser.add_argument(
35 '-m', '--message', help='Commit message', dest='m')
36 commit_parser.add_argument(
37 '-p', '--partial',
38 help='Interactively select segments of files to commit', dest='p',
39 action='store_true')
40 helpers.oei_flags(commit_parser, repo)
41 commit_parser.set_defaults(func=main)
42
43
44def main(args, repo):

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected