mib created this revision.
mib added reviewers: JDevlieghere, teemperor.
Herald added subscribers: lldb-commits, mgorny.
Herald added a project: LLDB.
This patch introduces the `shell` command in lldb. It allows the user to run
shell builtins and binaries on the host without putting lldb in the ba
jingham added a comment.
I do something similar with CommandObjectThreadStepWithTypeAndScope so that I
can share most of that command code, if you want to see an example of doing
that.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D79659/new/
http
jingham added a comment.
We certainly shouldn't duplicate the code for CommandObjectPlatformShell.
Why don't you just add a "m_use_host_platform" ivar to
CommandObjectPlatformShell, and make two instances of
CommandObjectPlatformShell, one with m_use_host_platform set to false and added
as a s
mib updated this revision to Diff 262999.
mib added a comment.
With the first implementation, I thought it'd be a good idea to have separate
Command Objects for `platform shell` and `shell` because I was imagining the
latter could be more "powerful": `shell` could have an interactive mode like
mib updated this revision to Diff 263005.
mib edited the summary of this revision.
mib added a comment.
It looks like command options are not supported on aliases that already have
options:
(lldb) shell -t 1 -- sleep 5
zsh:1: command not found: -t
error: command returned with status 127
I
JDevlieghere added inline comments.
Comment at: lldb/source/Commands/CommandObjectPlatform.cpp:1625
+// When called from the `shell` alias with no argument, exit.
+if (args.GetRawPart().empty())
Is this only true for the alias?
Commen
mib marked an inline comment as done.
mib added inline comments.
Comment at: lldb/source/Commands/CommandObjectPlatform.cpp:1625
+// When called from the `shell` alias with no argument, exit.
+if (args.GetRawPart().empty())
JDevlieghere wrote:
> Is this
mib updated this revision to Diff 264270.
mib marked 2 inline comments as done.
mib added a comment.
Merged the `shell` and `platform shell` test as @JDevlieghere suggested it.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D79659/new/
https://review
JDevlieghere accepted this revision.
JDevlieghere added a comment.
LGTM
Comment at: lldb/source/Commands/CommandObjectPlatform.cpp:1590
+void OptionParsingStarting(ExecutionContext *execution_context) override {
+ m_use_host_platform = false;
+}
Sh
This revision was not accepted when it landed; it landed in state "Needs
Review".
This revision was automatically updated to reflect the committed changes.
mib marked an inline comment as done.
Closed by commit rG4e9e0488ab67: [lldb/Commands] Add ability to run shell
command on the host. (authore
10 matches
Mail list logo