Caleb Maclennan pushed to branch main at Arch Linux / Packaging / Packages / 
ghostty


Commits:
25783b68 by Peter Jung at 2024-12-27T14:47:10+01:00
ghostty: Split out terminfo and shell-integration

Currently, when using ghostty via ssh on a server several programs, like top 
and tmux are not working.
Installing the ghostty package results into a classic server enviroment into 
90-120 packages, which is not really required for servers.

Therefore split the shell-integration and terminfo like we do on other 
terminals integration, for example kitty.
The base "ghostty" package will depend on the terminfo and shell integration.

Signed-off-by: Peter Jung <[email protected]>

- - - - -


2 changed files:

- .SRCINFO
- PKGBUILD


Changes:

=====================================
.SRCINFO
=====================================
@@ -33,3 +33,37 @@ pkgbase = ghostty
        sha256sums = 
d4788ab75b2d410cda3f7e96122183249b0aaf5be6228b33f1d5da3748ab1446
 
 pkgname = ghostty
+       depends = bzip2
+       depends = fontconfig
+       depends = libfontconfig.so
+       depends = freetype2
+       depends = libfreetype.so
+       depends = gcc-libs
+       depends = glibc
+       depends = glib2
+       depends = libglib-2.0.so
+       depends = libgio-2.0.so
+       depends = libgobject-2.0.so
+       depends = gtk4
+       depends = libgtk-4.so
+       depends = harfbuzz
+       depends = libharfbuzz.so
+       depends = libadwaita
+       depends = libadwaita-1.so
+       depends = libpng
+       depends = oniguruma
+       depends = pixman
+       depends = zlib
+       depends = ghostty-terminfo
+       depends = ghostty-shell-integration
+
+pkgname = ghostty-terminfo
+       pkgdesc = Terminfo for ghostty
+       depends = 
+
+pkgname = ghostty-shell-integration
+       pkgdesc = Shell integration scripts for ghostty
+       depends = 
+       optdepends = bash: Bash completions
+       optdepends = zsh: ZSH completions
+       optdepends = fish: Fish completions


=====================================
PKGBUILD
=====================================
@@ -1,8 +1,10 @@
 # Maintainer: Caleb Maclennan <[email protected]>
+# Maintainer: Peter Jung <[email protected]>
 
-pkgname=ghostty
-pkgrel=2
+pkgbase=ghostty
+pkgname=(ghostty ghostty-terminfo ghostty-shell-integration)
 pkgver=1.0.0
+pkgrel=2
 pkgdesc='Fast, native, feature-rich terminal emulator pushing modern features'
 arch=(x86_64)
 url="https://github.com/ghostty-org/ghostty";
@@ -31,12 +33,12 @@ 
source=("git+https://github.com/ghostty-org/ghostty#tag=v${pkgver}";)
 sha256sums=('d4788ab75b2d410cda3f7e96122183249b0aaf5be6228b33f1d5da3748ab1446')
 
 prepare() {
-       cd "$pkgname"
+       cd "$pkgbase"
        ZIG_GLOBAL_CACHE_DIR="$srcdir/zig-global-cache/" 
./nix/build-support/fetch-zig-cache.sh
 }
 
 build() {
-  cd "$pkgname"
+  cd "$pkgbase"
   zig build \
     --summary all \
     --prefix "$PWD/build/usr" \
@@ -47,9 +49,33 @@ build() {
     -Demit-docs
 }
 
-package() {
-  cd "$pkgname"
+package_ghostty() {
+  depends+=('ghostty-terminfo' 'ghostty-shell-integration')
+  cd "$pkgbase"
   cp -a build/* "$pkgdir/"
   install -Dm0644 -t "$pkgdir/usr/share/licenses/$pkgname/" LICENSE
+
+  rm -r "$pkgdir"/usr/share/terminfo
+  rm -r "$pkgdir"/usr/share/ghostty/shell-integration
+}
+
+package_ghostty-terminfo() {
+  pkgdesc='Terminfo for ghostty'
+  depends=()
+
+  cd "$pkgbase"
+  mkdir -p "$pkgdir/usr/share/terminfo"
+  cp -r build/usr/share/terminfo/* "$pkgdir/usr/share/terminfo/"
 }
 
+package_ghostty-shell-integration() {
+  pkgdesc='Shell integration scripts for ghostty'
+  depends=()
+  optdepends+=('bash: Bash completions'
+               'zsh: ZSH completions'
+               'fish: Fish completions')
+
+  cd "$pkgbase"
+  mkdir -p "$pkgdir/usr/share/ghostty/shell-integration"
+  cp -r build/usr/share/ghostty/shell-integration/* 
"$pkgdir/usr/share/ghostty/shell-integration/"
+}



View it on GitLab: 
https://gitlab.archlinux.org/archlinux/packaging/packages/ghostty/-/commit/25783b68a5a45f13f20dd44b03818c97fc3e61ef

-- 
View it on GitLab: 
https://gitlab.archlinux.org/archlinux/packaging/packages/ghostty/-/commit/25783b68a5a45f13f20dd44b03818c97fc3e61ef
You're receiving this email because of your account on gitlab.archlinux.org.


Reply via email to