Files
grok-bot-bin/PKGBUILD
T
s1d3sw1ped_bot 33e191de2b
Build Arch package / build (push) Failing after 11s
pkgbuild: Add grok-bot-bin from official .deb
Temporary Arch/CachyOS packaging until upstream ships a native package.
Pulls Cursor's amd64 deb by commit from the linux-x64 update feed.
Includes update script and Gitea Actions for bump + makepkg release.
2026-09-02 01:10:40 +00:00

71 lines
2.2 KiB
Bash

# Maintainer: s1d3sw1ped <https://git.s1d3sw1ped.com/s1d3sw1ped>
# Unofficial Arch/CachyOS repackage of the official Grok Bot .deb.
# Temporary until upstream ships a native package.
#
# Version oracle (commit is in the download URL):
# https://api2.cursor.sh/updates/api/update/linux-x64/sand/0.0.0/00000000-0000-0000-0000-000000000000/stable
# Deb URL:
# https://downloads.cursor.com/grokbot/stable/<commit>/linux/x64/grok-bot_<pkgver>_amd64.deb
pkgname=grok-bot-bin
pkgver=0.30.0
_commit=2385d097738b3719cc5ecd9281a107aa106215f1
pkgrel=1
pkgdesc="Grok Bot desktop agent (official .deb repackaged)"
arch=('x86_64')
url="https://cursor.com/download/bot"
license=('LicenseRef-proprietary')
depends=(
'alsa-lib'
'at-spi2-core'
'gtk3'
'libdrm'
'libnotify'
'libsecret'
'libxkbcommon'
'libxss'
'libxtst'
'mesa'
'nss'
'xdg-utils'
)
optdepends=(
'libappindicator-gtk3: tray icon support'
)
provides=('grok-bot' 'sand')
conflicts=('grok-bot' 'sand')
replaces=('sand')
options=('!strip' '!debug')
source=("https://downloads.cursor.com/grokbot/stable/${_commit}/linux/x64/grok-bot_${pkgver}_amd64.deb")
noextract=("grok-bot_${pkgver}_amd64.deb")
sha256sums=('fb888b2204c8a51c71a9f5f9a2913ac10561f3ef6939c1245ecae4e837d4ada2')
package() {
bsdtar -O -xf "$srcdir/grok-bot_${pkgver}_amd64.deb" data.tar.xz \
| bsdtar -xJf - -C "$pkgdir"
if [[ -f "$pkgdir/opt/Grok Bot/grok-bot" ]]; then
_bin=grok-bot
else
_bin=sand
fi
install -dm755 "$pkgdir/usr/bin"
ln -sf "/opt/Grok Bot/${_bin}" "$pkgdir/usr/bin/${_bin}"
if [[ "$_bin" != grok-bot ]]; then
ln -sf "/opt/Grok Bot/${_bin}" "$pkgdir/usr/bin/grok-bot"
fi
# Path contains a space, so Chromium cannot use the SUID sandbox.
# Arch/CachyOS kernels have user namespaces; keep chrome-sandbox non-setuid.
if [[ -f "$pkgdir/opt/Grok Bot/chrome-sandbox" ]]; then
chmod 0755 "$pkgdir/opt/Grok Bot/chrome-sandbox"
fi
install -dm755 "$pkgdir/usr/share/licenses/$pkgname"
ln -sf "/opt/Grok Bot/LICENSE.electron.txt" \
"$pkgdir/usr/share/licenses/$pkgname/LICENSE.electron.txt"
ln -sf "/opt/Grok Bot/LICENSES.chromium.html" \
"$pkgdir/usr/share/licenses/$pkgname/LICENSES.chromium.html"
}