BrettMayson / HEMTT

Build System for Arma 3
https://brettmayson.github.io/HEMTT
GNU General Public License v2.0
109 stars 40 forks source link

UNC Network paths no longer supported #266

Closed jonpas closed 4 years ago

jonpas commented 4 years ago

HEMTT Version: 0.7.4 (stable) Project: Any

Description:

Building a mod located on a UNC path fails.

Steps to reproduce:

Additional information:

Requires network shared drive.

HEMTT Output:

thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: PATH(IOPathError { source: Os { code: 3, kind: NotFound, message: "The system cannot find the path specified." }, path: "UNC\\10.0.2.2\\Work\\Arma 3\\Mods\\TheseusServices\\optionals\\weapons_hlc\\script_component.hpp" })', src\libcore\result.rs:1165:5
BrettMayson commented 4 years ago

no longer supported

Was this working with a previous version of HEMTT?

jonpas commented 4 years ago

Yes, it worked fine until I switched to 0.7.3(+).

jonpas commented 4 years ago

0.6.1 works correctly:

Path in 0.6.1:

\\?\UNC\10.0.2.2\Work\Arma 3\Mods\CBA_A3

same path in 0.7.2+ (presumably):

UNC\\10.0.2.2\Work\Arma 3\Mods\CBA_A3
jonpas commented 4 years ago

https://github.com/synixebrett/HEMTT/blob/792223aac803a0d85b235d319e75e7ff691dda76/src/files.rs#L28

This breaks it as shown in the above comment (removes leading \\?\). Why was this added?

It's failing for UNC paths because it's trying to replace:

E:\Arma 3\Mods\CBA_A3

in a path like this:

\\?\UNC\10.0.2.2\Work\Arma 3\Mods\CBA_A3