Merge pull request 'add drive root check, version bump' (#41) from waffle.lord/SPT-AKI-Installer:add-root-drive-detection into master
Reviewed-on: CWX/SPT-AKI-Installer#41
This commit is contained in:
commit
1a300b639a
@ -148,6 +148,7 @@ public static class FileHelper
|
|||||||
{
|
{
|
||||||
EndsWith = 0,
|
EndsWith = 0,
|
||||||
Contains = 1,
|
Contains = 1,
|
||||||
|
DriveRoot = 2
|
||||||
}
|
}
|
||||||
|
|
||||||
public static bool CheckPathForProblemLocations(string path, out string detectedName)
|
public static bool CheckPathForProblemLocations(string path, out string detectedName)
|
||||||
@ -162,6 +163,7 @@ public static class FileHelper
|
|||||||
{ "NextCloud", PathCheckType.Contains },
|
{ "NextCloud", PathCheckType.Contains },
|
||||||
{ "DropBox", PathCheckType.Contains },
|
{ "DropBox", PathCheckType.Contains },
|
||||||
{ "Google", PathCheckType.Contains },
|
{ "Google", PathCheckType.Contains },
|
||||||
|
{ "Drive Root", PathCheckType.DriveRoot}
|
||||||
};
|
};
|
||||||
|
|
||||||
foreach (var name in problemNames)
|
foreach (var name in problemNames)
|
||||||
@ -182,7 +184,12 @@ public static class FileHelper
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
default:
|
case PathCheckType.DriveRoot:
|
||||||
|
if (Regex.Match(path.ToLower(), @"^\w:(\\|\/)$").Success)
|
||||||
|
{
|
||||||
|
detectedName = name.Key;
|
||||||
|
return true;
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -9,8 +9,8 @@
|
|||||||
<PackageIcon>icon.ico</PackageIcon>
|
<PackageIcon>icon.ico</PackageIcon>
|
||||||
<ApplicationIcon>Assets\icon.ico</ApplicationIcon>
|
<ApplicationIcon>Assets\icon.ico</ApplicationIcon>
|
||||||
<Configurations>Debug;Release;TEST</Configurations>
|
<Configurations>Debug;Release;TEST</Configurations>
|
||||||
<AssemblyVersion>2.20</AssemblyVersion>
|
<AssemblyVersion>2.21</AssemblyVersion>
|
||||||
<FileVersion>2.20</FileVersion>
|
<FileVersion>2.21</FileVersion>
|
||||||
<Company>SPT-AKI</Company>
|
<Company>SPT-AKI</Company>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user