Skip to content

Commit 69a7dad

Browse files
committed
Further debugging changes to json mapping
1 parent d3b3a49 commit 69a7dad

File tree

1 file changed

+20
-8
lines changed

1 file changed

+20
-8
lines changed

.github/workflows/msbuild.yml

Lines changed: 20 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,17 @@ on:
3434
env:
3535
# Path to the solution file relative to the root of the project.
3636
SOLUTION_FILE_PATH: RTEA.sln
37-
NAME_MAPPING: "{\"Final\": \"Cortex Command.exe\", \"Debug Release\": \"Cortex Command.debug.release.exe\", \"Debug Minimal\": \"Cortex Command.debug.minimal.exe\", \"Debug Full\": \"Cortex Command.debug.full.exe\"}"
38-
37+
# NAME_MAPPING: |
38+
# "{"Final\": \"Cortex Command.exe\",
39+
# \"Debug Release\": \"Cortex Command.debug.release.exe\",
40+
# \"Debug Minimal\": \"Cortex Command.debug.minimal.exe\",
41+
# \"Debug Full\": \"Cortex Command.debug.full.exe\"}"
42+
43+
NAME_MAPPING: |
44+
{"Final": "Cortex Command.exe",
45+
"Debug Release": "Cortex Command.debug.release.exe",
46+
"Debug Minimal": "Cortex Command.debug.minimal.exe",
47+
"Debug Full": "Cortex Command.debug.full.exe"}
3948
4049
jobs:
4150
build:
@@ -45,6 +54,15 @@ jobs:
4554
steps:
4655
- uses: actions/checkout@v3
4756

57+
- name: Determine executable name
58+
id: executable_name
59+
if: ${{inputs.upload_artefacts}}
60+
run: |
61+
echo 'EXECUTABLE_NAME=${{ fromJson(env.NAME_MAPPING)[inputs.build_configuration] }}' >> "$GITHUB_OUTPUT"
62+
63+
- run: |
64+
echo ${{ steps.executable_name.outputs.EXECUTABLE_NAME }}
65+
4866
- name: Add MSBuild to PATH
4967
uses: microsoft/setup-msbuild@v1
5068

@@ -54,12 +72,6 @@ jobs:
5472
# See https://docs.microsoft.com/visualstudio/msbuild/msbuild-command-line-reference
5573
run: msbuild /m /p:Configuration="${{inputs.build_configuration}}" ${{env.SOLUTION_FILE_PATH}}
5674

57-
- name: Determine executable name
58-
id: executable_name
59-
if: ${{inputs.upload_artefacts}}
60-
run: |
61-
echo 'EXECUTABLE_NAME=${{ fromJson(env.NAME_MAPPING)[inputs.build_configuration] }}' >> "$GITHUB_OUTPUT"
62-
6375
- name: Upload Artifact
6476
if: ${{inputs.upload_artefacts}}
6577
uses: actions/upload-artifact@v3

0 commit comments

Comments
 (0)