Skip to content

Commit

Permalink
Upgrade to dotnet SDK 8.0.303 (#58)
Browse files Browse the repository at this point in the history
* Upgrade to dotnet SDK 8.0.303

* Increment patch version

* Set megalinter CSHARP_DOTNET_FORMAT_CLI_LINT_MODE to project

* Megalinter fixes (mega-linter-runner --fix)

* Disable megalinter for CSHARP as we use StyleCop.Analyzers to enforce C# formatting

* Specify schema in github issue config to make v8r happy

* Add v8r config file

* Fix yamllint warnings

* Add SPDX header

* Fix glob

* Ignore .jsonlintrc.yml in v8r

* Reduce v8r verbosity

* v8r ignore advanced-issue-labeler.yml

* One more try

* Fix .mega-linter.yml

* More schemas

* Fix example
  • Loading branch information
m-ringler authored Jul 19, 2024
1 parent 7e918e0 commit 35c5c16
Show file tree
Hide file tree
Showing 39 changed files with 505 additions and 472 deletions.
130 changes: 65 additions & 65 deletions .github/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,75 +2,75 @@
name: "🕷️ Bug report"
description: Create a report to help us improve
labels:
- bug
- bug
body:
- type: dropdown
id: toolaffected
attributes:
label: Which tool is affected?
description: CZI Shrink is the GUI application while CZI Compress refers to the CLI tool.
multiple: false
options:
- CZI Compress
- CZI Shrink
validations:
required: true
- type: dropdown
id: toolaffected
attributes:
label: Which tool is affected?
description: CZI Shrink is the GUI application while CZI Compress refers to the CLI tool.
multiple: false
options:
- CZI Compress
- CZI Shrink
validations:
required: true

- type: textarea
attributes:
label: Description
description: Describe the bug and add screenshots if possible/applicable.
placeholder: A clear and concise description of what the bug is.
validations:
required: true
- type: textarea
attributes:
label: Description
description: Describe the bug and add screenshots if possible/applicable.
placeholder: A clear and concise description of what the bug is.
validations:
required: true

- type: textarea
attributes:
label: Steps to reproduce
description: Please include screenshots (if applicable) and relevant logs.
placeholder: |
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error
validations:
required: true
- type: textarea
attributes:
label: Steps to reproduce
description: Please include screenshots (if applicable) and relevant logs.
placeholder: |
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error
validations:
required: true

- type: textarea
attributes:
label: Expected behavior
description: A clear and concise description of what you expected to happen.
placeholder: |
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error
validations:
required: true
- type: textarea
attributes:
label: Expected behavior
description: A clear and concise description of what you expected to happen.
placeholder: |
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error
validations:
required: true

- type: dropdown
attributes:
label: OS
description: What operating system are you using?
multiple: false
options:
- Windows
- MacOS
- Linux
validations:
required: true
- type: dropdown
attributes:
label: OS
description: What operating system are you using?
multiple: false
options:
- Windows
- MacOS
- Linux
validations:
required: true

- type: input
attributes:
label: OS Version
description: What version and flavor (if applicable) of your OS are you using?
placeholder: Ubuntu 23.10 | Sonoma 14.1.2 | Windows 11 23H2
validations:
required: true
- type: input
attributes:
label: OS Version
description: What version and flavor (if applicable) of your OS are you using?
placeholder: Ubuntu 23.10 | Sonoma 14.1.2 | Windows 11 23H2
validations:
required: true

- type: textarea
attributes:
label: Other Context
description: Please add any other context that may be relevant.
validations:
required: false
- type: textarea
attributes:
label: Other Context
description: Please add any other context that may be relevant.
validations:
required: false
4 changes: 2 additions & 2 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# STOP - Read this First!
# STOP - Read this First
Reporting a security vulnerability?
Check out the project's [security policy](https://github.com/zeiss/czicompress/security/policy).

Expand All @@ -24,7 +24,7 @@ Fixes # (issue)
Describe the tests that you ran to verify your changes.
Provide instructions to reproduce.

## Checklist:
## Checklist

- [ ] I followed the Contributing Guidelines.
- [ ] I did a self-review.
Expand Down
24 changes: 12 additions & 12 deletions .github/actions/cmake-build/action.yml
Original file line number Diff line number Diff line change
@@ -1,27 +1,27 @@
---
name: 'CMake-Build'
description: 'Install Dependencies + Configure CMake + Build'
name: "CMake-Build"
description: "Install Dependencies + Configure CMake + Build"
inputs:
path-cache:
description: 'Path to vcpkg cache directory'
description: "Path to vcpkg cache directory"
required: true
path-toolchain:
description: 'Path to vcpkg tool chain file'
description: "Path to vcpkg tool chain file"
required: true
os-id:
description: 'Operating System Identifier'
description: "Operating System Identifier"
required: true
build-type:
description: 'Build Configuration'
description: "Build Configuration"
required: true
package:
description: 'Using package manager for external dependencies'
description: "Using package manager for external dependencies"
required: true
platform:
description: 'OS platform'
description: "OS platform"
required: true
src-dir:
description: 'The directory with the sources'
description: "The directory with the sources"
required: true
runs:
using: "composite"
Expand All @@ -44,9 +44,9 @@ runs:
shell: bash
working-directory: ${{inputs.src-dir}}
run: |
# We install the following packages: eigen3, catch2, cli11. Installing them with vcpkg (and caching them)
# is faster than downloading and building them from source (which is the default behavior of the CZICompress-build-system).
vcpkg install --triplet ${{inputs.platform}} eigen3 catch2 cli11
# We install the following packages: eigen3, catch2, cli11. Installing them with vcpkg (and caching them)
# is faster than downloading and building them from source (which is the default behavior of the CZICompress-build-system).
vcpkg install --triplet ${{inputs.platform}} eigen3 catch2 cli11
- name: Configure CMake
shell: bash
Expand Down
8 changes: 4 additions & 4 deletions .github/advanced-issue-labeler.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
policy:
- section:
- id: [toolaffected]
block-list: ['None', 'Other']
block-list: ["None", "Other"]
label:
- name: czicompress
keys: ['CZI Compress']
- name: 'czishrink'
keys: ['CZI Shrink']
keys: ["CZI Compress"]
- name: "czishrink"
keys: ["CZI Shrink"]
44 changes: 26 additions & 18 deletions .github/workflows/czicompress_cmake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,24 +35,32 @@ jobs:
platform: x64-windows-static,
package: ON,
path-cache: '${{ github.workspace }}\vcpkg\installed',
path-toolchain: 'C:/vcpkg/scripts/buildsystems/vcpkg.cmake',
os-id: 'windows',
path-toolchain: "C:/vcpkg/scripts/buildsystems/vcpkg.cmake",
os-id: "windows",
}
- {
name: ubuntu-package-off,
os: ubuntu-20.04, # we want to use an older version in order to increase likelihood that binaries work on other distros
os: ubuntu-20.04, # we want to use an older version in order to increase likelihood that binaries work on other distros
platform: x64-linux,
package: OFF,
path-cache: '/usr/local/share/vcpkg/installed',
path-toolchain: '/usr/local/share/vcpkg/scripts/buildsystems/vcpkg.cmake',
os-id: 'linux',
path-cache: "/usr/local/share/vcpkg/installed",
path-toolchain: "/usr/local/share/vcpkg/scripts/buildsystems/vcpkg.cmake",
os-id: "linux",
}
exclude:
# From https://github.com/actions/runner/issues/1512
- build: Debug
config: {name: ubuntu-package-off, os: ubuntu-20.04, platform: x64-linux, package: OFF, path-cache: '/usr/local/share/vcpkg/installed', path-toolchain: '/usr/local/share/vcpkg/scripts/buildsystems/vcpkg.cmake', os-id: 'linux'}
config:
{
name: ubuntu-package-off,
os: ubuntu-20.04,
platform: x64-linux,
package: OFF,
path-cache: "/usr/local/share/vcpkg/installed",
path-toolchain: "/usr/local/share/vcpkg/scripts/buildsystems/vcpkg.cmake",
os-id: "linux",
}
steps:

- name: Checkout the source codes.
uses: actions/checkout@v4

Expand All @@ -64,7 +72,7 @@ jobs:
build-type: ${{matrix.build}}
package: ${{matrix.config.package}}
platform: ${{matrix.config.platform}}
src-dir: '${{github.workspace}}/czicompress'
src-dir: "${{github.workspace}}/czicompress"

- name: Run unit tests
working-directory: ${{github.workspace}}/czicompress/build
Expand All @@ -77,8 +85,8 @@ jobs:
if: ${{ (matrix.config.os == 'windows-latest') && (matrix.build == 'Debug') }}
shell: pwsh
run: |
choco install OpenCppCoverage -y
echo "C:\Program Files\OpenCppCoverage" >> $env:GITHUB_PATH
choco install OpenCppCoverage -y
echo "C:\Program Files\OpenCppCoverage" >> $env:GITHUB_PATH
- name: Get Coverage
if: ${{ (matrix.config.os == 'windows-latest') && (matrix.build == 'Debug') }}
Expand All @@ -94,29 +102,29 @@ jobs:
fail_ci_if_error: true
directory: ${{ github.workspace }}/TestResults
verbose: true
token: ${{ secrets.CODECOV_TOKEN }} # required
token: ${{ secrets.CODECOV_TOKEN }} # required

- name: Prepare licenses
if: matrix.build == 'Release'
shell: bash
run: |
set -e
mkdir ./czicompress-${{env.name}}
cp -R ./THIRD_PARTY_LICENSES_ARTIFACT_DISTRIBUTION.txt ./czicompress-${{env.name}}/
cp -R ./build/app/THIRD_PARTY_LICENSES.txt ./czicompress-${{env.name}}/
set -e
mkdir ./czicompress-${{env.name}}
cp -R ./THIRD_PARTY_LICENSES_ARTIFACT_DISTRIBUTION.txt ./czicompress-${{env.name}}/
cp -R ./build/app/THIRD_PARTY_LICENSES.txt ./czicompress-${{env.name}}/
# gather the binaries
- name: Prepare Linux binaries
if: ${{ (matrix.config.os == 'ubuntu-20.04') && (matrix.build == 'Release') }}
shell: bash
run: |
cp ./build/app/czicompress ./build/capi/libczicompressc.so ./czicompress-${{env.name}}/
cp ./build/app/czicompress ./build/capi/libczicompressc.so ./czicompress-${{env.name}}/
- name: Prepare Windows binaries
if: ${{ (matrix.config.os == 'windows-latest') && (matrix.build == 'Release') }}
shell: bash
run: |
cp ./build/app/${{matrix.build}}/*.exe ./build/capi/${{matrix.build}}/libczicompressc.dll ./czicompress-${{env.name}}/
cp ./build/app/${{matrix.build}}/*.exe ./build/capi/${{matrix.build}}/libczicompressc.dll ./czicompress-${{env.name}}/
# upload the build-results to artifacts-store
- name: Upload artifacts
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/czicompress_codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,13 +47,13 @@ jobs:

- uses: ./.github/actions/cmake-build
with:
path-cache: '/usr/local/share/vcpkg/installed'
path-toolchain: '/usr/local/share/vcpkg/scripts/buildsystems/vcpkg.cmake'
os-id: 'linux'
path-cache: "/usr/local/share/vcpkg/installed"
path-toolchain: "/usr/local/share/vcpkg/scripts/buildsystems/vcpkg.cmake"
os-id: "linux"
build-type: Release
package: ON
platform: x64-linux
src-dir: '${{github.workspace}}/czicompress'
src-dir: "${{github.workspace}}/czicompress"

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/czishrink_codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ on:
# │ │ │ │ │
# │ │ │ │ │
# * * * * *
- cron: '30 2 * * 2'
- cron: "30 2 * * 2"
workflow_dispatch: {}

permissions: read-all
Expand Down Expand Up @@ -48,7 +48,7 @@ jobs:
path: ${{ github.workspace }}/.nuget/packages
key: ${{ runner.os }}-czishrink-nuget-${{ hashFiles('czishrink/**/packages.lock.json') }}
restore-keys: |
${{ runner.os }}-czishrink-nuget-
${{ runner.os }}-czishrink-nuget-
- name: Initialize CodeQL
uses: github/codeql-action/init@v3
Expand Down
12 changes: 3 additions & 9 deletions .github/workflows/czishrink_dotnet.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,14 +29,8 @@ jobs:
matrix:
build: [Release, Debug]
config:
- {
os: windows-latest,
osfamily: win,
}
- {
os: ubuntu-latest,
osfamily: linux,
}
- {os: windows-latest, osfamily: win}
- {os: ubuntu-latest, osfamily: linux}
exclude:
# From https://github.com/actions/runner/issues/1512
- build: Debug
Expand Down Expand Up @@ -107,7 +101,7 @@ jobs:
directory: ${{ github.workspace }}/TestResults
files: coverage.cobertura.xml
verbose: true
token: ${{ secrets.CODECOV_TOKEN }} # required
token: ${{ secrets.CODECOV_TOKEN }} # required

- name: Upload dotnet test results
uses: actions/upload-artifact@v4
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/dependency-review.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
name: 'Dependency Review'
name: "Dependency Review"
on: [pull_request]

permissions:
Expand All @@ -9,9 +9,9 @@ jobs:
dependency-review:
runs-on: ubuntu-latest
steps:
- name: 'Checkout Repository'
- name: "Checkout Repository"
uses: actions/checkout@v4
- name: 'Dependency Review'
- name: "Dependency Review"
uses: actions/dependency-review-action@v4
with:
# Add more licenses as required. Do not add copy-left licenses or licenses incompatible with MIT (for czicompress) and GPL-3.0-or-later (for czishrink)
Expand Down
Loading

0 comments on commit 35c5c16

Please sign in to comment.