Lines Matching full:command

41             interpreter, "command source",  in CommandObjectCommandsSource()
125 // Instance variables to hold the values for command options.
133 bool DoExecute(Args &command, CommandReturnObject &result) override { in DoExecute() argument
134 if (command.GetArgumentCount() != 1) { in DoExecute()
145 result.AppendError("command source -C can only be specified " in DoExecute()
146 "from a command file"); in DoExecute()
152 FileSpec cmd_file(command[0].ref()); in DoExecute()
156 result.AppendError("command source -C can only be used " in DoExecute()
178 // Individual silent setting is override for global command echo settings. in DoExecute()
203 "Enter your Python command(s). Type 'DONE' to end.\n"
261 interpreter, "command alias", in CommandObjectCommandsAlias()
262 "Define a custom command in terms of an existing command.") { in CommandObjectCommandsAlias()
269 Below are some simple examples of how one might use the 'alias' command:" in CommandObjectCommandsAlias()
272 (lldb) command alias sc script in CommandObjectCommandsAlias()
274 Creates the abbreviation 'sc' for the 'script' command. in CommandObjectCommandsAlias()
276 (lldb) command alias bp breakpoint in CommandObjectCommandsAlias()
279 " Creates the abbreviation 'bp' for the 'breakpoint' command. Since \ in CommandObjectCommandsAlias()
284 (lldb) command alias bpl breakpoint list in CommandObjectCommandsAlias()
286 Creates the abbreviation 'bpl' for the two-word command 'breakpoint list'. in CommandObjectCommandsAlias()
289 "An alias can include some options for the command, with the values either \ in CommandObjectCommandsAlias()
295 (lldb) command alias bfl breakpoint set -f %1 -l %2 in CommandObjectCommandsAlias()
302 for the actual arguments that will be passed when the alias command is used. \ in CommandObjectCommandsAlias()
313 command, so you can't at present do something like this to append the file extension \ in CommandObjectCommandsAlias()
317 (lldb) command alias bcppfl breakpoint set -f %1.cpp -l %2 in CommandObjectCommandsAlias()
320 "For more complex aliasing, use the \"command regex\" command instead. In the \ in CommandObjectCommandsAlias()
326 (lldb) command alias bfl breakpoint set -f %1 -l %2 in CommandObjectCommandsAlias()
333 (lldb) command alias pltty process launch -s -o %1 -e %1 in CommandObjectCommandsAlias()
344 (lldb) command alias bl3 breakpoint set -f %1 -l 3 in CommandObjectCommandsAlias()
391 result.AppendError("'command alias' requires at least two arguments"); in DoExecute()
409 result.AppendError("'command alias' requires at least two arguments"); in DoExecute()
413 // Get the alias command. in DoExecute()
419 result.AppendWarning("if trying to pass options to 'command alias' add " in DoExecute()
434 result.AppendError("Error parsing command string. No alias created."); in DoExecute()
438 // Verify that the command is alias-able. in DoExecute()
441 "'%s' is a permanent debugger command and cannot be redefined.\n", in DoExecute()
448 "'%s' is a user container command and cannot be overwritten.\n" in DoExecute()
449 "Delete it first with 'command container delete'\n", in DoExecute()
454 // Get CommandObject that is being aliased. The command name is read from in DoExecute()
456 // name of the command object stripped off the front. in DoExecute()
462 result.AppendErrorWithFormat("invalid command given to 'command alias'. " in DoExecute()
463 "'%s' does not begin with a valid command." in DoExecute()
468 // Note that args was initialized with the original command, and has not in DoExecute()
483 // Verify & handle any options/arguments passed to the alias command in HandleAliasingRawCommand()
489 // Look up the command using command's name first. This is to resolve in HandleAliasingRawCommand()
521 result.AppendError("'command alias' requires at least two arguments"); in HandleAliasingNormalCommand()
529 args.Shift(); // Shift the alias command word off the argument vector. in HandleAliasingNormalCommand()
530 args.Shift(); // Shift the old command word off the argument vector. in HandleAliasingNormalCommand()
532 // Verify that the command is alias'able, and get the appropriate command in HandleAliasingNormalCommand()
537 "'%s' is a permanent debugger command and cannot be redefined.\n", in HandleAliasingNormalCommand()
544 "'%s' is user container command and cannot be overwritten.\n" in HandleAliasingNormalCommand()
545 "Delete it first with 'command container delete'", in HandleAliasingNormalCommand()
555 result.AppendErrorWithFormat("'%s' is not an existing command.\n", in HandleAliasingNormalCommand()
570 "'%s' is not a valid sub-command of '%s'. " in HandleAliasingNormalCommand()
582 // Verify & handle any options/arguments passed to the alias command in HandleAliasingNormalCommand()
625 interpreter, "command unalias", in CommandObjectCommandsUnalias()
626 "Delete one or more custom commands defined by 'command alias'.", in CommandObjectCommandsUnalias()
670 "'%s' is not a known command.\nTry 'help' to see a " in DoExecute()
679 "'%s' is not an alias, it is a debugger command which can be " in DoExecute()
680 "removed using the 'command delete' command.\n", in DoExecute()
684 "'%s' is a permanent debugger command and cannot be removed.\n", in DoExecute()
713 interpreter, "command delete", in CommandObjectCommandsDelete()
714 "Delete one or more custom commands defined by 'command regex'.", in CommandObjectCommandsDelete()
751 "defined regular expression command names", in DoExecute()
770 "'%s' is a permanent debugger command and cannot be removed.\n", in DoExecute()
792 interpreter, "command regex", in CommandObjectCommandsAddRegex()
793 "Define a custom command in terms of " in CommandObjectCommandsAddRegex()
796 "command regex <cmd-name> [s/<regex>/<subst>/ ...]"), in CommandObjectCommandsAddRegex()
802 "This command allows the user to create powerful regular expression commands \ in CommandObjectCommandsAddRegex()
816 "The regular expressions can all be specified on the command line if more than \ in CommandObjectCommandsAddRegex()
817 one argument is provided. If just the command name is provided on the command \ in CommandObjectCommandsAddRegex()
819 lines, followed by an empty line to terminate the command definition." in CommandObjectCommandsAddRegex()
825 "The following example will define a regular expression command named 'f' that \ in CommandObjectCommandsAddRegex()
830 (lldb) command regex f s/^$/finish/ 's/([0-9]+)/frame select %1/')"); in CommandObjectCommandsAddRegex()
872 bool DoExecute(Args &command, CommandReturnObject &result) override { in DoExecute() argument
873 const size_t argc = command.GetArgumentCount(); in DoExecute()
875 result.AppendError("usage: 'command regex <command-name> " in DoExecute()
881 auto name = command[0].ref(); in DoExecute()
904 for (auto &entry : command.entries().drop_front()) { in DoExecute()
928 "invalid regular expression command object for: '%.*s'", in AppendRegexSubstitution()
1068 // Instance variables to hold the values for command options.
1133 // Don't change the status if the command already set it... in DoExecute()
1218 // Don't change the status if the command already set it... in DoExecute()
1244 : CommandObjectParsed(interpreter, "command script import", in CommandObjectCommandsScriptImport()
1313 bool DoExecute(Args &command, CommandReturnObject &result) override { in DoExecute() argument
1314 if (command.empty()) { in DoExecute()
1315 result.AppendError("command script import needs one or more arguments"); in DoExecute()
1323 result.AppendError("command script import -c can only be specified " in DoExecute()
1324 "from a command file"); in DoExecute()
1329 for (auto &entry : command.entries()) { in DoExecute()
1338 // actually possible to craft a Python script that does other "command in DoExecute()
1341 // from the CommandObject itself, so that recursive command invocations in DoExecute()
1368 : CommandObjectParsed(interpreter, "command script add", in CommandObjectCommandsScriptAdd()
1369 "Add a scripted function as an LLDB command.", in CommandObjectCommandsScriptAdd()
1370 "Add a scripted function as an lldb command. " in CommandObjectCommandsScriptAdd()
1371 "If you provide a single argument, the command " in CommandObjectCommandsScriptAdd()
1372 "will be added at the root level of the command " in CommandObjectCommandsScriptAdd()
1375 "command, and the last element will be the new " in CommandObjectCommandsScriptAdd()
1376 "command name."), in CommandObjectCommandsScriptAdd()
1381 // This is one or more command names, which form the path to the command in CommandObjectCommandsScriptAdd()
1461 // Instance variables to hold the values for command options.
1492 "add python command.\n"); in IOHandlerInputComplete()
1504 error_sp->Printf("error: unable to add selected command: '%s'", in IOHandlerInputComplete()
1512 error_sp->Printf("error: unable to add selected command: '%s'", in IOHandlerInputComplete()
1520 "error: unable to create function, didn't add python command\n"); in IOHandlerInputComplete()
1524 error_sp->Printf("error: empty function, didn't add python command\n"); in IOHandlerInputComplete()
1529 "error: script interpreter missing, didn't add python command\n"); in IOHandlerInputComplete()
1536 bool DoExecute(Args &command, CommandReturnObject &result) override { in DoExecute() argument
1543 if (command.GetArgumentCount() == 0) { in DoExecute()
1544 result.AppendError("'command script add' requires at least one argument"); in DoExecute()
1562 command, true, path_error); in DoExecute()
1565 result.AppendErrorWithFormat("error in command path: %s", in DoExecute()
1572 m_cmd_name = std::string(command[0].ref()); in DoExecute()
1574 size_t num_args = command.GetArgumentCount(); in DoExecute()
1575 m_cmd_name = std::string(command[num_args - 1].ref()); in DoExecute()
1617 result.AppendErrorWithFormat("cannot add command: %s", in DoExecute()
1623 result.AppendErrorWithFormat("cannot add command: %s", in DoExecute()
1643 : CommandObjectParsed(interpreter, "command script list", in CommandObjectCommandsScriptList()
1649 bool DoExecute(Args &command, CommandReturnObject &result) override { in DoExecute() argument
1663 : CommandObjectParsed(interpreter, "command script clear", in CommandObjectCommandsScriptClear()
1669 bool DoExecute(Args &command, CommandReturnObject &result) override { in DoExecute() argument
1684 interpreter, "command script delete", in CommandObjectCommandsScriptDelete()
1685 "Delete a scripted command by specifying the path to the command.", in CommandObjectCommandsScriptDelete()
1690 // This is a list of command names forming the path to the command in CommandObjectCommandsScriptDelete()
1713 bool DoExecute(Args &command, CommandReturnObject &result) override { in DoExecute() argument
1715 llvm::StringRef root_cmd = command[0].ref(); in DoExecute()
1716 size_t num_args = command.GetArgumentCount(); in DoExecute()
1719 result.AppendErrorWithFormat("empty root command name"); in DoExecute()
1731 result.AppendErrorWithFormat("command '%s' not found.", in DoExecute()
1732 command[0].c_str()); in DoExecute()
1736 result.AppendErrorWithFormat("command '%s' is not a user command.", in DoExecute()
1737 command[0].c_str()); in DoExecute()
1741 result.AppendErrorWithFormat("command '%s' is a multi-word command.\n " in DoExecute()
1742 "Delete with \"command container delete\"", in DoExecute()
1743 command[0].c_str()); in DoExecute()
1747 if (command.GetArgumentCount() == 1) { in DoExecute()
1752 // We're deleting a command from a multiword command. Verify the command in DoExecute()
1756 GetCommandInterpreter().VerifyUserMultiwordCmdPath(command, true, in DoExecute()
1759 result.AppendErrorWithFormat("could not resolve command path: %s", in DoExecute()
1764 // This means that command only had a leaf command, so the container is in DoExecute()
1767 command[0].c_str()); in DoExecute()
1770 const char *leaf_cmd = command[num_args - 1].c_str(); in DoExecute()
1774 result.AppendErrorWithFormat("could not delete command '%s': %s", in DoExecute()
1782 out_stream << "Deleted command:"; in DoExecute()
1785 out_stream << command[idx].c_str(); in DoExecute()
1801 interpreter, "command script", in CommandObjectMultiwordCommandsScript()
1805 "command script <subcommand> [<subcommand-options>]") { in CommandObjectMultiwordCommandsScript()
1832 interpreter, "command container add", in CommandObjectCommandsContainerAdd()
1833 "Add a container command to lldb. Adding to built-" in CommandObjectCommandsContainerAdd()
1835 "command container add [[path1]...] container-name") { in CommandObjectCommandsContainerAdd()
1839 // This is one or more command names, which form the path to the command in CommandObjectCommandsContainerAdd()
1904 // Instance variables to hold the values for command options.
1910 bool DoExecute(Args &command, CommandReturnObject &result) override { in DoExecute() argument
1911 size_t num_args = command.GetArgumentCount(); in DoExecute()
1914 result.AppendError("no command was specified"); in DoExecute()
1919 // We're adding this as a root command, so use the interpreter. in DoExecute()
1920 const char *cmd_name = command.GetArgumentAtIndex(0); in DoExecute()
1928 result.AppendErrorWithFormat("error adding command: %s", in DoExecute()
1939 GetCommandInterpreter().VerifyUserMultiwordCmdPath(command, true, in DoExecute()
1943 result.AppendErrorWithFormat("error adding command: %s", in DoExecute()
1948 const char *cmd_name = command.GetArgumentAtIndex(num_args - 1); in DoExecute()
1974 interpreter, "command container delete", in CommandObjectCommandsContainerDelete()
1975 "Delete a container command previously added to " in CommandObjectCommandsContainerDelete()
1977 "command container delete [[path1] ...] container-cmd") { in CommandObjectCommandsContainerDelete()
1981 // This is one or more command names, which form the path to the command in CommandObjectCommandsContainerDelete()
2004 bool DoExecute(Args &command, CommandReturnObject &result) override { in DoExecute() argument
2005 size_t num_args = command.GetArgumentCount(); in DoExecute()
2008 result.AppendError("No command was specified."); in DoExecute()
2013 // We're removing a root command, so we need to delete it from the in DoExecute()
2015 const char *cmd_name = command.GetArgumentAtIndex(0); in DoExecute()
2020 result.AppendErrorWithFormat("container command %s doesn't exist.", in DoExecute()
2026 "container command %s is not a user command", cmd_name); in DoExecute()
2030 result.AppendErrorWithFormat("command %s is not a container command", in DoExecute()
2037 result.AppendErrorWithFormat("error removing command %s.", cmd_name); in DoExecute()
2048 GetCommandInterpreter().VerifyUserMultiwordCmdPath(command, true, in DoExecute()
2052 result.AppendErrorWithFormat("error removing container command: %s", in DoExecute()
2056 const char *leaf = command.GetArgumentAtIndex(num_args - 1); in DoExecute()
2060 result.AppendErrorWithFormat("error removing container command: %s", in DoExecute()
2073 interpreter, "command container", in CommandObjectCommandContainer()
2076 "add nested container commands by specifying a command path, " in CommandObjectCommandContainer()
2077 "but you can't add commands into the built-in command hierarchy.", in CommandObjectCommandContainer()
2078 "command container <subcommand> [<subcommand-options>]") { in CommandObjectCommandContainer()
2095 : CommandObjectMultiword(interpreter, "command", in CommandObjectMultiwordCommands()
2097 "command <subcommand> [<subcommand-options>]") { in CommandObjectMultiwordCommands()