OSDN Git Service

[Chore] MSVCでのビルドテストを行うワークフロー
authorHabu <habu1010+github@gmail.com>
Mon, 26 Jun 2023 03:50:31 +0000 (12:50 +0900)
committerHabu <habu1010+github@gmail.com>
Mon, 26 Jun 2023 10:32:13 +0000 (19:32 +0900)
プルリクエストに対して、MSVCでのビルドテストを行うワークフローを追加する。

.github/workflows/build-test-with-msvc.yml [new file with mode: 0644]
.github/workflows/pull-request-status-check.yml

diff --git a/.github/workflows/build-test-with-msvc.yml b/.github/workflows/build-test-with-msvc.yml
new file mode 100644 (file)
index 0000000..9093f32
--- /dev/null
@@ -0,0 +1,30 @@
+name: Build test with MSVC
+on:
+  workflow_call:
+
+  # 手動トリガーを許可
+  workflow_dispatch:
+
+jobs:
+  build:
+    runs-on: windows-2022
+
+    steps:
+      - name: Checkout Repository
+        uses: actions/checkout@v3
+        with:
+          lfs: true
+
+      - name: Setup MSBuild
+        uses: microsoft/setup-msbuild@v1
+
+      - name: Setup NuGet
+        uses: NuGet/setup-nuget@v1
+
+      - name: Restore Nuget Packages
+        run: |
+          NuGet restore .\Hengband\Hengband.sln
+
+      - name: Run build test
+        run: |
+          MSBuild -warnAsError .\Hengband\Hengband.sln /t:Rebuild /p:Configuration=Debug
index 2286a88..fdc9c64 100644 (file)
@@ -51,3 +51,8 @@ jobs:
       configure-opts: "--disable-japanese"
       distcheck: true
       use-ccache: true
+
+  build_test_with_msvc:
+    name: Build test with MSVC
+    needs: [check_bom, check_format]
+    uses: ./.github/workflows/build-test-with-msvc.yml