Skip to content

Commit e880c93

Browse files
authored
Merge pull request #79 from dotnetprojects/develop
Changing the build and deploy process
2 parents 0681825 + b81e431 commit e880c93

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+1191
-252
lines changed

.github/workflows/dotnet.yml

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
name: .NET
2+
3+
on:
4+
push:
5+
branches: [ master ]
6+
pull_request:
7+
branches: [ master ]
8+
9+
jobs:
10+
build:
11+
runs-on: windows-latest
12+
13+
steps:
14+
- name: Checkout
15+
uses: actions/checkout@v3
16+
with:
17+
submodules: false
18+
fetch-depth: 0
19+
20+
- name: Install .NET 8.0
21+
uses: actions/setup-dotnet@v3
22+
with:
23+
dotnet-version: '8.0.x'
24+
25+
- name: Restore dependencies
26+
run: dotnet restore ./Source/SVGImage/DotNetProjects.SVGImage.csproj
27+
28+
- name: GitVersion
29+
id: gitversion # step id used as reference for output values
30+
uses: roryprimrose/set-vs-sdk-project-version@v1.0.6
31+
with:
32+
projectFilter: './Source/SVGImage/*.SVGImage.csproj'
33+
version: '5.0.118'
34+
35+
- name: Update project version
36+
uses: roryprimrose/set-vs-sdk-project-version@v1.0.6
37+
with:
38+
projectFilter: './Source/SVGImage/*.SVGImage.csproj'
39+
version: '5.0.118'
40+
# version: ${{ steps.gitversion.outputs.NuGetVersionV2 }}
41+
assemblyVersion: ${{ steps.gitversion.outputs.AssemblySemVer }}
42+
fileVersion: ${{ steps.gitversion.outputs.MajorMinorPatch }}
43+
informationalVersion: ${{ steps.gitversion.outputs.InformationalVersion }}
44+
45+
- name: Build, Test, Pack, Publish
46+
shell: bash
47+
run: |
48+
dotnet tool install -g dotnet-releaser
49+
dotnet-releaser run --nuget-token "${{secrets.NUGET_API_KEY}}" --github-token "${{secrets.GITHUB_TOKEN}}" Source/dotnet-releaser.toml

.github/workflows/gh-pages.yml

Lines changed: 27 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,46 @@
11
# Your GitHub workflow file under .github/workflows/
2-
name: DocFX
3-
2+
# Trigger the action on push to master
43
on:
54
push:
65
branches:
76
- master
8-
7+
8+
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
9+
permissions:
10+
contents: read
11+
pages: write
12+
id-token: write
13+
14+
# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
15+
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
16+
concurrency:
17+
group: "pages"
18+
cancel-in-progress: false
19+
920
jobs:
1021
publish-docs:
22+
environment:
23+
name: github-pages
24+
url: ${{ steps.deployment.outputs.page_url }}
1125
runs-on: windows-latest
1226
steps:
1327
- name: Checkout
1428
uses: actions/checkout@v3
1529
- name: Dotnet Setup
1630
uses: actions/setup-dotnet@v3
1731
with:
18-
dotnet-version: 7.x
32+
dotnet-version: 8.x
1933

2034
- run: dotnet tool update -g docfx
2135
- run: docfx Docs/docfx.json
2236

23-
- name: Upload DocFX packages
24-
uses: actions/upload-artifact@v3
25-
with:
26-
name: docfx_site
27-
path: ${{ github.workspace }}/Docs/_site
28-
29-
- name: Deploy
30-
uses: peaceiris/actions-gh-pages@v3
37+
- name: Setup Pages
38+
uses: actions/configure-pages@v3
39+
- name: Upload artifact
40+
uses: actions/upload-pages-artifact@v2
3141
with:
32-
github_token: ${{ secrets.GITHUB_TOKEN }}
33-
publish_dir: Docs/_site
42+
# Upload entire repository
43+
path: 'Docs/_site'
44+
- name: Deploy to GitHub Pages
45+
id: deployment
46+
uses: actions/deploy-pages@v2

Docs/Readme.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ The SVGImage control library targets the following frameworks
1919
* .NET Framework, Version 4.7
2020
* .NET Framework, Version 4.8
2121
* .NET Core, Version 3.1
22-
* .NET 6 ~ 7
22+
* .NET 6 ~ 8
2323

2424
## License
2525
The SVGImage control library is relicensed under [MIT License](https://github.com/dotnetprojects/SVGImage/blob/master/LICENSE),

Docs/docfx.json

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
],
99
"src": "../Source/",
1010
"properties": {
11-
"TargetFramework": "netcoreapp3.1"
11+
"TargetFramework": "net8.0"
1212
}
1313
}
1414
],
@@ -55,6 +55,8 @@
5555
"_appFaviconPath": "images/dotnetprojects.png",
5656
"_enableDiagrams": true,
5757
"_enableSearch": true,
58+
"pdf": true,
59+
"pdfTocPage": true,
5860
"_appFooter": "<div class=\"d-flex flex-column flex-sm-row justify-content-between pt-1\"><p> &copy; 2020 - 2023 DotNetProjects</p><p>Made with <a href=\"https://dotnet.github.io/docfx\">DocFX</a></p></div>",
5961
"_gitContribute": {
6062
"repo": "https://github.com/dotnetprojects/SVGImage",
@@ -74,4 +76,4 @@
7476
"keepFileLink": false,
7577
"disableGitFeatures": false
7678
}
77-
}
79+
}

Docs/index.md

Lines changed: 23 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
## SVGImage
1+
# SVGImage
22
This is an SVG Image View Control for WPF applications.
33

44
Initially forked from: [SVGImage Control - CodeProject Article](https://www.codeproject.com/Articles/92434/SVGImage-Control)
@@ -8,6 +8,27 @@ Besides the bug fixes, new features are added including the following:
88
- Support of styles.
99
- Simple Animation support.
1010

11+
## Downloads
12+
The SVGImage is available as a single DLL in [NuGet Package](https://www.nuget.org/packages/DotNetProjects.SVGImage).
13+
The respository includes
14+
* **Tests:** For test tools, and
15+
* **Samples:** For sample applications
16+
* **Docs:** For the documentations (in markdown format).
17+
18+
The command lines installation options are: For the version `5.0.118`
19+
* **.NET CLI:** dotnet add package DotNetProjects.SVGImage --version 5.0.118
20+
* **Package Manager:** NuGet\Install-Package DotNetProjects.SVGImage -Version 5.0.118
21+
22+
For reference in projects use: For the version `5.0.118`
23+
```xml
24+
<PackageReference Include="DotNetProjects.SVGImage" Version="5.0.118" />
25+
```
26+
27+
## How to build
28+
The SVGImage build targets .NET6.0-Windows (and up), .Net Framework 4.x TFMs and .NET Core 3.1.
29+
* Use `Source/SVGImage.sln` in requires Visual Studio 2022 for complete build, or
30+
* Use `Source/SVGImage.VS2019.sln` in Visual Studio 2019 for .Net Frameworks and .NET Core 3.1.
31+
1132
## Framework support
1233
The SVGImage control library targets the following frameworks
1334
* .NET Framework, Version 4.0
@@ -16,7 +37,7 @@ The SVGImage control library targets the following frameworks
1637
* .NET Framework, Version 4.7
1738
* .NET Framework, Version 4.8
1839
* .NET Core, Version 3.1
19-
* .NET 6 ~ 7
40+
* .NET 6 ~ 8
2041

2142
## License
2243
The SVGImage control library is relicensed under [MIT License](https://github.com/dotnetprojects/SVGImage/blob/master/LICENSE),

README.md

Lines changed: 25 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
## SVGImage
1+
# SVGImage
22
This is an SVG Image View Control for WPF applications.
33

44
Initially forked from: [SVGImage Control - CodeProject Article](https://www.codeproject.com/Articles/92434/SVGImage-Control)
@@ -8,6 +8,27 @@ Besides the bug fixes, new features are added including the following:
88
- Support of styles.
99
- Simple Animation support.
1010

11+
## Downloads
12+
The SVGImage is available as a single DLL in [NuGet Package](https://www.nuget.org/packages/DotNetProjects.SVGImage).
13+
The respository includes
14+
* **Tests:** For test tools, and
15+
* **Samples:** For sample applications
16+
* **Docs:** For the documentations (in markdown format).
17+
18+
The command lines installation options are: For the version `5.0.118`
19+
* **.NET CLI:** dotnet add package DotNetProjects.SVGImage --version 5.0.118
20+
* **Package Manager:** NuGet\Install-Package DotNetProjects.SVGImage -Version 5.0.118
21+
22+
For reference in projects use: For the version `5.0.118`
23+
```xml
24+
<PackageReference Include="DotNetProjects.SVGImage" Version="5.0.118" />
25+
```
26+
27+
## How to build
28+
The SVGImage build targets .NET6.0-Windows (and up), .Net Framework 4.x TFMs and .NET Core 3.1.
29+
* Use `Source/SVGImage.sln` in requires Visual Studio 2022 for complete build, or
30+
* Use `Source/SVGImage.VS2019.sln` in Visual Studio 2019 for .Net Frameworks and .NET Core 3.1.
31+
1132
## Documentations
1233
For the User Manual and API References see [Documentation](http://dotnetprojects.github.io/SVGImage/).
1334

@@ -19,7 +40,7 @@ The SVGImage control library targets the following frameworks
1940
* .NET Framework, Version 4.7
2041
* .NET Framework, Version 4.8
2142
* .NET Core, Version 3.1
22-
* .NET 6 ~ 7
43+
* .NET 6 ~ 8
2344

2445
## License
2546
The SVGImage control library is relicensed under [MIT License](https://github.com/dotnetprojects/SVGImage/blob/master/LICENSE),
@@ -28,3 +49,5 @@ with permission from the original author.
2849
## Sample Application
2950

3051
![](Docs/images/sample.png)
52+
53+

Samples/ClipArtViewer/ClipArtViewer.csproj

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<Project Sdk="Microsoft.NET.Sdk.WindowsDesktop">
22
<PropertyGroup>
3-
<TargetFrameworks>net40;net45;net46;net47;net48;netcoreapp3.1;net6.0-windows;net7.0-windows</TargetFrameworks>
3+
<TargetFrameworks>net40;net45;net46;net47;net48;netcoreapp3.1;net6.0-windows;net7.0-windows;net8.0-windows</TargetFrameworks>
44
<OutputType>WinExe</OutputType>
55
<UseWPF>true</UseWPF>
66
<GenerateAssemblyInfo>false</GenerateAssemblyInfo>
@@ -17,11 +17,15 @@
1717
<DefineConstants>DEBUG;TRACE</DefineConstants>
1818
<WarningLevel>4</WarningLevel>
1919
<OutputPath>Output\</OutputPath>
20+
<!-- NOTE: The target framework 'netcoreapp3.1' is out of support -->
21+
<NoWarn>$(NoWarn);NETSDK1138</NoWarn>
2022
</PropertyGroup>
2123
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
2224
<DefineConstants>TRACE</DefineConstants>
2325
<WarningLevel>4</WarningLevel>
2426
<OutputPath>Output\</OutputPath>
27+
<!-- NOTE: The target framework 'netcoreapp3.1' is out of support -->
28+
<NoWarn>$(NoWarn);NETSDK1138</NoWarn>
2529
</PropertyGroup>
2630
<PropertyGroup>
2731
<ApplicationIcon>ClipArtViewer.ico</ApplicationIcon>
@@ -114,4 +118,12 @@
114118
<HintPath>..\..\Tests\Libs\net7.0-windows\Notifications.Wpf.dll</HintPath>
115119
</Reference>
116120
</ItemGroup>
121+
<ItemGroup Condition=" '$(TargetFramework)' == 'net8.0-windows'">
122+
<Reference Include="ShellFileDialogs">
123+
<HintPath>..\..\Tests\Libs\net8.0\ShellFileDialogs.dll</HintPath>
124+
</Reference>
125+
<Reference Include="Notifications.Wpf">
126+
<HintPath>..\..\Tests\Libs\net8.0-windows\Notifications.Wpf.dll</HintPath>
127+
</Reference>
128+
</ItemGroup>
117129
</Project>

Samples/CustomBrushesExample/CustomBrushesExample.csproj

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<Project Sdk="Microsoft.NET.Sdk.WindowsDesktop">
22
<PropertyGroup>
3-
<TargetFrameworks>net40;net45;net46;net47;net48;netcoreapp3.1;net6.0-windows;net7.0-windows</TargetFrameworks>
3+
<TargetFrameworks>net40;net45;net46;net47;net48;netcoreapp3.1;net6.0-windows;net7.0-windows;net8.0-windows</TargetFrameworks>
44
<OutputType>WinExe</OutputType>
55
<UseWPF>true</UseWPF>
66
<GenerateAssemblyInfo>false</GenerateAssemblyInfo>
@@ -13,10 +13,14 @@
1313
<DebugSymbols>true</DebugSymbols>
1414
<DefineConstants>DEBUG;TRACE</DefineConstants>
1515
<WarningLevel>4</WarningLevel>
16+
<!-- NOTE: The target framework 'netcoreapp3.1' is out of support -->
17+
<NoWarn>$(NoWarn);NETSDK1138</NoWarn>
1618
</PropertyGroup>
1719
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
1820
<DefineConstants>TRACE</DefineConstants>
1921
<WarningLevel>4</WarningLevel>
22+
<!-- NOTE: The target framework 'netcoreapp3.1' is out of support -->
23+
<NoWarn>$(NoWarn);NETSDK1138</NoWarn>
2024
</PropertyGroup>
2125
<PropertyGroup>
2226
<ApplicationIcon>CustomBrushesExample.ico</ApplicationIcon>

Samples/Example/Example.csproj

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<Project Sdk="Microsoft.NET.Sdk.WindowsDesktop">
22
<PropertyGroup>
3-
<TargetFrameworks>net40;net45;net46;net47;net48;netcoreapp3.1;net6.0-windows;net7.0-windows</TargetFrameworks>
3+
<TargetFrameworks>net40;net45;net46;net47;net48;netcoreapp3.1;net6.0-windows;net7.0-windows;net8.0-windows</TargetFrameworks>
44
<OutputType>WinExe</OutputType>
55
<UseWPF>true</UseWPF>
66
<GenerateAssemblyInfo>false</GenerateAssemblyInfo>
@@ -13,10 +13,14 @@
1313
<DebugSymbols>true</DebugSymbols>
1414
<DefineConstants>DEBUG;TRACE</DefineConstants>
1515
<WarningLevel>4</WarningLevel>
16+
<!-- NOTE: The target framework 'netcoreapp3.1' is out of support -->
17+
<NoWarn>$(NoWarn);NETSDK1138</NoWarn>
1618
</PropertyGroup>
1719
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
1820
<DefineConstants>TRACE</DefineConstants>
1921
<WarningLevel>4</WarningLevel>
22+
<!-- NOTE: The target framework 'netcoreapp3.1' is out of support -->
23+
<NoWarn>$(NoWarn);NETSDK1138</NoWarn>
2024
</PropertyGroup>
2125
<PropertyGroup>
2226
<ApplicationIcon>Example.ico</ApplicationIcon>
@@ -30,6 +34,7 @@
3034
<DefineConstants Condition="$(TargetFramework.StartsWith('netcore'))">$(DefineConstants);NETCORE</DefineConstants>
3135
<DefineConstants Condition="$(TargetFramework.StartsWith('net6'))">$(DefineConstants);NETCORE;NETNEXT</DefineConstants>
3236
<DefineConstants Condition="$(TargetFramework.StartsWith('net7'))">$(DefineConstants);NETCORE;NETNEXT</DefineConstants>
37+
<DefineConstants Condition="$(TargetFramework.StartsWith('net8'))">$(DefineConstants);NETCORE;NETNEXT</DefineConstants>
3338
</PropertyGroup>
3439
<ItemGroup>
3540
<None Remove="Images\rect.svg" />

Samples/IconConverterSample/IconConverterSample.csproj

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<Project Sdk="Microsoft.NET.Sdk.WindowsDesktop">
22
<PropertyGroup>
3-
<TargetFrameworks>net45;net46;net47;net48;netcoreapp3.1;net6.0-windows;net7.0-windows</TargetFrameworks>
3+
<TargetFrameworks>net45;net46;net47;net48;netcoreapp3.1;net6.0-windows;net7.0-windows;net8.0-windows</TargetFrameworks>
44
<OutputType>WinExe</OutputType>
55
<GenerateAssemblyInfo>false</GenerateAssemblyInfo>
66
<UseWPF>true</UseWPF>
@@ -23,16 +23,21 @@
2323
<DefineConstants Condition="$(TargetFramework.StartsWith('netcore'))">$(DefineConstants);NETCORE</DefineConstants>
2424
<DefineConstants Condition="$(TargetFramework.StartsWith('net6'))">$(DefineConstants);NETCORE;NETNEXT</DefineConstants>
2525
<DefineConstants Condition="$(TargetFramework.StartsWith('net7'))">$(DefineConstants);NETCORE;NETNEXT</DefineConstants>
26+
<DefineConstants Condition="$(TargetFramework.StartsWith('net8'))">$(DefineConstants);NETCORE;NETNEXT</DefineConstants>
2627
</PropertyGroup>
2728
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
2829
<DebugType>full</DebugType>
2930
<DebugSymbols>true</DebugSymbols>
3031
<DefineConstants>DEBUG;TRACE</DefineConstants>
3132
<OutputPath>Output\</OutputPath>
33+
<!-- NOTE: The target framework 'netcoreapp3.1' is out of support -->
34+
<NoWarn>$(NoWarn);NETSDK1138</NoWarn>
3235
</PropertyGroup>
3336
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
3437
<DefineConstants>TRACE</DefineConstants>
3538
<OutputPath>Output\</OutputPath>
39+
<!-- NOTE: The target framework 'netcoreapp3.1' is out of support -->
40+
<NoWarn>$(NoWarn);NETSDK1138</NoWarn>
3641
</PropertyGroup>
3742
<ItemGroup>
3843
<ProjectReference Include="..\..\Source\SVGImage\DotNetProjects.SVGImage.csproj" />

0 commit comments

Comments
 (0)