From 4ebbf1a123afc4df2d97bf01ffc4a504f4bf4aa3 Mon Sep 17 00:00:00 2001 From: BBaoVanC Date: Thu, 29 Apr 2021 17:44:40 -0500 Subject: [PATCH] Use matrix in integraton.yml --- .github/workflows/integration.yml | 20 ++++++++-------- Makefile | 40 +++++++++++++++---------------- 2 files changed, 30 insertions(+), 30 deletions(-) diff --git a/.github/workflows/integration.yml b/.github/workflows/integration.yml index 8bb1f60..f7d5de9 100644 --- a/.github/workflows/integration.yml +++ b/.github/workflows/integration.yml @@ -15,20 +15,20 @@ jobs: build: runs-on: ubuntu-latest + strategy: + matrix: + arch: + - amd64 + - iphoneos-arm steps: - uses: actions/checkout@v2 - - name: Build debs - run: make debs + - name: Build deb + run: make ${{ matrix.arch }}deb - - name: Upload iphoneos-arm deb as artifact + - name: Upload deb as artifact uses: actions/upload-artifact@v2 with: - name: iphoneos-arm-deb - path: com.propr.nekofetch*iphoneos-arm.deb - - name: Upload amd64 deb as artifact - uses: actions/upload-artifact@v2 - with: - name: amd64-deb - path: nekofetch*amd64.deb + name: ${{ matrix.arch }}-deb + path: "*nekofetch*.deb" diff --git a/Makefile b/Makefile index ee19b07..186802a 100644 --- a/Makefile +++ b/Makefile @@ -7,11 +7,11 @@ PREFIX ?= /usr all: @echo "Nekofetch doesn't need to be compiled, run 'make install' to install" -debs: options iosdeb amd64deb +debs: options iphoneos-armdeb amd64deb -debroots: options iosdebroot amd64debroot +debroots: options iphoneos-armdebroot amd64debroot -controls: options ioscontrol amd64control +controls: options iphoneos-armcontrol amd64control options: @echo "VERSION: $(VERSION)" @@ -25,24 +25,24 @@ install: uninstall: rm -f $(DESTDIR)$(PREFIX)/bin/nekofetch -ioscontrol: - cp control.template ioscontrol - sed -i 's/PACKAGE/com.propr.nekofetch/' ioscontrol - sed -i 's/ARCH/iphoneos-arm/' ioscontrol - sed -i 's/VERSION/$(VERSION)/' ioscontrol +iphoneos-armcontrol: + cp control.template iphoneos-armcontrol + sed -i 's/PACKAGE/com.propr.nekofetch/' iphoneos-armcontrol + sed -i 's/ARCH/iphoneos-arm/' iphoneos-armcontrol + sed -i 's/VERSION/$(VERSION)/' iphoneos-armcontrol amd64control: cp control.template amd64control sed -i 's/PACKAGE/nekofetch/' amd64control sed -i 's/ARCH/amd64/' amd64control sed -i 's/VERSION/$(VERSION)/' amd64control -iosdebroot: ioscontrol - mkdir -p iosdebroot/DEBIAN - mkdir -p iosdebroot/usr/bin - mkdir -p iosdebroot/usr/share/doc/nekofetch - cp ioscontrol iosdebroot/DEBIAN/control - cp LICENSE iosdebroot/usr/share/doc/nekofetch/copyright - cp nekofetch iosdebroot/usr/bin/nekofetch +iphoneos-armdebroot: iphoneos-armcontrol + mkdir -p iphoneos-armdebroot/DEBIAN + mkdir -p iphoneos-armdebroot/usr/bin + mkdir -p iphoneos-armdebroot/usr/share/doc/nekofetch + cp iphoneos-armcontrol iphoneos-armdebroot/DEBIAN/control + cp LICENSE iphoneos-armdebroot/usr/share/doc/nekofetch/copyright + cp nekofetch iphoneos-armdebroot/usr/bin/nekofetch amd64debroot: amd64control mkdir -p amd64debroot/DEBIAN mkdir -p amd64debroot/usr/bin @@ -51,14 +51,14 @@ amd64debroot: amd64control cp LICENSE amd64debroot/usr/share/doc/nekofetch/copyright cp nekofetch amd64debroot/usr/bin/nekofetch -iosdeb: iosdebroot - dpkg-deb -b "iosdebroot" "com.propr.nekofetch_$(VERSION)_iphoneos-arm.deb" +iphoneos-armdeb: iphoneos-armdebroot + dpkg-deb -b "iphoneos-armdebroot" "com.propr.nekofetch_$(VERSION)_iphoneos-arm.deb" amd64deb: amd64debroot dpkg-deb -b "amd64debroot" "nekofetch_$(VERSION)_amd64.deb" clean: - rm -rf iosdebroot amd64debroot - rm -f ioscontrol amd64control + rm -rf iphoneos-armdebroot amd64debroot + rm -f iphoneos-armcontrol amd64control rm -f com.propr.nekofetch_*_iphoneos-arm.deb nekofetch_*_amd64.deb -.PHONY: all debs debroots controls options install uninstall iosdeb amd64deb clean +.PHONY: all debs debroots controls options install uninstall iphoneos-armdeb amd64deb clean