diff options
author | Daniel Mensinger <daniel@mensinger-ka.de> | 2019-03-02 12:40:31 +0100 |
---|---|---|
committer | Daniel Mensinger <daniel@mensinger-ka.de> | 2019-03-04 13:00:07 +0100 |
commit | 90b557e38af2df9e68f72c96d0f22f0e7bc37e91 (patch) | |
tree | 794b894d7feeca3f2174c96975f1dd47f8130f58 | |
parent | 1290330894f5c2ad77684b1b3985a7ba17114ccb (diff) | |
download | meson-90b557e38af2df9e68f72c96d0f22f0e7bc37e91.zip meson-90b557e38af2df9e68f72c96d0f22f0e7bc37e91.tar.gz meson-90b557e38af2df9e68f72c96d0f22f0e7bc37e91.tar.bz2 |
rewriter: Remove command alias
-rw-r--r-- | docs/markdown/Rewriter.md | 7 | ||||
-rw-r--r-- | mesonbuild/mesonmain.py | 2 | ||||
-rw-r--r-- | mesonbuild/rewriter.py | 6 |
3 files changed, 7 insertions, 8 deletions
diff --git a/docs/markdown/Rewriter.md b/docs/markdown/Rewriter.md index 332c9f7..ce769d4 100644 --- a/docs/markdown/Rewriter.md +++ b/docs/markdown/Rewriter.md @@ -26,10 +26,9 @@ frontends, etc.) ## Using the rewriter -All rewriter functions are accessed via `meson rewrite` (or the rewriter alias -`meson rw`). The meson rewriter assumes that it is run inside the project root -directory. If this isn't the case, use `--sourcedir` to specify the actual -project source directory. +All rewriter functions are accessed via `meson rewrite`. The meson rewriter +assumes that it is run inside the project root directory. If this isn't the +case, use `--sourcedir` to specify the actual project source directory. ### Adding and removing sources diff --git a/mesonbuild/mesonmain.py b/mesonbuild/mesonmain.py index bd19da5..822a943 100644 --- a/mesonbuild/mesonmain.py +++ b/mesonbuild/mesonmain.py @@ -57,7 +57,7 @@ class CommandLineParser: self.add_command('help', self.add_help_arguments, self.run_help_command, help='Print help of a subcommand') self.add_command('rewrite', lambda parser: rewriter.add_arguments(parser, self.formater), rewriter.run, - help='Modify the project definition', aliases=['rw']) + help='Modify the project definition') # Hidden commands self.add_command('runpython', self.add_runpython_arguments, self.run_runpython_command, diff --git a/mesonbuild/rewriter.py b/mesonbuild/rewriter.py index 196fc3b..a47a3a1 100644 --- a/mesonbuild/rewriter.py +++ b/mesonbuild/rewriter.py @@ -39,7 +39,7 @@ def add_arguments(parser, formater=None): subparsers = parser.add_subparsers(dest='type', title='Rewriter commands', description='Rewrite command to execute') # Target - tgt_parser = subparsers.add_parser('target', aliases=['tgt'], help='Modify a target', formatter_class=formater) + tgt_parser = subparsers.add_parser('target', help='Modify a target', formatter_class=formater) tgt_parser.add_argument('-s', '--subdir', default='', dest='subdir', help='Subdirectory of the new target (only for the "add_target" action)') tgt_parser.add_argument('--type', dest='tgt_type', choices=rewriter_keys['target']['target_type'][2], default='executable', help='Type of the target to add (only for the "add_target" action)') @@ -58,13 +58,13 @@ def add_arguments(parser, formater=None): kw_parser.add_argument('kwargs', nargs='*', help='Pairs of keyword and value') # Default options - def_parser = subparsers.add_parser('default-options', aliases=['def'], help='Modify the project default options', formatter_class=formater) + def_parser = subparsers.add_parser('default-options', help='Modify the project default options', formatter_class=formater) def_parser.add_argument('operation', choices=rewriter_keys['default_options']['operation'][2], help='Action to execute') def_parser.add_argument('options', nargs='*', help='Key, value pairs of configuration option') # JSON file/command - cmd_parser = subparsers.add_parser('command', aliases=['cmd'], help='Execute a JSON array of commands', formatter_class=formater) + cmd_parser = subparsers.add_parser('command', help='Execute a JSON array of commands', formatter_class=formater) cmd_parser.add_argument('json', help='JSON string or file to execute') class RequiredKeys: |