fixed warnings.
This commit is contained in:
parent
ebc776459d
commit
92b32975e8
@ -1,5 +1,4 @@
|
||||
using System;
|
||||
using System.Threading;
|
||||
|
||||
namespace KattekerCreator.Helper
|
||||
{
|
||||
|
@ -63,7 +63,7 @@ namespace KattekerCreator
|
||||
var additionalFiles = new[]
|
||||
{
|
||||
new PhysicalFile(appStubFile, Path.GetFileName(_appArguments.ProgramFile)),
|
||||
new PhysicalFile(configFile, Path.Combine($"app-{_assemblyFileInfo.AssemblyVersion}", Path.GetFileName(configFile)))
|
||||
new PhysicalFile(configFile, Path.Combine($"app-{_assemblyFileInfo.AssemblyVersion}", Path.GetFileName(configFile) ?? string.Empty))
|
||||
};
|
||||
var templateFile = GenerateNsisTemplate(additionalFiles);
|
||||
//Start makensis.exe
|
||||
|
@ -1,7 +1,6 @@
|
||||
<Application x:Class="Example.App"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:local="clr-namespace:Example"
|
||||
StartupUri="MainWindow.xaml">
|
||||
<Application.Resources>
|
||||
|
||||
|
@ -1,11 +1,9 @@
|
||||
using System.Windows;
|
||||
|
||||
namespace Example
|
||||
namespace Example
|
||||
{
|
||||
/// <summary>
|
||||
/// Interaction logic for App.xaml
|
||||
/// </summary>
|
||||
public partial class App : Application
|
||||
public partial class App
|
||||
{
|
||||
}
|
||||
}
|
||||
|
@ -3,7 +3,6 @@
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||
xmlns:local="clr-namespace:Example"
|
||||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||
Title="MainWindow"
|
||||
Width="800"
|
||||
|
@ -1,5 +1,4 @@
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
[assembly: AssemblyTitle("Katteker.Test")]
|
||||
|
@ -61,11 +61,15 @@ namespace Katteker
|
||||
try
|
||||
{
|
||||
using (var response = await webReq.GetResponseAsync().ConfigureAwait(false))
|
||||
using (var sr = new StreamReader(response.GetResponseStream()))
|
||||
{
|
||||
var responseStream = response.GetResponseStream();
|
||||
if (responseStream == null) return null;
|
||||
using (var sr = new StreamReader(responseStream))
|
||||
{
|
||||
return await sr.ReadToEndAsync().ConfigureAwait(false);
|
||||
}
|
||||
}
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
// ignore;
|
||||
|
@ -1,6 +1,7 @@
|
||||
using Semver;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Text.RegularExpressions;
|
||||
|
||||
namespace Katteker
|
||||
@ -29,7 +30,7 @@ namespace Katteker
|
||||
/// <summary>
|
||||
/// Construct release entry from string.
|
||||
/// </summary>
|
||||
/// <exception cref="ArgumentOutOfRangeException"></exception>
|
||||
/// <exception cref="FileLoadException"></exception>
|
||||
public ReleaseEntry(string line)
|
||||
{
|
||||
var elements = line?.Split(Seperator);
|
||||
@ -38,7 +39,7 @@ namespace Katteker
|
||||
Filename = elements[1];
|
||||
Filesize = long.Parse(elements[2]);
|
||||
var fileSegments = Regex.Match(Filename, FilenameRegex);
|
||||
if (fileSegments.Groups.Count < 3) throw new ArgumentOutOfRangeException("Filename is not compilant.");
|
||||
if (fileSegments.Groups.Count < 3) throw new FileLoadException("Filename not compilant.");
|
||||
ApplicationName = fileSegments.Groups[1].Value;
|
||||
Version = SemVersion.Parse(fileSegments.Groups[2].Value);
|
||||
IsDelta = fileSegments.Groups[3].Value != "full";
|
||||
|
Loading…
x
Reference in New Issue
Block a user