feat(packages): add pkgbuild for snigdha os gnome config

This commit is contained in:
Eshan Roy (Eshanized)
2024-05-02 16:25:49 +05:30
parent 851eb035b5
commit 577d4034dc
2 changed files with 55 additions and 0 deletions

View File

@@ -0,0 +1,26 @@
# Maintainer: Eshan Roy <eshan@snigdhaos.org>
pkgname=snigdhaos-gnome-config
pkgver=1
_pkgver=1.0.0
pkgrel=1
arch=('any')
url="https://github.com/Snigdha-OS/$pkgname"
license=('MIT')
makedepends=('coreutils')
source=("https://github.com/Snigdha-OS/$pkgname/archive/refs/tags/{$_pkgver}.tar.gz")
sha256sums=('SKIP')
pkgdesc='Snigdha OS Gnome Config'
install=$pkgname.install
provides=('snigdhaos-desktop-config')
conflicts=('snigdhaos-desktop-config')
package() {
install -d "$pkgdir"/etc
cp -rf "$srcdir"/$pkgname-$_pkgver/etc "$pkgdir"
depends=('snigdhaos-backgrounds'
'gnome-themes-extra'
'kvantum'
'kvantum-qt5'
'ttf-overpass')
}

View File

@@ -0,0 +1,29 @@
# Font-icon directories
FONT_DIRS="/usr/share/fonts/TTF /usr/share/fonts/OTF /usr/share/fonts/misc"
ICON_DIR="/usr/share/icons/hicolor"
GLIB_SCHEMA_DIR="usr/share/glib-2.0/schemas"
# Font-related commands
update_fonts() {
mkfontscale "$FONT_DIRS" >/dev/null 2>&1
mkfontdir "$FONT_DIRS" >/dev/null 2>&1
fc-cache -s >/dev/null
}
# GTK related commands
update_gtk() {
glib-compile-schemas $GLIB_SCHEMA_DIR
gtk-update-icon-cache -ftq $ICON_DIR
/bin/sh -c 'dconf update'
}
# Post installation
post_install() {
post_upgrade
}
# Post upgrade
post_upgrade() {
update_fonts
update_gtk
}