@@ -322,28 +322,39 @@ jobs:
322
322
shell : bash
323
323
324
324
- name : Set ownership of executables to root:root
325
- if : ${{ matrix.config.os != 'windows-latest' }} && matrix.config.image == ''
326
- run : sudo chown -R root:root build
327
-
328
- - name : Set ownership of executables to root:root (container)
329
- if : ${{ matrix.config.os != 'windows-latest' }} && matrix.config.image != ''
330
- run : chown -R root:root build
325
+ if : ${{ matrix.config.os != 'windows-latest' }}
326
+ run : |
327
+ if [[ -z "${{ matrix.config.image }}" ]]; then
328
+ sudo chown -R root:root build
329
+ else
330
+ chown -R root:root build
331
+ fi
331
332
332
333
- name : Packing release
333
334
env :
334
335
ARCHIVE_EXT : ${{ matrix.config.release_extension }}
335
336
run : |
336
337
cd build
337
338
if [[ "${{ matrix.config.os }}" != "windows-latest" ]]; then
338
- sudo ${{ matrix.config.archive_command }} "${DESTDIR}${ARCHIVE_EXT}" $DESTDIR
339
+ if [[ -z "${{ matrix.config.image }}" ]]; then
340
+ sudo ${{ matrix.config.archive_command }} "${DESTDIR}${ARCHIVE_EXT}" $DESTDIR
341
+ else
342
+ ${{ matrix.config.archive_command }} "${DESTDIR}${ARCHIVE_EXT}" $DESTDIR
343
+ fi
339
344
else
340
345
${{ matrix.config.archive_command }} "${DESTDIR}${ARCHIVE_EXT}" $DESTDIR
341
346
fi
342
347
shell : bash
343
348
344
349
- name : Set ownership of tar archive to root:root
345
350
if : ${{ matrix.config.os != 'windows-latest' }}
346
- run : sudo chown root:root build/"${DESTDIR}${ARCHIVE_EXT}"
351
+ run : |
352
+ if [[ -z "${{ matrix.config.image }}" ]]; then
353
+ sudo chown root:root build/"${DESTDIR}${ARCHIVE_EXT}"
354
+ else
355
+ chown root:root build/"${DESTDIR}${ARCHIVE_EXT}"
356
+ fi
357
+
347
358
348
359
- name : Generate Hashes
349
360
if : ${{ matrix.config.publish_release }}
0 commit comments