@@ -23,17 +23,22 @@ jobs:
23
23
- name : Get checksums
24
24
id : get_checksums
25
25
run : |
26
- # Download the .deb file
26
+ # Download the x86_64 .deb
27
27
wget https://github.com/foss42/apidash/releases/download/v${{ steps.get_version.outputs.version }}/apidash-linux-amd64.deb
28
28
29
- # Download the LICENSE file
29
+ # Download the arm64 .deb
30
+ wget https://github.com/foss42/apidash/releases/download/v${{ steps.get_version.outputs.version }}/apidash-linux-arm64.deb
31
+
32
+ # Download the LICENSE
30
33
wget https://raw.githubusercontent.com/foss42/apidash/main/LICENSE
31
34
32
35
# Generate SHA512 checksums
33
- DEB_CHECKSUM=$(sha512sum apidash-linux-amd64.deb | awk '{print $1}')
36
+ DEB_X86_64_CHECKSUM=$(sha512sum apidash-linux-amd64.deb | awk '{print $1}')
37
+ DEB_ARM64_CHECKSUM=$(sha512sum apidash-linux-arm64.deb | awk '{print $1}')
34
38
LICENSE_CHECKSUM=$(sha512sum LICENSE | awk '{print $1}')
35
39
36
- echo "deb_checksum=$DEB_CHECKSUM" >> $GITHUB_OUTPUT
40
+ echo "deb_x86_64_checksum=$DEB_X86_64_CHECKSUM" >> $GITHUB_OUTPUT
41
+ echo "deb_arm64_checksum=$DEB_ARM64_CHECKSUM" >> $GITHUB_OUTPUT
37
42
echo "license_checksum=$LICENSE_CHECKSUM" >> $GITHUB_OUTPUT
38
43
39
44
- name : Publish AUR package
@@ -47,29 +52,37 @@ jobs:
47
52
pkgver=${{ steps.get_version.outputs.version }}
48
53
pkgrel=1
49
54
pkgdesc="Beautiful open-source cross-platform API Client"
50
- arch=('x86_64')
55
+ arch=('x86_64' 'aarch64' )
51
56
url="https://apidash.dev"
52
57
license=('Apache-2.0')
53
58
depends=()
54
59
options=('!emptydirs' '!strip')
55
- source=("https://github.com/foss42/apidash/releases/download/v${pkgver}/apidash-linux-amd64.deb"
56
- 'LICENSE')
57
- sha512sums=('${{ steps.get_checksums.outputs.deb_checksum }}'
58
- '${{ steps.get_checksums.outputs.license_checksum }}')
60
+ source=("LICENSE::https://raw.githubusercontent.com/foss42/apidash/main/LICENSE")
61
+ source_x86_64=("apidash-linux-amd64.deb::https://github.com/foss42/apidash/releases/download/v${{ steps.get_version.outputs.version }}/apidash-linux-amd64.deb")
62
+ source_aarch64=("apidash-linux-arm64.deb::https://github.com/foss42/apidash/releases/download/v${{ steps.get_version.outputs.version }}/apidash-linux-arm64.deb")
63
+ sha512sums=('${{ steps.get_checksums.outputs.license_checksum }}')
64
+ sha512sums_x86_64=('${{ steps.get_checksums.outputs.deb_x86_64_checksum }}')
65
+ sha512sums_aarch64=('${{ steps.get_checksums.outputs.deb_arm64_checksum }}')
59
66
60
67
package() {
61
- bsdtar -xf data.tar.zst -C "$pkgdir/"
62
-
63
- # Fix permissions of directories.
64
- find "$pkgdir/" -type d -exec chmod 755 {} \;
65
-
66
- # Create a symlink inside the /usr/bin directory.
67
- mkdir -p "${pkgdir}/usr/bin"
68
- ln -s /usr/share/apidash/apidash "$pkgdir/usr/bin/apidash"
69
-
70
- install -Dm644 LICENSE "$pkgdir"/usr/share/licenses/apidash/LICENSE
68
+ if [ "$CARCH" = "x86_64" ]; then
69
+ _debfile="$srcdir/apidash-linux-amd64.deb"
70
+ elif [ "$CARCH" = "aarch64" ]; then
71
+ _debfile="$srcdir/apidash-linux-arm64.deb"
72
+ fi
73
+ ar -x "${_debfile}" data.tar.zst
74
+ bsdtar -xf data.tar.zst -C "$pkgdir/"
75
+
76
+ # Fix permissions of directories
77
+ find "$pkgdir/" -type d -exec chmod 755 {} \;
78
+
79
+ # Create a symlink inside /usr/bin
80
+ mkdir -p "${pkgdir}/usr/bin"
81
+ ln -s /usr/share/apidash/apidash "$pkgdir/usr/bin/apidash"
82
+
83
+ install -Dm644 "$srcdir/LICENSE" "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
71
84
}
72
85
commit_username : ${{ secrets.AUR_USERNAME }}
73
86
commit_email : ${{ secrets.AUR_EMAIL }}
74
87
ssh_private_key : ${{ secrets.AUR_SSH_PRIVATE_KEY }}
75
- commit_message : " Update to version ${{ steps.get_version.outputs.version }}"
88
+ commit_message : " Update to version ${{ steps.get_version.outputs.version }}"
0 commit comments