PKGBUILD: Point desktop Exec at update shim
Build Arch package / build (push) Successful in 27s

0.30 shipped Exec="/opt/Grok Bot/grok-bot", so the app menu skipped
/usr/bin/grok-bot and never auto-updated. Always rewrite the desktop
Exec to the PATH shim after unpacking the .deb so that cannot regress.
Bump pkgrel to 2; clearer sudo failure hint in the launch shim.
This commit is contained in:
s1d3sw1ped_bot
2026-09-02 15:21:20 +00:00
parent 7fea71c3ec
commit 4b2bc70766
4 changed files with 14 additions and 4 deletions
+10 -2
View File
@@ -10,7 +10,7 @@
pkgname=grok-bot-bin
pkgver=0.35.0
_commit=1c5a6ceb364c4dd53f0069f72cc4239220ed471e
pkgrel=1
pkgrel=2
pkgdesc="Grok Bot desktop agent (official .deb repackaged)"
arch=('x86_64')
url="https://cursor.com/download/bot"
@@ -44,7 +44,7 @@ source=(
noextract=("grok-bot_${pkgver}_amd64.deb")
sha256sums=(
'ed254e819d0f0419a1df9771009363074f65f80d8175d2ee0fc62900087ebd99'
'886c8b55eb44d2f7812be50dcc1571907dc2d7e755171e67e916f497634f09eb'
'1c5a3599db15816caa839fc9e088ba9798757e44fec89c066ef5f6f3c0972aee'
)
package() {
@@ -56,6 +56,14 @@ package() {
# Keep provides(sand) on PATH; both names run the same shim.
ln -sf grok-bot "$pkgdir/usr/bin/sand"
# Always point the menu entry at the PATH shim. Upstream .desktop has used
# Exec="/opt/Grok Bot/grok-bot" (0.30) which bypasses auto-update; rewrite
# every build so a future /opt regression cannot ship again.
if [[ -f "$pkgdir/usr/share/applications/grok-bot.desktop" ]]; then
sed -i 's|^Exec=.*|Exec=grok-bot %U|' \
"$pkgdir/usr/share/applications/grok-bot.desktop"
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