(pattern: string)
| 24 | } |
| 25 | |
| 26 | function workspacePackagePattern(pattern: string) { |
| 27 | const isNegated = pattern.startsWith('!'); |
| 28 | const workspacePattern = isNegated ? pattern.slice(1) : pattern; |
| 29 | const packageJsonPattern = workspacePattern.endsWith('/package.json') |
| 30 | ? workspacePattern |
| 31 | : `${workspacePattern.replace(/\/$/, '')}/package.json`; |
| 32 | |
| 33 | return isNegated ? `!${packageJsonPattern}` : packageJsonPattern; |
| 34 | } |
| 35 | |
| 36 | function packageJsonWorkspacePatterns(rootPackageJson: PackageJson) { |
| 37 | const workspaces: unknown = rootPackageJson.workspaces; |
nothing calls this directly
no outgoing calls
no test coverage detected