|
6 | 6 | - '**' # Runs on all branches |
7 | 7 | pull_request: |
8 | 8 |
|
| 9 | + |
9 | 10 | jobs: |
10 | 11 | build: |
11 | | - runs-on: ${{ matrix.os }} |
12 | | - strategy: |
13 | | - matrix: |
14 | | - # These images are arm64 unless specified: https://github.com/actions/runner-images |
15 | | - os: [macos-15] # macOS CI is expensive: [macos-14, macos-15, macos-15-intel, macos-26] |
| 12 | + # YAML anchor for the runner OS |
| 13 | + # These images are arm64 unless specified: https://github.com/actions/runner-images |
| 14 | + # macOS CI is 10x more expensive than linux: https://docs.github.com/en/billing/concepts/product-billing/github-actions |
| 15 | + runs-on: &runner-os [macos-15] # [macos-14, macos-15, macos-15-intel, macos-26] |
16 | 16 |
|
17 | 17 | steps: |
18 | 18 | - name: Checkout repository |
19 | 19 | uses: actions/checkout@v5 |
20 | 20 |
|
21 | | - - name: Install Adobe DNG Converter |
| 21 | + - name: Cache Adobe DNG Converter.app |
| 22 | + id: cache-dng-app |
| 23 | + uses: actions/cache@v3 |
| 24 | + with: |
| 25 | + path: /Applications/Adobe\ DNG\ Converter.app |
| 26 | + key: dng-app-17-5 |
| 27 | + restore-keys: | |
| 28 | + dng-app- |
| 29 | +
|
| 30 | + - name: Download and Install Adobe DNG Converter |
| 31 | + if: steps.cache-dng-app.outputs.cache-hit != 'true' |
22 | 32 | run: | |
23 | 33 | printf -- "-Downloading the DNG Converter .dmg file\n" |
24 | 34 | curl -L -o DNGConverter_17_5.dmg https://download.adobe.com/pub/adobe/dng/mac/DNGConverter_17_5.dmg |
|
39 | 49 | printf -- "\n\n-Unmounting the DMG file\n" |
40 | 50 | hdiutil detach /Volumes/DNGConverter_17_5 |
41 | 51 |
|
| 52 | + - name: Verify installation |
| 53 | + run: | |
| 54 | + du -sh /Applications/Adobe* |
| 55 | + /Applications/Adobe\ DNG\ Converter.app/Contents/MacOS/Adobe\ DNG\ Converter -d |
| 56 | +
|
| 57 | + - name: Upload installed environment |
| 58 | + uses: actions/upload-artifact@v4 |
| 59 | + with: |
| 60 | + name: dng-env |
| 61 | + path: /Applications/Adobe\ DNG\ Converter.app |
| 62 | + retention-days: 30 |
| 63 | + |
| 64 | + test: |
| 65 | + needs: build |
| 66 | + runs-on: *runner-os |
| 67 | + |
| 68 | + steps: |
| 69 | + - name: Checkout repository |
| 70 | + uses: actions/checkout@v5 |
| 71 | + |
| 72 | + - name: Download installed environment |
| 73 | + uses: actions/download-artifact@v4 |
| 74 | + with: |
| 75 | + name: dng-env |
| 76 | + path: /tmp/dng-app |
| 77 | + |
| 78 | + - name: Move environment to /Applications |
| 79 | + run: | |
| 80 | + sudo mkdir -p "/Applications/Adobe DNG Converter.app" |
| 81 | + sudo cp -R /tmp/dng-app/* "/Applications/Adobe DNG Converter.app/" |
| 82 | + sudo chmod +x "/Applications/Adobe DNG Converter.app/Contents/MacOS/Adobe DNG Converter" |
| 83 | +
|
| 84 | + - name: Verify installation |
| 85 | + run: | |
| 86 | + "/Applications/Adobe DNG Converter.app/Contents/MacOS/Adobe DNG Converter" -d |
| 87 | +
|
42 | 88 | - name: Test organizeGoProDNG.sh |
43 | 89 | run: | |
44 | 90 | chmod +x tests/test_organizeGoProDNG.sh |
|
0 commit comments