Skip to content

Commit f630760

Browse files
committed
Initial commit
0 parents  commit f630760

File tree

73 files changed

+2517
-0
lines changed

Some content is hidden

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

73 files changed

+2517
-0
lines changed

.gitattributes

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
###############################################################################
2+
# Set default behavior to automatically normalize line endings.
3+
###############################################################################
4+
* text=auto
5+
6+
###############################################################################
7+
# Set default behavior for command prompt diff.
8+
#
9+
# This is need for earlier builds of msysgit that does not have it on by
10+
# default for csharp files.
11+
# Note: This is only used by command line
12+
###############################################################################
13+
#*.cs diff=csharp
14+
15+
###############################################################################
16+
# Set the merge driver for project and solution files
17+
#
18+
# Merging from the command prompt will add diff markers to the files if there
19+
# are conflicts (Merging from VS is not affected by the settings below, in VS
20+
# the diff markers are never inserted). Diff markers may cause the following
21+
# file extensions to fail to load in VS. An alternative would be to treat
22+
# these files as binary and thus will always conflict and require user
23+
# intervention with every merge. To do so, just uncomment the entries below
24+
###############################################################################
25+
#*.sln merge=binary
26+
#*.csproj merge=binary
27+
#*.vbproj merge=binary
28+
#*.vcxproj merge=binary
29+
#*.vcproj merge=binary
30+
#*.dbproj merge=binary
31+
#*.fsproj merge=binary
32+
#*.lsproj merge=binary
33+
#*.wixproj merge=binary
34+
#*.modelproj merge=binary
35+
#*.sqlproj merge=binary
36+
#*.wwaproj merge=binary
37+
38+
###############################################################################
39+
# behavior for image files
40+
#
41+
# image files are treated as binary by default.
42+
###############################################################################
43+
#*.jpg binary
44+
#*.png binary
45+
#*.gif binary
46+
47+
###############################################################################
48+
# diff behavior for common document formats
49+
#
50+
# Convert binary document formats to text before diffing them. This feature
51+
# is only available from the command line. Turn it on by uncommenting the
52+
# entries below.
53+
###############################################################################
54+
#*.doc diff=astextplain
55+
#*.DOC diff=astextplain
56+
#*.docx diff=astextplain
57+
#*.DOCX diff=astextplain
58+
#*.dot diff=astextplain
59+
#*.DOT diff=astextplain
60+
#*.pdf diff=astextplain
61+
#*.PDF diff=astextplain
62+
#*.rtf diff=astextplain
63+
#*.RTF diff=astextplain

.github/workflows/build-release.yml

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
name: Release
2+
on:
3+
release:
4+
types: [published]
5+
jobs:
6+
libjxl:
7+
name: Build libjxl
8+
runs-on: windows-2022
9+
permissions:
10+
contents: read
11+
strategy:
12+
matrix:
13+
arch: [x64-windows, arm64-windows]
14+
steps:
15+
- name: Checkout
16+
uses: actions/checkout@v4
17+
with:
18+
submodules: recursive
19+
fetch-depth: 2
20+
- name: Build libjxl
21+
run: |
22+
.\BuildLibJxl.ps1 ${{ matrix.arch }} .\libjxl\
23+
- name: Upload dlls
24+
uses: actions/upload-artifact@v4
25+
with:
26+
name: libjxl-${{ matrix.arch }}
27+
compression-level: 0
28+
path: |
29+
libjxl/build-${{ matrix.arch }}/lib/Release/*.dll
30+
libjxl/build-${{ matrix.arch }}/third_party/brotli/Release/*.dll
31+
build:
32+
name: NuGet
33+
runs-on: windows-2022
34+
needs: libjxl
35+
permissions:
36+
contents: read
37+
packages: write
38+
steps:
39+
- name: Checkout
40+
uses: actions/checkout@v4
41+
- name: Prepare Env
42+
uses: microsoft/setup-msbuild@v2
43+
- name: Download libjxl
44+
uses: actions/download-artifact@v4
45+
with:
46+
path: libjxl-dll
47+
- name: Publish nuget
48+
run: |
49+
Get-ChildItem -Path .\libjxl-dll\libjxl-x64-windows\*.dll -File -Recurse | Move-Item -Destination .\JxlNet\runtimes\win-x64\native
50+
Get-ChildItem -Path .\libjxl-dll\libjxl-arm64-windows\*.dll -File -Recurse | Move-Item -Destination .\JxlNet\runtimes\win-arm64\native
51+
dotnet pack --configuration Release
52+
dotnet nuget add source --username ${{ github.actor }} --password ${{ secrets.GITHUB_TOKEN }} --store-password-in-clear-text --name github "https://nuget.pkg.github.com/${{ github.actor }}/index.json"
53+
dotnet nuget push "$(Get-ChildItem JxlNet\bin\Release\*.nupkg)" --api-key ${{ secrets.GITHUB_TOKEN }} --source "github"
54+
- name: Upload nuget
55+
uses: actions/upload-artifact@v4
56+
with:
57+
name: nupkg
58+
path: |
59+
JxlNet/bin/Release/*.nupkg
60+
JxlNet/bin/Release/*.snupkg

0 commit comments

Comments
 (0)