Skip to content

Coordinated fix on Feb 12 broke Windows path handling between node-glob and minimatch #471

@jsuddsjr

Description

@jsuddsjr

When using allowWindowsEscape=true in minimatch options, glob is forcing minimatch to treat the path as though it contained escapes rather than Windows path separators (backslashes). Notice the negation in the following statement, which would entirely fix the issue if it were allowed to run.

  if (!options.allowWindowsEscape && path.sep !== '/') {
    pattern = pattern.split(path.sep).join('/')
  }

Therefore, glob@7.2.2 combined with minimatch@^3.1.1 cannot locate files using patterns like:

E:\\Src\\repo\\packages\\test\\.storybook\\main{'.js','.jsx'}

Unfortunately, this is causing the latest version of Storybook to fail to locate configuration files in its default state in Windows. Error: No configuration files have been found in your configDir.

Please coordinate another fix.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions