Thanks to visit codestin.com
Credit goes to github.com

Skip to content

[lldb] Add file path completion in for crashlog & process save-core#7015

Merged
JDevlieghere merged 4 commits intoswiftlang:swift/release/5.9from
medismailben:file-completion-improvements
Jun 20, 2023
Merged

[lldb] Add file path completion in for crashlog & process save-core#7015
JDevlieghere merged 4 commits intoswiftlang:swift/release/5.9from
medismailben:file-completion-improvements

Conversation

@medismailben
Copy link

This PR allows the user perform file path completion in lldb's command interpreter when using the process save-core command as well as custom (user-provided) commands such as crashlog.

This patch should allow the user to set specific auto-completion type
for their custom commands.

To do so, we had to hoist the `CompletionType` enum so the user can
access it and add a new completion type flag to the CommandScriptAdd
Command Object.

So now, the user can specify which completion type will be used with
their custom command, when they register it.

This also makes the `crashlog` custom commands use disk-file completion
type, to browse through the user file system and load the report.

Differential Revision: https://reviews.llvm.org/D152011

Signed-off-by: Med Ismail Bennani <[email protected]>
This patch should fix a crash in the opening a crash report that was
passed with a relative path.

This patch expands the crash report path before parsing it and raises a
`FileNotFoundError` exception if the file doesn't exist.

Differential Revision: https://reviews.llvm.org/D152012

Signed-off-by: Med Ismail Bennani <[email protected]>
This patch should fix path completion starting from the root directory.

To do so, this patch adds a special case when setting the search
directory when the completion buffer points to the root directory.

Differential Revision: https://reviews.llvm.org/D152013

Signed-off-by: Med Ismail Bennani <[email protected]>
This patch improves the way the user can save the process state into a
corefile by adding completion handler that would provide tab completion
for the corefile path and also resolves the corefile path to expand
relative path.

Differential Revision: https://reviews.llvm.org/D152842

Signed-off-by: Med Ismail Bennani <[email protected]>
@medismailben medismailben changed the base branch from next to swift/release/5.9 June 16, 2023 23:13
@medismailben
Copy link
Author

@swift-ci test

@JDevlieghere JDevlieghere merged commit 1567f02 into swiftlang:swift/release/5.9 Jun 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants