public async Task DownloadAppSignature(CancellationToken token) { ensureFileDeleted(_appOnlineSignatureFile); _updateAppDir.CreateDirectory(); var client = new YandexDiskClientWrapper(new YandexDiskClient(), _appSourceConfig.YandexKey); await client.TryDownloadFile(_appSourceConfig.FileListUrl, _appOnlineSignatureFile, token); AppOnlineSignature = getAppOnlineSignature(); }
public async Task DownloadApp(CancellationToken token) { var expectedSignature = AppOnlineSignature; FsPath appOnline = _updateAppDir.Join(expectedSignature.Path); ensureFileDeleted(appOnline); _updateAppDir.CreateDirectory(); var client = new YandexDiskClientWrapper(new YandexDiskClient(), _appSourceConfig.YandexKey); string url = string.Format(_appSourceConfig.ZipUrl, expectedSignature.Path); await client.TryDownloadFile(url, appOnline, token); }