Skip to content

Commit

Permalink
Merge pull request #152 from lacmus-foundation/releases/1.0.0
Browse files Browse the repository at this point in the history
Releases/1.0.0
  • Loading branch information
gosha20777 authored Apr 18, 2024
2 parents 6e33977 + 3f6e10d commit b91be36
Show file tree
Hide file tree
Showing 20 changed files with 118 additions and 77 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/dotnetcore.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
dotnet_version: ['6.0.x']
dotnet_version: ['8.0.x']
os: [ubuntu-latest, windows-latest, macOS-latest]

steps:
Expand Down
30 changes: 15 additions & 15 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
dotnet_version: ['6.0.x']
dotnet_version: ['8.0.x']
os:
- ubuntu-latest
steps:
Expand All @@ -20,19 +20,19 @@ jobs:
- run: cd src && dotnet build --configuration Release
- name: Create artifact linux
run: |
dotnet tool install --global dotnet-rpm
dotnet tool install --global dotnet-deb
dotnet tool install --global dotnet-tarball
dotnet tool install --global dotnet-rpm-net8
dotnet tool install --global dotnet-deb-net8
dotnet tool install --global dotnet-tarball-net8
echo "building packeges"
dotnet restore src/LacmusApp.sln
mkdir -p bin/linux
cd src/LacmusApp.Avalonia
dotnet rpm install
dotnet deb install
dotnet tarball install
dotnet rpm --framework net6.0 -c Release --runtime="linux-x64" -o ../../bin/linux LacmusApp.Avalonia.csproj
dotnet deb --framework net6.0 -c Release --runtime="linux-x64" -o ../../bin/linux LacmusApp.Avalonia.csproj
dotnet tarball --framework net6.0 -c Release --runtime="linux-x64" -o ../../bin/linux LacmusApp.Avalonia.csproj
dotnet rpm --framework net8.0 -c Release --runtime="linux-x64" -o ../../bin/linux LacmusApp.Avalonia.csproj
dotnet deb --framework net8.0 -c Release --runtime="linux-x64" -o ../../bin/linux LacmusApp.Avalonia.csproj
dotnet tarball --framework net8.0 -c Release --runtime="linux-x64" -o ../../bin/linux LacmusApp.Avalonia.csproj
shell: bash
- uses: actions/upload-artifact@v3
with:
Expand All @@ -53,24 +53,24 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
dotnet_version: ['6.0.x']
dotnet_version: ['8.0.x']
os:
- windows-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-dotnet@v1
- name: Create artifact windows
run: |
dotnet tool install --global dotnet-zip
dotnet tool install --global dotnet-zip-net8
echo "building packeges"
dotnet restore src/LacmusApp.sln
mkdir -p bin/windows
mkdir -p bin/windows/app
mkdir -p bin/windows/installer
cd src/LacmusApp.Avalonia
dotnet zip install
dotnet zip --framework net6.0 -c Release --runtime="win-x64" -o ../../bin/windows LacmusApp.Avalonia.csproj
dotnet publish --framework net6.0 -c Release --runtime="win-x64" -o ../../bin/windows/app LacmusApp.Avalonia.csproj
dotnet zip --framework net8.0 -c Release --runtime="win-x64" -o ../../bin/windows LacmusApp.Avalonia.csproj
dotnet publish --framework net8.0 -c Release --runtime="win-x64" -o ../../bin/windows/app LacmusApp.Avalonia.csproj
cd ../../
curl -L --output bin/windows/installer/temp.zip https://github.com/lacmus-foundation/inno-setup-gihtub-action/releases/download/v.1.0.0/innoSetupCli.zip
unzip bin/windows/installer/temp.zip -d bin/windows/installer
Expand All @@ -90,21 +90,21 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
dotnet_version: ['6.0.x']
dotnet_version: ['8.0.x']
os:
- osx-latest
- macOS-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-dotnet@v1
- name: Create artifact osx
run: |
bash packages/osx/build-osx.sh
dotnet tool install --global dotnet-tarball
dotnet tool install --global dotnet-tarball-net8
echo "building packeges"
dotnet restore src/LacmusApp.sln
cd src/LacmusApp.Avalonia
dotnet tarball install
dotnet tarball --framework net6.0 -c Release --runtime="osx-x64" -o ../../bin/osx LacmusApp.Avalonia.csproj
dotnet tarball --framework net8.0 -c Release --runtime="osx-x64" -o ../../bin/osx LacmusApp.Avalonia.csproj
shell: bash
- uses: actions/upload-artifact@v3
with:
Expand Down
6 changes: 3 additions & 3 deletions mk-release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@ rm -rf ./bin/app/ && \
echo "restoring packeges"
dotnet restore src/LacmusApp.sln
echo -n "building for linux"
dotnet publish --framework net6.0 --runtime="linux-x64" -c Release -o ./bin/app/linux src/LacmusApp.sln
dotnet publish --framework net8.0 --runtime="linux-x64" -c Release -o ./bin/app/linux src/LacmusApp.sln
mv ./bin/app/linux/LacmusApp.Avalonia ./bin/app/linux/LacmusApp
echo -n "building for win10"
dotnet publish --framework net6.0 --runtime="win10-x64" -c Release -o ./bin/app/win10 src/LacmusApp.sln
dotnet publish --framework net8.0 --runtime="win10-x64" -c Release -o ./bin/app/win10 src/LacmusApp.sln
mv ./bin/app/win10/LacmusApp.Avalonia.exe ./bin/app/win10/LacmusApp.exe
echo -n "building for osx"
dotnet publish --framework net6.0 --runtime="osx-x64" -c Release -o ./bin/app/osx src/LacmusApp.sln
dotnet publish --framework net8.0 --runtime="osx-x64" -c Release -o ./bin/app/osx src/LacmusApp.sln
mv ./bin/app/osx/LacmusApp.Avalonia ./bin/app/osx/LacmusApp
cd ./bin/app/
zip -r -9 ./linux.zip ./linux/
Expand Down
2 changes: 1 addition & 1 deletion packages/osx/build-osx.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ CERT_NAME="" # Name of certification to sign the application
echo "********** Start building $APP_NAME **********"

# Get application version
VERSION="0.7.0"
VERSION="1.0.0"
if [ "$?" != "0" ]; then
echo "Unable to get version of $APP_NAME"
exit
Expand Down
2 changes: 1 addition & 1 deletion packages/windows/script.iss
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#define MyAppName "Lacmus Application"
#define MyAppVersion "0.7.0"
#define MyAppVersion "1.0.0"
#define MyAppPublisher "Lacmus Foundation"
#define MyAppURL "https://lacmus.ml/"
#define MyAppExeName "LacmusApp.Avalonia.exe"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@ public VersionViewModel()
{
var revision = $"preview-{version?.Revision}";

Version = $"{version?.Major}.{version?.Minor}.{version?.Build} {revision} beta";
Version = $"{version?.Major}.{version?.Minor}.{version?.Build} {revision}";
}
else
{
Version = $"{version.Major}.{version.Minor}.{version.Build} beta";
Version = $"{version.Major}.{version.Minor}.{version.Build}";
}
}

Expand Down
9 changes: 9 additions & 0 deletions src/LacmusApp.Avalonia/Directory.Build.props
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<PackageReference Include="Packaging.Targets">
<Version>0.1.220-*</Version>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
</ItemGroup>
</Project>
36 changes: 23 additions & 13 deletions src/LacmusApp.Avalonia/LacmusApp.Avalonia.csproj
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net6.0</TargetFramework>
<TargetFramework>net8.0</TargetFramework>
<RuntimeIdentifiers>linux-x64;win-x64;osx-x64</RuntimeIdentifiers>
<Company>Lacmus Foundation</Company>
<AssemblyVersion>0.7.0</AssemblyVersion>
<FileVersion>0.7.0</FileVersion>
<Version>0.7.0</Version>
<AssemblyVersion>1.0.0</AssemblyVersion>
<FileVersion>1.0.0</FileVersion>
<Version>1.0.0</Version>
<Authors>gosha20777</Authors>
<Copyright>Copyright (c) Lacmus Foundation 2022</Copyright>
<Description>Lacmus help to find lost people in Search and Rescue operations. Lacmus is a cross-platform application which use computer vision and neural networks and written with C#, .NET Core, ReactiveUI and Avalonia.</Description>
Expand All @@ -22,8 +22,8 @@
<CFBundleName>Lacmus</CFBundleName> <!-- Also defines .app file name -->
<CFBundleDisplayName>Lacmus</CFBundleDisplayName>
<CFBundleIdentifier>com.example</CFBundleIdentifier>
<CFBundleVersion>0.7.0</CFBundleVersion>
<CFBundleShortVersionString>0.7.0</CFBundleShortVersionString>
<CFBundleVersion>1.0.0</CFBundleVersion>
<CFBundleShortVersionString>1.0.0</CFBundleShortVersionString>
<CFBundlePackageType>APPL</CFBundlePackageType>
<CFBundleExecutable>LacmusApp.Avalonia</CFBundleExecutable>
<CFBundleIconFile>..\..\packages\osx\LacmusApp.icns</CFBundleIconFile> <!-- Will be copied from output directory -->
Expand All @@ -48,18 +48,23 @@
</Compile>
</ItemGroup>
<ItemGroup>
<PackageReference Include="Avalonia" Version="0.10.17" />
<PackageReference Include="Avalonia.Controls.DataGrid" Version="0.10.17" />
<PackageReference Include="Avalonia" Version="0.10.22" />
<PackageReference Include="Avalonia.Controls.DataGrid" Version="0.10.22" />
<PackageReference Include="Avalonia.Controls.PanAndZoom" Version="10.14.0" />
<PackageReference Include="Avalonia.Desktop" Version="0.10.17" />
<PackageReference Include="Avalonia.Native" Version="0.10.17" />
<PackageReference Include="Avalonia.ReactiveUI" Version="0.10.17" />
<PackageReference Include="Avalonia.Desktop" Version="0.10.22" />
<PackageReference Include="Avalonia.Native" Version="0.10.22" />
<PackageReference Include="Avalonia.ReactiveUI" Version="0.10.22" />
<PackageReference Include="Citrus.Avalonia" Version="1.6.1" />
<PackageReference Include="Dotnet.Bundle" Version="0.9.13" />
<PackageReference Include="Flurl" Version="3.0.6" />
<PackageReference Include="HarfBuzzSharp" Version="2.8.2.5" />
<PackageReference Include="HarfBuzzSharp.NativeAssets.Linux" Version="2.8.2.5" />
<PackageReference Include="HarfBuzzSharp.NativeAssets.macOS" Version="2.8.2.5" />
<PackageReference Include="HarfBuzzSharp.NativeAssets.WebAssembly" Version="2.8.2.5" />
<PackageReference Include="HarfBuzzSharp.NativeAssets.Win32" Version="2.8.2.5" />
<PackageReference Include="LacmusPlugin" Version="2.0.3" />
<PackageReference Include="MessageBox.Avalonia" Version="2.0.2" />
<PackageReference Include="MetadataExtractor" Version="2.7.2" />
<PackageReference Include="MetadataExtractor" Version="2.8.1" />
<PackageReference Include="Microsoft.AspNetCore.Cryptography.KeyDerivation" Version="6.0.7" />
<PackageReference Include="NewtonSoft.Json" Version="13.0.1" />
<PackageReference Include="Octokit" Version="2.0.0" />
Expand All @@ -71,7 +76,12 @@
<PackageReference Include="Serilog" Version="2.11.0" />
<PackageReference Include="Serilog.Sinks.Console" Version="4.0.1" />
<PackageReference Include="Serilog.Sinks.File" Version="5.0.0" />
<PackageReference Include="SkiaSharp.QrCode" Version="0.6.0" />
<PackageReference Include="SkiaSharp" Version="2.88.8" />
<PackageReference Include="SkiaSharp.NativeAssets.Linux" Version="2.88.8" />
<PackageReference Include="SkiaSharp.NativeAssets.macOS" Version="2.88.8" />
<PackageReference Include="SkiaSharp.NativeAssets.WebAssembly" Version="2.88.8" />
<PackageReference Include="SkiaSharp.NativeAssets.Win32" Version="2.88.8" />
<PackageReference Include="SkiaSharp.QrCode" Version="0.7.0" />
<PackageReference Include="System.Diagnostics.PerformanceCounter" Version="6.0.1" />
</ItemGroup>
<ItemGroup>
Expand Down
7 changes: 3 additions & 4 deletions src/LacmusApp.Avalonia/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ internal static class Program
{
private static void Main(string[] args)
{
Console.WriteLine($"Lacmus desktop application. Version {GetVersion()} beta.");
Console.WriteLine($"Lacmus desktop application. Version {GetVersion()}.");
Console.WriteLine("Copyright (c) 2022 Lacmus Foundation <[email protected]>.");
Console.WriteLine("Github page: https://github.com/lacmus-foundation.");
Console.WriteLine("Powered by ODS <https://ods.ai>.");
Expand All @@ -33,10 +33,9 @@ private static void Main(string[] args)

public static string GetVersion()
{
var revision = "";
if (typeof(Program).Assembly.GetName().Version.Revision != 0)
revision = $"preview-{typeof(Program).Assembly.GetName().Version.Revision}";
return $"{typeof(Program).Assembly.GetName().Version.Major}.{typeof(Program).Assembly.GetName().Version.Minor}.{typeof(Program).Assembly.GetName().Version.Build}.{revision}";
return $"{typeof(Program).Assembly.GetName().Version.Major}.{typeof(Program).Assembly.GetName().Version.Minor}.{typeof(Program).Assembly.GetName().Version.Build} preview-{typeof(Program).Assembly.GetName().Version.Revision}";
return $"{typeof(Program).Assembly.GetName().Version.Major}.{typeof(Program).Assembly.GetName().Version.Minor}.{typeof(Program).Assembly.GetName().Version.Build}";
}

private static AppBuilder BuildAvaloniaApp()
Expand Down
9 changes: 6 additions & 3 deletions src/LacmusApp.Avalonia/Services/PhotoLoader.cs
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public async Task<PhotoViewModel[]> ReadAllFromDirByPhoto(LoadType loadType = Lo
using (var stream = File.OpenRead(path))
{
var (brush, height, width) = await reader.Read(stream);
var (metadata, latitude, longitude) = ExifConvertor.ConvertExif(
var (metadata, latitude, longitude, altitude) = ExifConvertor.ConvertExif(
ImageMetadataReader.ReadMetadata(path));
var photoViewModel = new PhotoViewModel(index)
{
Expand All @@ -63,6 +63,7 @@ public async Task<PhotoViewModel[]> ReadAllFromDirByPhoto(LoadType loadType = Lo
Name = GetNameFromPath(path),
Latitude = latitude,
Longitude = longitude,
Altitude = altitude,
ExifDataCollection = metadata
};
photoList.Add(photoViewModel);
Expand Down Expand Up @@ -109,7 +110,7 @@ public async Task<PhotoViewModel[]> ReadAllFromDirByAnnotation(LoadType loadType
using (var photoStream = File.OpenRead(photoPath))
{
var (brush, height, width) = await reader.Read(photoStream);
var (metadata, latitude, longitude) = ExifConvertor.ConvertExif(
var (metadata, latitude, longitude, altitude) = ExifConvertor.ConvertExif(
ImageMetadataReader.ReadMetadata(photoPath));
var photoViewModel = new PhotoViewModel(index)
{
Expand All @@ -121,6 +122,7 @@ public async Task<PhotoViewModel[]> ReadAllFromDirByAnnotation(LoadType loadType
Name = GetNameFromPath(photoPath),
Latitude = latitude,
Longitude = longitude,
Altitude = altitude,
ExifDataCollection = metadata
};
photoList.Add(photoViewModel);
Expand All @@ -147,7 +149,7 @@ public async Task<PhotoViewModel> LoadFromFile(string path, int index, IEnumerab
using (var photoStream = File.OpenRead(path))
{
var (brush, height, width) = await reader.ReadFromStream(photoStream);
var (metadata, latitude, longitude) = ExifConvertor.ConvertExif(
var (metadata, latitude, longitude, altitude) = ExifConvertor.ConvertExif(
ImageMetadataReader.ReadMetadata(path));
return new PhotoViewModel(index)
{
Expand All @@ -159,6 +161,7 @@ public async Task<PhotoViewModel> LoadFromFile(string path, int index, IEnumerab
Name = GetNameFromPath(path),
Latitude = latitude,
Longitude = longitude,
Altitude = altitude,
ExifDataCollection = metadata
};
}
Expand Down
3 changes: 2 additions & 1 deletion src/LacmusApp.Avalonia/ViewModels/FourthWizardViewModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ public async Task OpenFile(string inputPath)
await using (var stream = File.OpenRead(path))
{
var (brush, height, width) = await reader.Read(stream);
var (metadata, latitude, longitude) = ExifConvertor.ConvertExif(
var (metadata, latitude, longitude, altitude) = ExifConvertor.ConvertExif(
ImageMetadataReader.ReadMetadata(path));
var photoViewModel = new PhotoViewModel(id)
{
Expand All @@ -96,6 +96,7 @@ public async Task OpenFile(string inputPath)
Path = path,
Latitude = latitude,
Longitude = longitude,
Altitude = altitude,
ExifDataCollection = metadata
};

Expand Down
5 changes: 2 additions & 3 deletions src/LacmusApp.Avalonia/ViewModels/LoadingWindowViewModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -100,10 +100,9 @@ private async void Init()

private static string GetVersion()
{
var revision = "";
if (typeof(Program).Assembly.GetName().Version.Revision != 0)
revision = $"preview-{typeof(Program).Assembly.GetName().Version.Revision}";
return $"{typeof(Program).Assembly.GetName().Version.Major}.{typeof(Program).Assembly.GetName().Version.Minor}.{typeof(Program).Assembly.GetName().Version.Build}.{revision} beta";
return $"{typeof(Program).Assembly.GetName().Version.Major}.{typeof(Program).Assembly.GetName().Version.Minor}.{typeof(Program).Assembly.GetName().Version.Build} preview-{typeof(Program).Assembly.GetName().Version.Revision}";
return $"{typeof(Program).Assembly.GetName().Version.Major}.{typeof(Program).Assembly.GetName().Version.Minor}.{typeof(Program).Assembly.GetName().Version.Build}";
}
}
}
Loading

0 comments on commit b91be36

Please sign in to comment.