Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Auto-detect Dart SDK in preference page does not work for existing workspace #83

Closed
vogella opened this issue Jul 8, 2019 · 2 comments
Labels
up-for-grabs Contributions are welcome

Comments

@vogella
Copy link
Contributor

vogella commented Jul 8, 2019

As discussed if I start Eclipse for an existing workspace, the Dart SDK is wrongly configured as the WS location.

To test: Delete Dart SDK and restart Eclipse, check preference page.

@vogella vogella added the up-for-grabs Contributions are welcome label Jul 8, 2019
@lak-proddev
Copy link
Contributor

Some how Files.exist returns true for emply location

Path path = Paths.get(location);
Files.exists(path)

lak-proddev added a commit to lak-proddev/dartboard that referenced this issue Jul 9, 2019
lak-proddev added a commit to lak-proddev/dartboard that referenced this issue Jul 9, 2019
@jonas-jonas
Copy link
Member

Some how Files.exist returns true for emply location

In my experience it returns true for all files and directories. That being said, if the input is empty it just uses the current working directory (in this case the workspace location). Both of these problems can be fixed if I find a way to verify that the entered file is a valid Dart SDK executable. Though I'm not sure about the best way to do this.

  1. We could check the output of /entered/path --version with a pattern (as it will contain the phrase Dart VM version...)
  2. Somehow check the signature of the file.

Currently, I'm favoring 1. but I'm not sure how future proof this is, as the output could change and thus require us to change the pattern to match it again.

lak-proddev added a commit to lak-proddev/dartboard that referenced this issue Jul 9, 2019
lak-proddev added a commit to lak-proddev/dartboard that referenced this issue Jul 9, 2019
existing workspace eclipse#83"

This reverts commit 00a495e.

Signed-off-by: Lakshminarayana Nekkanti <[email protected]>
jonas-jonas pushed a commit that referenced this issue Jul 9, 2019
jonas-jonas pushed a commit that referenced this issue Jul 12, 2019
closes #83

Signed-off-by: Jonas Hungershausen <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
up-for-grabs Contributions are welcome
Projects
None yet
Development

No branches or pull requests

3 participants