Commit 942a1fd
Fix project restore detection for nonstandard artifact locations
When a project doesn't place project.assets.json under <projDir>/obj/
(e.g. UseArtifactsOutput or projects like dotnet/fsharp with custom
output layout), the fallback MSBuild --getProperty call may itself fail.
Previously that failure was hard-coded to throw, making it impossible
to use fsdocs on such repos.
Following the maintainer suggestion from issue #592, change the
fallback so that:
- If MSBuild succeeds and reports an assets path that exists -> OK
- If MSBuild succeeds but the assets file doesn't exist -> fail fast
(project definitely not restored)
- If MSBuild fails (e.g. old SDK, nonstandard project) -> warn and
proceed, letting the cracking step produce the definitive error
Closes #592
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>1 parent cacabf3 commit 942a1fd
2 files changed
Lines changed: 21 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
| 15 | + | |
15 | 16 | | |
16 | 17 | | |
17 | 18 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
372 | 372 | | |
373 | 373 | | |
374 | 374 | | |
375 | | - | |
| 375 | + | |
376 | 376 | | |
377 | | - | |
378 | | - | |
| 377 | + | |
| 378 | + | |
| 379 | + | |
| 380 | + | |
| 381 | + | |
| 382 | + | |
| 383 | + | |
| 384 | + | |
| 385 | + | |
379 | 386 | | |
380 | | - | |
381 | | - | |
382 | | - | |
383 | | - | |
| 387 | + | |
| 388 | + | |
| 389 | + | |
| 390 | + | |
| 391 | + | |
| 392 | + | |
| 393 | + | |
| 394 | + | |
| 395 | + | |
| 396 | + | |
384 | 397 | | |
385 | 398 | | |
386 | 399 | | |
| |||
0 commit comments