Let the user choose main class, when none is open #5536
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
In the VS Code, when attempting to start a program using the Run pane, without any file opened, the Run fails, as no main class is found.
This patch proposes to show a dialog so that the user can choose a main class. In case only one main class is found, it is selected automatically.
The intent behind the
getServerLookup()
->getServerServicesLookup()
change is to ensure the content of the default lookup is present incontext.getLspSession().getLookup()
only once. It is added there once in the session lookup, and is also part of the server lookup. So, the patch is instead using a subset of the server lookup that does not include the default lookup.^Add meaningful description above
By opening a pull request you confirm that, unless explicitly stated otherwise, the changes -
Please make sure (eg.
git log
) that all commits have a valid name and email address for you in the Author field.If you're a first time contributor, see the Contributing guidelines for more information.
If you're a committer, please label the PR before pressing "Create pull request" so that the right test jobs can run.