(value: string)
| 282 | } |
| 283 | |
| 284 | function shouldConsumeOptionalPathValue(value: string): boolean { |
| 285 | const trimmed = value.trim(); |
| 286 | if (!trimmed) return false; |
| 287 | if (/^[a-zA-Z][a-zA-Z0-9+.-]*:\/\//.test(trimmed)) return false; |
| 288 | if ( |
| 289 | trimmed.startsWith('./') || |
| 290 | trimmed.startsWith('../') || |
| 291 | trimmed.startsWith('~/') || |
| 292 | trimmed.startsWith('/') |
| 293 | ) { |
| 294 | return true; |
| 295 | } |
| 296 | if (trimmed.includes('/') || trimmed.includes('\\')) return true; |
| 297 | return false; |
| 298 | } |
| 299 | |
| 300 | function shouldTreatUnknownDashTokenAsPositional( |
| 301 | command: string | null, |
no test coverage detected