Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# SPDX-License-Identifier: MIT
# SPDX-FileCopyrightText: "2025 smdn <[email protected]>"
#
# ref: https://docs.github.com/code-security/dependabot/working-with-dependabot/dependabot-options-reference
#
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
day: "wednesday"
time: "03:24"
timezone: "Asia/Tokyo"
28 changes: 10 additions & 18 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,15 +40,17 @@ jobs:
strategy:
fail-fast: false
matrix:
language: [ 'csharp' ]
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby' ]
# Learn more about CodeQL language support at https://git.io/codeql-language-support
include:
- language: csharp
build-mode: manual
source-root: './src'

steps:
- name: Checkout repository
uses: actions/[email protected].1
uses: actions/[email protected].2

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v3
with:
Expand All @@ -59,22 +61,12 @@ jobs:
# queries: ./path/to/local/query, your-org/your-repo/queries@main
config-file: ./.github/codeql/configurations.yml

# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
# - name: Autobuild
# uses: github/codeql-action/autobuild@v2
- name: Autobuild
if: ${{ (matrix.build-mode == 'autobuild') || (matrix.build-mode == '') }}
uses: github/codeql-action/autobuild@v3

# ℹ️ Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl

# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
# and modify them (or add more) to build your code if your project
# uses a compiled language

#- run: |
# make bootstrap
# make release
- name: Custom build steps
- name: Build all .NET projects
if: ${{ (matrix.build-mode == 'manual') && (matrix.language == 'csharp') }}
run: |
./eng/BuildAllProjects.ps1

Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/generate-release-target.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ jobs:
exit 1

run-generate-release-target:
uses: smdn/Smdn.Fundamentals/.github/workflows/generate-release-target.yml@workflows/release-target-v1.9.0
uses: smdn/Smdn.Fundamentals/.github/workflows/generate-release-target.yml@workflows/release-target/v1.10.2
needs: determine-release-target
if: startsWith(needs.determine-release-target.outputs.tag_name, 'new-release/')
with:
Expand All @@ -71,7 +71,7 @@ jobs:
release_tag_prefix: 'releases/'
workflow_runs_on: 'ubuntu-24.04'
dotnet_sdk_version: '8.0.100'
dry_run: ${{ fromJSON(needs.determine-release-target.outputs.dry_run) }}
dry_run: ${{ needs.determine-release-target.outputs.dry_run == 'true' }}
secrets:
token_repo: ${{ secrets.PUBLISH_NEW_RELEASE }}
token_pullrequest: ${{ secrets.PUBLISH_NEW_RELEASE }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/publish-release-target.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ on:

jobs:
run-publish-release-target:
uses: smdn/Smdn.Fundamentals/.github/workflows/publish-release-target.yml@workflows/release-target-v1.9.0
uses: smdn/Smdn.Fundamentals/.github/workflows/publish-release-target.yml@workflows/release-target/v1.10.2
if: |
(github.event.pull_request.merged == true && startsWith(github.head_ref, 'releases/')) &&
(contains(github.event.pull_request.labels.*.name, 'release-target'))
Expand Down
66 changes: 20 additions & 46 deletions .github/workflows/test-packages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,12 @@ on:
type: string

os:
description: "The OS label which run the test on. (ex: ubuntu-22.04, ubuntu-20.04, windows-latest, macos-latest)"
description: "The OS label which run the test on. (ubuntu-24.04, ubuntu-22.04, windows-latest, macos-latest, etc.)"
required: false
type: string

dotnet_sdk_version:
description: "The minimum .NET SDK version which is used to run tests."
required: false
type: string

Expand All @@ -41,52 +46,21 @@ on:
type: string

jobs:
prerequisites:
runs-on: ubuntu-latest
outputs:
os: ${{ steps.input-prerequisites.outputs.os }}
verbose: ${{ steps.input-prerequisites.outputs.verbose }}
env:
RUNS_ON_OS_LIST_DEFAULT: 'ubuntu-24.04, ubuntu-22.04, ubuntu-20.04, windows-latest, macos-latest'
steps:
- name: Delay until the package is published
run: |
# If the workflow is triggered by 'release' event,
# wait for a while until the package is published on NuGet
if [ '${{ github.event_name }}' = 'release' ]; then
sleep 5.0m
fi

- name: Determine prerequisites
id: input-prerequisites
run: |
if [ -z '${{ github.event.inputs.os }}' ]; then
echo "os=${RUNS_ON_OS_LIST_DEFAULT}" >> $GITHUB_OUTPUT
else
echo 'os=${{ github.event.inputs.os }}' >> $GITHUB_OUTPUT
fi

if [ '${{ github.event.inputs.verbose }}' = 'true' ]; then
echo 'verbose=true' >> $GITHUB_OUTPUT
else
echo 'verbose=false' >> $GITHUB_OUTPUT
fi

run-test:
uses: smdn/Smdn.Fundamentals/.github/workflows/test.yml@workflows/test-v1.3.2
needs: prerequisites
name: Run tests with released packages
uses: smdn/Smdn.Fundamentals/.github/workflows/test.yml@workflows/test/v1.4.1
with:
project: ${{ github.event.inputs.project }}
os: ${{ needs.prerequisites.outputs.os }}
extra_options_common: '/p:TestReleasedPackage=true'
verbose: ${{ fromJSON(needs.prerequisites.outputs.verbose) }}
path_proj_install_project_assets: "eng/InstallProjectAssets.proj"
dotnet_sdk_version: '8.0.100'
timeout_minutes_test_job: 10
timeout_hang: "[ {'OS':'windows','Timeout':'6min'}, {'OS':'macos','Timeout':'3min'}, {'OS':'','Timeout':'1min'} ]"
timeout_vstest_connection: "[ {'OS':'windows','Timeout':360}, {'OS':'macos','Timeout':180}, {'OS':'','Timeout':60} ]"
dotnet_test_options_verbosity_level: ${{ github.event.inputs.dotnet_test_options_verbosity_level }}
dotnet_test_options_framework: ${{ github.event.inputs.dotnet_test_options_framework }}
dotnet_test_options_filter_expression: ${{ github.event.inputs.dotnet_test_options_filter_expression }}
project: ${{ inputs.project }}
os: ${{ inputs.os == '' && 'ubuntu-24.04, ubuntu-22.04, ubuntu-20.04, windows-latest, macos-latest' || inputs.os }}
extra_options_common: '/p:TestReleasedPackage=true'
verbose: ${{ inputs.verbose == 'true' }}
path_proj_install_project_assets: "eng/InstallProjectAssets.proj"
dotnet_sdk_version: ${{ inputs.dotnet_sdk_version == '' && '8.0.100' || inputs.dotnet_sdk_version }}
timeout_minutes_test_job: 10
timeout_hang: "[ {'OS':'windows','Timeout':'6min'}, {'OS':'macos','Timeout':'3min'}, {'OS':'','Timeout':'1min'} ]"
timeout_vstest_connection: "[ {'OS':'windows','Timeout':360}, {'OS':'macos','Timeout':180}, {'OS':'','Timeout':60} ]"
dotnet_test_options_verbosity_level: ${{ inputs.dotnet_test_options_verbosity_level }}
dotnet_test_options_framework: ${{ inputs.dotnet_test_options_framework }}
dotnet_test_options_filter_expression: ${{ inputs.dotnet_test_options_filter_expression }}
secrets:
token_repo: ${{ secrets.GITHUB_TOKEN }}
58 changes: 20 additions & 38 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,12 @@ on:
type: string

os:
description: "The OS label which run the test on. (ex: ubuntu-22.04, ubuntu-20.04, windows-latest, macos-latest)"
description: "The OS label which run the test on. (ubuntu-24.04, ubuntu-22.04, windows-latest, macos-latest, etc.)"
required: false
type: string

dotnet_sdk_version:
description: "The minimum .NET SDK version which is used to run tests."
required: false
type: string

Expand Down Expand Up @@ -59,44 +64,21 @@ on:
type: string

jobs:
prerequisites:
runs-on: ubuntu-latest
outputs:
os: ${{ steps.input-prerequisites.outputs.os }}
verbose: ${{ steps.input-prerequisites.outputs.verbose }}
env:
RUNS_ON_OS_LIST_DEFAULT: 'ubuntu-24.04, ubuntu-22.04, ubuntu-20.04, windows-latest, macos-latest'
steps:
- name: Determine prerequisites
id: input-prerequisites
run: |
if [ -z '${{ github.event.inputs.os }}' ]; then
echo "os=${RUNS_ON_OS_LIST_DEFAULT}" >> $GITHUB_OUTPUT
else
echo 'os=${{ github.event.inputs.os }}' >> $GITHUB_OUTPUT
fi

if [ '${{ github.event.inputs.verbose }}' = 'true' ]; then
echo 'verbose=true' >> $GITHUB_OUTPUT
else
echo 'verbose=false' >> $GITHUB_OUTPUT
fi

run-test:
uses: smdn/Smdn.Fundamentals/.github/workflows/test.yml@workflows/test-v1.3.2
needs: prerequisites
name: Run tests
uses: smdn/Smdn.Fundamentals/.github/workflows/test.yml@workflows/test/v1.4.1
with:
project: ${{ github.event.inputs.project }}
os: ${{ needs.prerequisites.outputs.os }}
verbose: ${{ fromJSON(needs.prerequisites.outputs.verbose) }}
path_proj_install_project_assets: "eng/InstallProjectAssets.proj"
dotnet_sdk_version: '8.0.100'
timeout_minutes_test_job: 10
timeout_hang: "[ {'OS':'windows','Timeout':'6min'}, {'OS':'macos','Timeout':'3min'}, {'OS':'','Timeout':'1min'} ]"
timeout_vstest_connection: "[ {'OS':'windows','Timeout':360}, {'OS':'macos','Timeout':180}, {'OS':'','Timeout':60} ]"
extra_options_common: ${{ github.event.inputs.extra_options_common }}
dotnet_test_options_verbosity_level: ${{ github.event.inputs.dotnet_test_options_verbosity_level }}
dotnet_test_options_framework: ${{ github.event.inputs.dotnet_test_options_framework }}
dotnet_test_options_filter_expression: ${{ github.event.inputs.dotnet_test_options_filter_expression }}
project: ${{ inputs.project }}
os: ${{ inputs.os == '' && 'ubuntu-24.04, ubuntu-22.04, ubuntu-20.04, windows-latest, macos-latest' || inputs.os }}
verbose: ${{ inputs.verbose == 'true' }}
path_proj_install_project_assets: "eng/InstallProjectAssets.proj"
dotnet_sdk_version: ${{ inputs.dotnet_sdk_version == '' && '8.0.100' || inputs.dotnet_sdk_version }}
timeout_minutes_test_job: 10
timeout_hang: "[ {'OS':'windows','Timeout':'6min'}, {'OS':'macos','Timeout':'3min'}, {'OS':'','Timeout':'1min'} ]"
timeout_vstest_connection: "[ {'OS':'windows','Timeout':360}, {'OS':'macos','Timeout':180}, {'OS':'','Timeout':60} ]"
extra_options_common: ${{ inputs.extra_options_common }}
dotnet_test_options_verbosity_level: ${{ inputs.dotnet_test_options_verbosity_level }}
dotnet_test_options_framework: ${{ inputs.dotnet_test_options_framework }}
dotnet_test_options_filter_expression: ${{ inputs.dotnet_test_options_filter_expression }}
secrets:
token_repo: ${{ secrets.GITHUB_TOKEN }}
52 changes: 52 additions & 0 deletions MuninNode.sln
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.0.31903.59
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Smdn.Net.MuninNode", "src\Smdn.Net.MuninNode\Smdn.Net.MuninNode.csproj", "{DAC6756C-24D7-403F-A3D6-C573B6AA4A2E}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "multiple-fields", "examples\multiple-fields\multiple-fields.csproj", "{8C2FDAA2-B21F-4055-816D-B73BEA2CA991}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "local-node-uptime", "examples\local-node-uptime\local-node-uptime.csproj", "{43641D75-9327-42D7-8C7F-9A91F737A1C5}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{E3D3E473-95E2-4A68-9416-F210DAC57404}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "examples", "examples", "{3A0BF316-8300-4B36-B1A4-5D7813E0E728}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "tests", "tests", "{0A0B3E22-E38B-46AD-B101-110D25E3AAD9}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Smdn.Net.MuninNode.Tests", "tests\Smdn.Net.MuninNode\Smdn.Net.MuninNode.Tests.csproj", "{27C3F87B-5C59-44F9-96F9-25528972DA70}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{DAC6756C-24D7-403F-A3D6-C573B6AA4A2E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{DAC6756C-24D7-403F-A3D6-C573B6AA4A2E}.Debug|Any CPU.Build.0 = Debug|Any CPU
{DAC6756C-24D7-403F-A3D6-C573B6AA4A2E}.Release|Any CPU.ActiveCfg = Release|Any CPU
{DAC6756C-24D7-403F-A3D6-C573B6AA4A2E}.Release|Any CPU.Build.0 = Release|Any CPU
{8C2FDAA2-B21F-4055-816D-B73BEA2CA991}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{8C2FDAA2-B21F-4055-816D-B73BEA2CA991}.Debug|Any CPU.Build.0 = Debug|Any CPU
{8C2FDAA2-B21F-4055-816D-B73BEA2CA991}.Release|Any CPU.ActiveCfg = Release|Any CPU
{8C2FDAA2-B21F-4055-816D-B73BEA2CA991}.Release|Any CPU.Build.0 = Release|Any CPU
{43641D75-9327-42D7-8C7F-9A91F737A1C5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{43641D75-9327-42D7-8C7F-9A91F737A1C5}.Debug|Any CPU.Build.0 = Debug|Any CPU
{43641D75-9327-42D7-8C7F-9A91F737A1C5}.Release|Any CPU.ActiveCfg = Release|Any CPU
{43641D75-9327-42D7-8C7F-9A91F737A1C5}.Release|Any CPU.Build.0 = Release|Any CPU
{27C3F87B-5C59-44F9-96F9-25528972DA70}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{27C3F87B-5C59-44F9-96F9-25528972DA70}.Debug|Any CPU.Build.0 = Debug|Any CPU
{27C3F87B-5C59-44F9-96F9-25528972DA70}.Release|Any CPU.ActiveCfg = Release|Any CPU
{27C3F87B-5C59-44F9-96F9-25528972DA70}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(NestedProjects) = preSolution
{DAC6756C-24D7-403F-A3D6-C573B6AA4A2E} = {E3D3E473-95E2-4A68-9416-F210DAC57404}
{43641D75-9327-42D7-8C7F-9A91F737A1C5} = {3A0BF316-8300-4B36-B1A4-5D7813E0E728}
{8C2FDAA2-B21F-4055-816D-B73BEA2CA991} = {3A0BF316-8300-4B36-B1A4-5D7813E0E728}
{27C3F87B-5C59-44F9-96F9-25528972DA70} = {0A0B3E22-E38B-46AD-B101-110D25E3AAD9}
EndGlobalSection
EndGlobal
Loading