mirror of
https://github.com/immense/Remotely.git
synced 2025-10-26 11:27:15 +00:00
Add namespaces to Program.cs. Make publish locations runtime-agnostic.
This commit is contained in:
parent
6fc0d98dd0
commit
3f28faba39
@ -16,6 +16,8 @@ using Avalonia;
|
||||
using Immense.RemoteControl.Desktop.UI;
|
||||
using Desktop.Shared.Services;
|
||||
|
||||
namespace Remotely.Desktop.XPlat;
|
||||
|
||||
public class Program
|
||||
{
|
||||
// This is needed for the visual designer to work.
|
||||
@ -105,4 +107,4 @@ public class Program
|
||||
}
|
||||
catch (TaskCanceledException) { }
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -8,7 +8,7 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
<TargetFramework>net7.0</TargetFramework>
|
||||
<PublishDir>..\Agent\bin\Release\net7.0\linux-x64\publish\Desktop</PublishDir>
|
||||
<PublishDir>..\Agent\bin\publish\linux-x64\Desktop</PublishDir>
|
||||
<RuntimeIdentifier>linux-x64</RuntimeIdentifier>
|
||||
<SelfContained>true</SelfContained>
|
||||
<PublishSingleFile>False</PublishSingleFile>
|
||||
|
||||
@ -15,6 +15,8 @@ using Avalonia;
|
||||
using Immense.RemoteControl.Desktop.UI;
|
||||
using Desktop.Shared.Services;
|
||||
|
||||
namespace Remotely.Desktop.Win;
|
||||
|
||||
public class Program
|
||||
{
|
||||
// This is needed for the visual designer to work.
|
||||
@ -95,4 +97,4 @@ public class Program
|
||||
}
|
||||
catch (TaskCanceledException) { }
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -8,7 +8,7 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
<TargetFramework>net7.0</TargetFramework>
|
||||
<PublishDir>..\Agent\bin\Release\net7.0\win-x64\publish\Desktop</PublishDir>
|
||||
<PublishDir>..\Agent\bin\publish\win-x64\Desktop</PublishDir>
|
||||
<SelfContained>true</SelfContained>
|
||||
<RuntimeIdentifier>win-x64</RuntimeIdentifier>
|
||||
<PublishSingleFile>True</PublishSingleFile>
|
||||
|
||||
@ -8,7 +8,7 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
<TargetFramework>net7.0</TargetFramework>
|
||||
<PublishDir>..\Agent\bin\Release\net7.0\win-x64\publish\Desktop</PublishDir>
|
||||
<PublishDir>..\Agent\bin\publish\win-x64\Desktop</PublishDir>
|
||||
<SelfContained>true</SelfContained>
|
||||
<RuntimeIdentifier>win-x64</RuntimeIdentifier>
|
||||
<PublishSingleFile>false</PublishSingleFile>
|
||||
|
||||
@ -8,7 +8,7 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x86</Platform>
|
||||
<TargetFramework>net7.0</TargetFramework>
|
||||
<PublishDir>..\Agent\bin\Release\net7.0\win-x86\publish\Desktop</PublishDir>
|
||||
<PublishDir>..\Agent\bin\publish\win-x86\Desktop</PublishDir>
|
||||
<RuntimeIdentifier>win-x86</RuntimeIdentifier>
|
||||
<SelfContained>true</SelfContained>
|
||||
<PublishSingleFile>False</PublishSingleFile>
|
||||
|
||||
@ -1,18 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
https://go.microsoft.com/fwlink/?LinkID=208121.
|
||||
-->
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<PublishProtocol>FileSystem</PublishProtocol>
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
<TargetFramework>net7.0-windows</TargetFramework>
|
||||
<PublishDir>bin\Release\win-x64\publish\</PublishDir>
|
||||
<SelfContained>true</SelfContained>
|
||||
<RuntimeIdentifier>win-x64</RuntimeIdentifier>
|
||||
<PublishSingleFile>False</PublishSingleFile>
|
||||
<PublishReadyToRun>False</PublishReadyToRun>
|
||||
<PublishTrimmed>True</PublishTrimmed>
|
||||
</PropertyGroup>
|
||||
</Project>
|
||||
@ -1,18 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
https://go.microsoft.com/fwlink/?LinkID=208121.
|
||||
-->
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<PublishProtocol>FileSystem</PublishProtocol>
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x86</Platform>
|
||||
<TargetFramework>net7.0</TargetFramework>
|
||||
<PublishDir>bin\Release\win-x86\publish\</PublishDir>
|
||||
<SelfContained>true</SelfContained>
|
||||
<RuntimeIdentifier>win-x86</RuntimeIdentifier>
|
||||
<PublishSingleFile>False</PublishSingleFile>
|
||||
<PublishReadyToRun>False</PublishReadyToRun>
|
||||
<PublishTrimmed>True</PublishTrimmed>
|
||||
</PropertyGroup>
|
||||
</Project>
|
||||
@ -92,25 +92,25 @@ if ([string]::IsNullOrWhiteSpace($MSBuildPath) -or !(Test-Path -Path $MSBuildPat
|
||||
|
||||
|
||||
# Clear publish folders.
|
||||
if ((Test-Path -Path "$Root\Agent\bin\Release\net7.0\win-x64\publish") -eq $true) {
|
||||
Get-ChildItem -Path "$Root\Agent\bin\Release\net7.0\win-x64\publish" | Remove-Item -Force -Recurse
|
||||
if ((Test-Path -Path "$Root\Agent\bin\publish\win-x64") -eq $true) {
|
||||
Get-ChildItem -Path "$Root\Agent\bin\publish\win-x64" | Remove-Item -Force -Recurse
|
||||
}
|
||||
if ((Test-Path -Path "$Root\Agent\bin\Release\net7.0\win-x86\publish" ) -eq $true) {
|
||||
Get-ChildItem -Path "$Root\Agent\bin\Release\net7.0\win-x86\publish" | Remove-Item -Force -Recurse
|
||||
if ((Test-Path -Path "$Root\Agent\bin\publish\win-x86" ) -eq $true) {
|
||||
Get-ChildItem -Path "$Root\Agent\bin\publish\win-x86" | Remove-Item -Force -Recurse
|
||||
}
|
||||
if ((Test-Path -Path "$Root\Agent\bin\Release\net7.0\linux-x64\publish") -eq $true) {
|
||||
Get-ChildItem -Path "$Root\Agent\bin\Release\net7.0\linux-x64\publish" | Remove-Item -Force -Recurse
|
||||
if ((Test-Path -Path "$Root\Agent\bin\publish\linux-x64") -eq $true) {
|
||||
Get-ChildItem -Path "$Root\Agent\bin\publish\linux-x64" | Remove-Item -Force -Recurse
|
||||
}
|
||||
|
||||
|
||||
# Publish Core clients.
|
||||
dotnet publish /p:Version=$CurrentVersion /p:FileVersion=$CurrentVersion --runtime win-x64 --self-contained --configuration Release --output "$Root\Agent\bin\Release\net7.0\win-x64\publish" "$Root\Agent"
|
||||
dotnet publish /p:Version=$CurrentVersion /p:FileVersion=$CurrentVersion --runtime linux-x64 --self-contained --configuration Release --output "$Root\Agent\bin\Release\net7.0\linux-x64\publish" "$Root\Agent"
|
||||
dotnet publish /p:Version=$CurrentVersion /p:FileVersion=$CurrentVersion --runtime win-x86 --self-contained --configuration Release --output "$Root\Agent\bin\Release\net7.0\win-x86\publish" "$Root\Agent"
|
||||
dotnet publish /p:Version=$CurrentVersion /p:FileVersion=$CurrentVersion --runtime win-x64 --self-contained --configuration Release --output "$Root\Agent\bin\publish\win-x64" "$Root\Agent"
|
||||
dotnet publish /p:Version=$CurrentVersion /p:FileVersion=$CurrentVersion --runtime linux-x64 --self-contained --configuration Release --output "$Root\Agent\bin\publish\linux-x64" "$Root\Agent"
|
||||
dotnet publish /p:Version=$CurrentVersion /p:FileVersion=$CurrentVersion --runtime win-x86 --self-contained --configuration Release --output "$Root\Agent\bin\publish\win-x86" "$Root\Agent"
|
||||
|
||||
New-Item -Path "$Root\Agent\bin\Release\net7.0\win-x64\publish\Desktop\" -ItemType Directory -Force
|
||||
New-Item -Path "$Root\Agent\bin\Release\net7.0\win-x86\publish\Desktop\" -ItemType Directory -Force
|
||||
New-Item -Path "$Root\Agent\bin\Release\net7.0\linux-x64\publish\Desktop\" -ItemType Directory -Force
|
||||
New-Item -Path "$Root\Agent\bin\publish\win-x64\Desktop\" -ItemType Directory -Force
|
||||
New-Item -Path "$Root\Agent\bin\publish\win-x86\Desktop\" -ItemType Directory -Force
|
||||
New-Item -Path "$Root\Agent\bin\publish\linux-x64\Desktop\" -ItemType Directory -Force
|
||||
|
||||
|
||||
# Publish Linux ScreenCaster
|
||||
@ -155,7 +155,7 @@ if ($SignAssemblies) {
|
||||
}
|
||||
|
||||
# Compress Core clients.
|
||||
$PublishDir = "$Root\Agent\bin\Release\net7.0\win-x64\publish"
|
||||
$PublishDir = "$Root\Agent\bin\publish\win-x64"
|
||||
Compress-Archive -Path "$PublishDir\*" -DestinationPath "$PublishDir\Remotely-Win-x64.zip" -Force
|
||||
while ((Test-Path -Path "$PublishDir\Remotely-Win-x64.zip") -eq $false){
|
||||
Write-Host "Waiting for archive to finish: $PublishDir\Remotely-Win-x64.zip"
|
||||
@ -163,7 +163,7 @@ while ((Test-Path -Path "$PublishDir\Remotely-Win-x64.zip") -eq $false){
|
||||
}
|
||||
Move-Item -Path "$PublishDir\Remotely-Win-x64.zip" -Destination "$Root\Server\wwwroot\Content\Remotely-Win-x64.zip" -Force
|
||||
|
||||
$PublishDir = "$Root\Agent\bin\Release\net7.0\win-x86\publish"
|
||||
$PublishDir = "$Root\Agent\bin\publish\win-x86"
|
||||
Compress-Archive -Path "$PublishDir\*" -DestinationPath "$PublishDir\Remotely-Win-x86.zip" -Force
|
||||
while ((Test-Path -Path "$PublishDir\Remotely-Win-x86.zip") -eq $false){
|
||||
Write-Host "Waiting for archive to finish: $PublishDir\Remotely-Win-x86.zip"
|
||||
@ -171,7 +171,7 @@ while ((Test-Path -Path "$PublishDir\Remotely-Win-x86.zip") -eq $false){
|
||||
}
|
||||
Move-Item -Path "$PublishDir\Remotely-Win-x86.zip" -Destination "$Root\Server\wwwroot\Content\Remotely-Win-x86.zip" -Force
|
||||
|
||||
$PublishDir = "$Root\Agent\bin\Release\net7.0\linux-x64\publish"
|
||||
$PublishDir = "$Root\Agent\bin\publish\linux-x64"
|
||||
Compress-Archive -Path "$PublishDir\*" -DestinationPath "$PublishDir\Remotely-Linux.zip" -Force
|
||||
while ((Test-Path -Path "$PublishDir\Remotely-Linux.zip") -eq $false){
|
||||
Write-Host "Waiting for archive to finish: $PublishDir\Remotely-Win-x86.zip"
|
||||
|
||||
@ -1 +1 @@
|
||||
Subproject commit 7b16798dd39d3fd8e2877a380cc50d7c4e55eb4d
|
||||
Subproject commit 9395713ca70430b8b473cccb6fd63f888aeb6aa9
|
||||
Loading…
Reference in New Issue
Block a user