Skip to content
This repository was archived by the owner on Sep 8, 2025. It is now read-only.

Commit e620c17

Browse files
authored
Add github workflows (#4)
Fixes #2 Signed-off-by: Dave Thaler <dthaler1968@gmail.com>
1 parent d15f706 commit e620c17

File tree

3 files changed

+101
-0
lines changed

3 files changed

+101
-0
lines changed

.github/dependabot.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# For documentation on the format of this file, see
2+
# https://docs.github.com/en/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file
3+
---
4+
version: 2
5+
updates:
6+
7+
- package-ecosystem: "github-actions"
8+
# Workflow files stored in the
9+
# default location of `.github/workflows`
10+
directory: "/"
11+
schedule:
12+
interval: "weekly"
13+
day: "saturday"
14+
groups:
15+
actions:
16+
patterns:
17+
- "*"

.github/workflows/build.yml

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
# For documentation on the github environment, see
2+
# https://docs.github.com/en/actions/using-github-hosted-runners/about-github-hosted-runners
3+
#
4+
# For documentation on the syntax of this file, see
5+
# https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions
6+
---
7+
name: CPP CI
8+
9+
on:
10+
pull_request:
11+
12+
concurrency:
13+
# Cancel any CI/CD workflow currently in progress for the same PR.
14+
# Allow running concurrently with any other commits.
15+
group: build-${{ github.event.pull_request.number || github.sha }}
16+
cancel-in-progress: true
17+
18+
permissions:
19+
contents: read
20+
21+
jobs:
22+
build_windows:
23+
permissions:
24+
actions: write # for fkirc/skip-duplicate-actions to skip or stop workflow runs
25+
contents: read # for actions/checkout to fetch code
26+
strategy:
27+
matrix:
28+
configurations: [Debug, Release]
29+
runs-on: windows-latest
30+
env:
31+
# Configuration type to build. For documentation on how build matrices work, see
32+
# https://docs.github.com/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix
33+
BUILD_CONFIGURATION: ${{matrix.configurations}}
34+
35+
steps:
36+
- name: Harden Runner
37+
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
38+
with:
39+
egress-policy: audit
40+
41+
- id: skip_check
42+
uses: fkirc/skip-duplicate-actions@f75f66ce1886f00957d99748a42c724f4330bdcf # v5.3.1
43+
with:
44+
cancel_others: 'false'
45+
paths_ignore: '["**.md"]'
46+
47+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
48+
if: steps.skip_check.outputs.should_skip != 'true'
49+
with:
50+
submodules: 'recursive'
51+
52+
- name: Build
53+
if: steps.skip_check.outputs.should_skip != 'true'
54+
run: |
55+
dotnet build OrcaHelloProxy.sln /p:Configuration=${{env.BUILD_CONFIGURATION}} /p:Platform="Any CPU"
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
# For documentation on the github environment, see
2+
# https://docs.github.com/en/actions/using-github-hosted-runners/about-github-hosted-runners
3+
#
4+
# For documentation on the syntax of this file, see
5+
# https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions
6+
---
7+
name: Validate-YAML
8+
9+
on:
10+
pull_request:
11+
12+
permissions:
13+
contents: read
14+
15+
jobs:
16+
validate-yaml:
17+
runs-on: ubuntu-latest
18+
19+
steps:
20+
- name: Harden the runner (Audit all outbound calls)
21+
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
22+
with:
23+
egress-policy: audit
24+
25+
- name: Checkout repository
26+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
27+
28+
- name: Validate YAML
29+
run: yamllint .

0 commit comments

Comments
 (0)