|
17 | 17 | - '**test.yml'
|
18 | 18 |
|
19 | 19 | env:
|
20 |
| - VERSION: action-test |
| 20 | + VERSION: container-test |
21 | 21 |
|
22 | 22 | jobs:
|
23 | 23 | test-rmw:
|
24 | 24 | runs-on: ubuntu-latest
|
25 | 25 | strategy:
|
26 | 26 | matrix:
|
27 |
| - platform: ['amd64', 'arm64', 'arm/v7'] |
| 27 | + platform: |
| 28 | + - linux/amd64 |
| 29 | + - linux/arm64 |
| 30 | + - linux/arm/v7 |
| 31 | + |
28 | 32 | steps:
|
29 |
| - - name: Checkout |
| 33 | + - name: Checkout rmw |
30 | 34 | uses: actions/checkout@v4
|
31 |
| - - name: Use action from self |
32 |
| - uses: ./ |
33 | 35 | with:
|
34 |
| - platform: ${{ matrix.platform }} |
35 |
| - dependency_commands: | |
36 |
| - export -p |
37 |
| - sudo apt install -y libncursesw5-dev |
38 |
| - build_commands: | |
39 |
| - git clone --depth 1 https://github.com/theimpossibleastronaut/rmw |
40 |
| - cd rmw |
41 |
| - meson setup _build -Dprefix=/usr |
42 |
| - cd _build |
43 |
| - ninja |
44 |
| - install_to_appdir_commands: | |
45 |
| - meson install --destdir=$APPDIR --skip-subprojects |
46 |
| - linuxdeploy_output_version: $VERSION |
47 |
| - linuxdeploy_args: | |
48 |
| - -d rmw/packaging/rmw.desktop \ |
49 |
| - --icon-file=rmw/packaging/rmw_icon_32x32.png \ |
50 |
| - --icon-filename=rmw \ |
51 |
| - --executable=$APPDIR/usr/bin/rmw \ |
52 |
| - -o appimage |
| 36 | + repository: theimpossibleastronaut/rmw |
53 | 37 |
|
54 |
| - - name: Create sha256sum |
55 |
| - run: | |
56 |
| - cd out |
57 |
| - sha256sum $IMAGE_FILENAME > $IMAGE_FILENAME.sha256sum |
| 38 | + - if: ${{ ! contains(matrix.platform, 'amd64') }} |
| 39 | + uses: docker/setup-qemu-action@v3 |
58 | 40 |
|
59 |
| - - name: Upload AppImage |
60 |
| - uses: actions/upload-artifact@v4 |
61 |
| - with: |
62 |
| - name: ${{ env.IMAGE_FILENAME }} |
63 |
| - path: ./out/* |
64 |
| - if-no-files-found: error |
| 41 | + - name: Set variables |
| 42 | + run: | |
| 43 | + if [ -z "$VERSION" ]; then |
| 44 | + echo "VERSION=${{ github.sha }}" >> $GITHUB_ENV |
| 45 | + fi |
65 | 46 |
|
66 |
| - test-netpanzer: |
67 |
| - runs-on: ubuntu-latest |
68 |
| - strategy: |
69 |
| - matrix: |
70 |
| - platform: [amd64] |
71 |
| - steps: |
72 |
| - - name: Checkout |
73 |
| - uses: actions/checkout@v4 |
74 |
| - - name: Use action from self |
75 |
| - uses: ./ |
76 |
| - with: |
77 |
| - platform: ${{ matrix.platform }} |
78 |
| - dependency_commands: | |
79 |
| - sudo apt install -y \ |
80 |
| - gettext \ |
81 |
| - liblua5.1-0-dev \ |
82 |
| - libphysfs-dev \ |
83 |
| - libsdl2-dev \ |
84 |
| - libsdl2-mixer-dev \ |
85 |
| - libsdl2-ttf-dev |
86 |
| - build_commands: | |
87 |
| - git clone --depth 1 https://github.com/netpanzer/netpanzer |
88 |
| - cd netpanzer |
89 |
| - meson setup _build -Dprefix=/usr |
90 |
| - cd _build |
91 |
| - ninja |
92 |
| - install_to_appdir_commands: | |
93 |
| - meson install --destdir=$APPDIR --skip-subprojects |
94 |
| - linuxdeploy_output_version: $VERSION |
95 |
| - linuxdeploy_args: | |
96 |
| - -d netpanzer/support/win32/netpanzer.desktop \ |
97 |
| - --custom-apprun=netpanzer/support/appimage/AppRun \ |
98 |
| - --icon-file=netpanzer/netpanzer.png \ |
99 |
| - --icon-filename=netpanzer \ |
100 |
| - --executable $APPDIR/usr/bin/netpanzer \ |
101 |
| - --output appimage |
| 47 | + - name: Build AppImage |
| 48 | + run: | |
| 49 | + docker run -t \ |
| 50 | + --rm \ |
| 51 | + --platform=${{ matrix.platform }} \ |
| 52 | + -e HOSTUID=$(id -u) \ |
| 53 | + -e VERSION \ |
| 54 | + -v $GITHUB_WORKSPACE:/workspace \ |
| 55 | + -w /workspace \ |
| 56 | + andy5995/linuxdeploy:latest packaging/appimage/pre-appimage.sh |
102 | 57 |
|
103 | 58 | - name: Create sha256sum
|
104 | 59 | run: |
|
| 60 | + IMAGE_FILENAME=$(basename `find out/*AppImage`) |
| 61 | + echo "IMAGE_FILENAME=$IMAGE_FILENAME" >> $GITHUB_ENV |
105 | 62 | cd out
|
106 |
| - sha256sum $IMAGE_FILENAME > $IMAGE_FILENAME.sha256sum |
| 63 | + sha256sum "$IMAGE_FILENAME" > "$IMAGE_FILENAME.sha256sum" |
107 | 64 |
|
108 | 65 | - name: Upload AppImage
|
109 | 66 | uses: actions/upload-artifact@v4
|
110 | 67 | with:
|
111 | 68 | name: ${{ env.IMAGE_FILENAME }}
|
112 | 69 | path: ./out/*
|
113 | 70 | if-no-files-found: error
|
| 71 | + |
| 72 | + #test-netpanzer: |
| 73 | + #runs-on: ubuntu-latest |
| 74 | + #strategy: |
| 75 | + #matrix: |
| 76 | + #platform: [amd64] |
| 77 | + #steps: |
| 78 | + #- name: Checkout |
| 79 | + #uses: actions/checkout@v4 |
| 80 | + #- name: Checkout netpanzer |
| 81 | + #uses: actions/checkout@v4 |
| 82 | + #with: |
| 83 | + #repository: netpanzer/netpanzer |
| 84 | + #path: netpanzer |
| 85 | + #- name: Use action from self |
| 86 | + #uses: ./ |
| 87 | + #with: |
| 88 | + #platform: ${{ matrix.platform }} |
| 89 | + #pre_appimage_script: rmw/packaging/appimage/pre |
| 90 | + #sudo apt install -y \ |
| 91 | + #gettext \ |
| 92 | + #liblua5.1-0-dev \ |
| 93 | + #libphysfs-dev \ |
| 94 | + #libsdl2-dev \ |
| 95 | + #libsdl2-mixer-dev \ |
| 96 | + #libsdl2-ttf-dev |
| 97 | + #build_commands: | |
| 98 | + #git clone --depth 1 https://github.com/netpanzer/netpanzer |
| 99 | + #cd netpanzer |
| 100 | + #meson setup _build -Dprefix=/usr |
| 101 | + #cd _build |
| 102 | + #ninja |
| 103 | + #install_to_appdir_commands: | |
| 104 | + #meson install --destdir=$APPDIR --skip-subprojects |
| 105 | + #linuxdeploy_output_version: $VERSION |
| 106 | + #linuxdeploy_args: | |
| 107 | + #-d netpanzer/support/win32/netpanzer.desktop \ |
| 108 | + #--custom-apprun=netpanzer/support/appimage/AppRun \ |
| 109 | + #--icon-file=netpanzer/netpanzer.png \ |
| 110 | + #--icon-filename=netpanzer \ |
| 111 | + #--executable $APPDIR/usr/bin/netpanzer \ |
| 112 | + #--output appimage |
| 113 | + |
| 114 | + #- name: Create sha256sum |
| 115 | + #run: | |
| 116 | + #cd out |
| 117 | + #sha256sum $IMAGE_FILENAME > $IMAGE_FILENAME.sha256sum |
| 118 | + |
| 119 | + #- name: Upload AppImage |
| 120 | + #uses: actions/upload-artifact@v4 |
| 121 | + #with: |
| 122 | + #name: ${{ env.IMAGE_FILENAME }} |
| 123 | + #path: ./out/* |
| 124 | + #if-no-files-found: error |
0 commit comments