blob: 6a7c54388fbc2398eb49074bcf0ee6e4551446f1 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
|
# Maintainer: Sheikh Limon <sheikhlimon404@gmail.com>
pkgname=goose-desktop
pkgver=1.25.0
pkgrel=1
pkgdesc="Goose Desktop (built from source) - an open source, extensible AI agent that goes beyond code suggestions - install, execute, edit, and test with any LLM"
arch=("x86_64")
url="https://github.com/block/goose"
license=("Apache-2.0")
depends=()
optdepends=()
makedepends=(
"cargo"
"nodejs"
"just"
)
# LTO breaks sqlx/sqlite linkage
options=("!lto" "!debug")
source=(
"${pkgname}-${pkgver}.tar.gz::https://github.com/block/goose/archive/refs/tags/v${pkgver}.tar.gz"
)
b2sums=('e35df8a528f53926f0e730702b843343252a9081dcc7b7299c2f6c60be88b81433d747a8acc865b5952b3acfc14d82a76fd3200d8383a8e99167e733e0839856')
conflicts=("goose-desktop-bin")
provides=("goose-desktop")
prepare() {
cd "goose-${pkgver}"
# Hide menu bar on Linux
sed -i '/useContentSize: true/a\ autoHideMenuBar: process.platform === '\''linux'\'',' \
ui/desktop/src/main.ts
}
build() {
cd "goose-${pkgver}"
just release-binary
cd ui/desktop
# Ignore husky prepare script
npm install --quiet --ignore-scripts --no-audit
npx electron-forge package
}
package() {
cd "goose-${pkgver}"
install -Dm755 "target/release/goose" "$pkgdir/usr/bin/goose"
mkdir -p "$pkgdir/usr/lib/$pkgname"
cp -r "ui/desktop/out/Goose-linux-x64/"* "$pkgdir/usr/lib/$pkgname/"
ln -s /usr/lib/$pkgname/Goose "$pkgdir/usr/bin/$pkgname"
install -Dm644 ui/desktop/forge.deb.desktop "$pkgdir/usr/share/applications/$pkgname.desktop"
sed -i "s|/usr/lib/goose/|/usr/lib/$pkgname/|g" "$pkgdir/usr/share/applications/$pkgname.desktop"
sed -i "s|/usr/share/pixmaps/goose.png|/usr/share/pixmaps/$pkgname.png|g" "$pkgdir/usr/share/applications/$pkgname.desktop"
install -Dm644 ui/desktop/out/Goose-linux-x64/resources/images/icon.png "$pkgdir/usr/share/pixmaps/$pkgname.png"
}
|