Commit debac39
committed
fix: guard drive-letter fallback with IS_WINDOWS to prevent Unix regression
The fallback path in cwdFromSlug() produced Windows-style `D:/...` paths
on Unix for slugs starting with a single letter (e.g. `D-Workspace-...`).
Gate the drive-letter fallback behind `IS_WINDOWS` so Unix correctly
returns `/D/Workspace/...`.
Also fix the test: make the Windows drive-letter fallback assertion
Windows-only (itWindows) and add a Unix counterpart asserting the
correct `/D/Workspace/project/alpha` result.1 parent bab2c4f commit debac39
2 files changed
Lines changed: 7 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
24 | | - | |
| 24 | + | |
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
28 | 33 | | |
29 | 34 | | |
30 | 35 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
61 | 61 | | |
62 | 62 | | |
63 | 63 | | |
64 | | - | |
| 64 | + | |
65 | 65 | | |
66 | 66 | | |
67 | 67 | | |
| |||
0 commit comments