Implement support for mono (#806)

* Initial buggy mono support

* Start building generic-netf variant

* Fix CIs

* Disable ILLink.Tasks for generic-netf

* Make generic-netf *special*

* Keep fixing

Don't ask me why reverse order works, this is next-gen msbuild magic

* Mono compat

* Mono compat

* Misc

* Update to .NET Framework 4.7.2

* .NET 4.7.2 compat

* Misc
This commit is contained in:
Łukasz Domeradzki
2018-06-03 07:51:20 +02:00
committed by GitHub
parent 56d48ae210
commit a515de5807
14 changed files with 174 additions and 36 deletions

View File

@@ -257,7 +257,7 @@ namespace ArchiSteamFarm {
GlobalConfig globalConfig;
try {
globalConfig = JsonConvert.DeserializeObject<GlobalConfig>(await File.ReadAllTextAsync(filePath).ConfigureAwait(false));
globalConfig = JsonConvert.DeserializeObject<GlobalConfig>(await RuntimeCompatibility.File.ReadAllTextAsync(filePath).ConfigureAwait(false));
} catch (Exception e) {
ASF.ArchiLogger.LogGenericException(e);
return null;
@@ -314,7 +314,7 @@ namespace ArchiSteamFarm {
await WriteSemaphore.WaitAsync().ConfigureAwait(false);
try {
await File.WriteAllTextAsync(newFilePath, json).ConfigureAwait(false);
await RuntimeCompatibility.File.WriteAllTextAsync(newFilePath, json).ConfigureAwait(false);
if (File.Exists(filePath)) {
File.Replace(newFilePath, filePath, null);