(a: string, b: string)
| 1433 | const suffixes = [`${base}.lua`, `${base}.luau`, `${base}/init.lua`, `${base}/init.luau`]; |
| 1434 | const files = context.getAllFiles(); |
| 1435 | const shared = (a: string, b: string): number => { |
| 1436 | let i = 0; |
| 1437 | while (i < a.length && i < b.length && a[i] === b[i]) i++; |
| 1438 | return i; |
| 1439 | }; |
| 1440 | for (const suffix of suffixes) { |
| 1441 | const matches = files.filter((f) => f === suffix || f.endsWith('/' + suffix)); |
| 1442 | if (matches.length === 0) continue; |