|
22 | 22 | default: true |
23 | 23 |
|
24 | 24 | jobs: |
25 | | - validate: |
26 | | - runs-on: windows-2022 |
27 | | - outputs: |
28 | | - runners: ${{ steps.runners-matrix.outputs.runners }} |
29 | | - steps: |
30 | | - - uses: actions/checkout@v2 |
31 | | - with: |
32 | | - submodules: recursive |
33 | | - - name: Install job dependencies |
34 | | - shell: bash |
35 | | - run: | |
36 | | - choco install -y dos2unix |
37 | | - curl https://www.kikisoft.com/Hive/clang-format/clang-format-7.0.0-LambdaPatch-windows.exe -o clang-format.exe |
38 | | - ln -s $(pwd)/clang-format.exe /usr/bin/clang-format |
39 | | -
|
40 | | - - name: Run fix_files |
41 | | - shell: bash {0} |
42 | | - run: | |
43 | | - ./scripts/bashUtils/fix_files.sh |
44 | | -
|
45 | | - - name: Check for changes |
46 | | - shell: bash |
47 | | - run: | |
48 | | - git diff --name-status --exit-code |
49 | | - if [ $? -ne 0 ]; then |
50 | | - echo "Some files need formatting/fixing. Please run the script and commit the changes." |
51 | | - exit 1 |
52 | | - fi |
53 | | - - name: prepare-runners-matrix |
54 | | - id: runners-matrix |
55 | | - shell: bash |
56 | | - run: | |
57 | | - macos=$(([ ${{vars.RELEASE_MACOS}} = "true" ] || [ ${{inputs.RELEASE_MACOS}} = "true" ]) && jq -n --argjson r '${{vars.RUNNER_LABELS_MACOS}}' '$r' || echo '""') |
58 | | - echo $macos |
59 | | - linux=$(([ ${{vars.RELEASE_LINUX}} = "true" ] || [ ${{inputs.RELEASE_LINUX}} = "true" ]) && jq -n --argjson r '${{vars.RUNNER_LABELS_LINUX}}' '$r' || echo '""') |
60 | | - echo $linux |
61 | | - windows=$(([ ${{vars.RELEASE_WINDOWS}} = "true" ] || [ ${{inputs.RELEASE_WINDOWS}} = "true" ]) && jq -n --argjson r '${{vars.RUNNER_LABELS_WINDOWS}}' '$r' || echo '""') |
62 | | - echo $windows |
63 | | -
|
64 | | - runners=$(jq -n --argjson m "$macos" --argjson l "$linux" --argjson w "$windows" '[$m,$l,$w]' | jq 'del(.[] | select(. == ""))' | tr -d '\n' ) |
65 | | - echo $runners |
66 | | - echo "runners=$runners" >> "$GITHUB_OUTPUT" |
67 | | -
|
68 | | - release: |
69 | | - |
70 | | - needs: validate |
71 | | - env: |
72 | | - LC_ALL: en_US.UTF-8 |
73 | | - |
74 | | - strategy: |
75 | | - fail-fast: false |
76 | | - matrix: |
77 | | - config: |
78 | | - - release |
79 | | - runner-label: ${{ fromJSON(needs.validate.outputs.runners) }} |
80 | | - |
81 | | - runs-on: ${{matrix.runner-label}} |
82 | | - steps: |
83 | | - - uses: actions/checkout@v2 |
84 | | - with: |
85 | | - submodules: recursive |
86 | | - |
87 | | - - uses: L-Acoustics/la-mw-gh-action/.github/actions/la-swig@v0 |
88 | | - name: Install custom SWIG |
89 | | - id: la_swig |
90 | | - |
91 | | - |
92 | | - - name: Configure runner |
93 | | - uses: L-Acoustics/la-mw-gh-action/.github/actions/la-configure-runner@v0 |
94 | | - |
95 | | - - name: Build, Test, Push Library |
96 | | - uses: L-Acoustics/la-mw-gh-action/.github/actions/la-build@e368cc944233da2d9b61c7bc3e6108cacf20b174 |
97 | | - with: |
98 | | - push_bindings: 'true' |
99 | | - GTEST_FILTER: '-MANUAL*' |
100 | | - SWIG_EXEC: ${{steps.la_swig.outputs.swig_exec}} |
101 | | - SWIG_DIR: ${{steps.la_swig.outputs.swig_dir}} |
102 | | - BUILD_DIR: "_build" |
103 | | - include_nuget_la_feed_url: 'false' |
104 | | - CONFIG: ${{matrix.config}} |
105 | | - NUGET_CURRENT_FEED_URL: 'https://nuget.pkg.github.com/L-Acoustics/index.json' |
106 | | - LIB_NAME: "la_networkInterfaceHelper" |
107 | | - GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}} |
| 25 | + release-stage: |
| 26 | + uses: L-Acoustics/la-mw-gh-action/.github/workflows/release_stage.yml@main |
| 27 | + with: |
| 28 | + release_linux: ${{inputs.release_linux}} |
| 29 | + release_windows: ${{inputs.release_windows}} |
| 30 | + release_macos: ${{inputs.release_macos}} |
| 31 | + secrets: |
| 32 | + GH_TOKEN: ${{secrets.GITHUB_TOKEN}} |
| 33 | + KEYCHAIN_PASSWORD: ${{secrets.KEYCHAIN_PASSWORD}} |
| 34 | + APPLE_CERTIFICATES_P12_BASE64_PASSWORD: ${{secrets.APPLE_CERTIFICATES_P12_BASE64_PASSWORD}} |
| 35 | + APPLE_CERTIFICATES_P12_BASE64: ${{secrets.APPLE_CERTIFICATES_P12_BASE64}} |
0 commit comments