Skip to content

_isSdkDir has an incorrect check against version as a directory #811

@srawlins

Description

@srawlins

I can't find an installation of Dart where version is a directory, yet that is what is expected in _isSdkDir. This function used to (pre 0.1.0) just test whether a thing existed named version.

Indeed on my Mac Homebrew installation, version is a file:

$ file /usr/local/Cellar/dart/1.24.0-dev.6.9/libexec/version
/usr/local/Cellar/dart/1.24.0-dev.6.9/libexec/version: ASCII text
$ cat /usr/local/Cellar/dart/1.24.0-dev.6.9/libexec/version
1.24.0-dev.6.9

Metadata

Metadata

Assignees

No one assigned

    Labels

    package:cli_utiltype-bugIncorrect behavior (everything from a crash to more subtle misbehavior)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions