From 2d735947814c9a263460ed5d46a2241dbe719bc1 Mon Sep 17 00:00:00 2001 From: clsty Date: Mon, 17 Jun 2024 16:46:14 +0800 Subject: [PATCH] Use local PKGBUILD for OneUI4-icon --- .../PKGBUILD | 23 +++++++++++++++++++ install.sh | 13 ++++------- scriptdata/installers | 1 + 3 files changed, 28 insertions(+), 9 deletions(-) create mode 100644 arch-packages/illogical-impulse-oneui4-icons-git/PKGBUILD diff --git a/arch-packages/illogical-impulse-oneui4-icons-git/PKGBUILD b/arch-packages/illogical-impulse-oneui4-icons-git/PKGBUILD new file mode 100644 index 000000000..72fcadb05 --- /dev/null +++ b/arch-packages/illogical-impulse-oneui4-icons-git/PKGBUILD @@ -0,0 +1,23 @@ +pkgname=illogical-impulse-oneui4-icons-git +_pkgname=OneUI4-Icons +pkgver=r64.9ba2190 +pkgrel=1 +pkgdesc="A fork of mjkim0727/OneUI4-Icons for illogical-impulse dotfiles." +arch=('x86_64') +url="https://github.com/end-4/OneUI4-Icons" +license=('GPL3') +source=("git+${url}.git") +sha256sums=('SKIP') + +pkgver(){ + cd $srcdir/$_pkgname + printf 'r%s.%s' "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)" +} + +package() { + cd $srcdir/$_pkgname + install -dm755 "$pkgdir/usr/share/icons" + for _i in OneUI{,-dark,-light}; do + cp -dr --no-preserve=mode "$_i" "$pkgdir/usr/share/icons/$_i" + done +} diff --git a/install.sh b/install.sh index 439dc6648..de90e2a1d 100755 --- a/install.sh +++ b/install.sh @@ -104,7 +104,9 @@ install-local-pkgbuild() { } # Install core dependencies from the meta-packages -metapkgs=(./arch-packages/illogical-impulse-{audio,backlight,basic,ags,fonts-themes,gnome,gtk,microtex,portal,python,screencapture,widgets}) +metapkgs=(./arch-packages/illogical-impulse-{audio,backlight,basic,fonts-themes,gnome,gtk,microtex,portal,python,screencapture,widgets}) +metapkgs+=(./arch-packages/illogical-impulse-ags) +metapkgs+=(./arch-packages/illogical-impulse-oneui4-icons-git) for i in "${metapkgs[@]}"; do metainstallflags="--needed" @@ -167,14 +169,6 @@ v gsettings set org.gnome.desktop.interface font-name 'Rubik 11' printf "\e[36m[$0]: 2. Installing parts from source repo\e[0m\n" sleep 1 -if $(test -d /usr/local/share/icons/OneUI); then - echo -e "\e[33m[$0]: Icon pack \"OneUI\" already exists, no need to install.\e[0m" - echo -e "\e[34mYou can reinstall it in order to update to the latest version anyway.\e[0m" - ask_OneUI=$ask -else ask_OneUI=true -fi -if $ask_OneUI;then showfun install-OneUI;v install-OneUI;fi - if $(test -d /usr/local/share/icons/Bibata-Modern-Classic); then echo -e "\e[33m[$0]: Cursor theme \"Bibata-Modern-Classic\" already exists, no need to install.\e[0m" echo -e "\e[34mYou can reinstall it in order to update to the latest version anyway.\e[0m" @@ -286,6 +280,7 @@ warn_files_tests+=(/usr/local/bin/ags) warn_files_tests+=(/usr/local/share/com.github.Aylur.ags) warn_files_tests+=(/usr/local/share/fonts/TTF/Rubik{,-Italic}[wght].ttf) warn_files_tests+=(/usr/local/share/fonts/TTF/Gabarito-{Black,Bold,ExtraBold,Medium,Regular,SemiBold}.ttf) +warn_files_tests+=(/usr/local/share/icons/OneUI{,-dark,-light}) for i in $warn_files_test; do test -f $t && warn_files+=($t) test -d $t && warn_files+=($t) diff --git a/scriptdata/installers b/scriptdata/installers index b8a76d7bd..2d6ded505 100644 --- a/scriptdata/installers +++ b/scriptdata/installers @@ -66,6 +66,7 @@ install-Gabarito (){ x cd $base } +# Not for Arch(based) distro. install-OneUI (){ x mkdir -p $base/cache/OneUI4-Icons x cd $base/cache/OneUI4-Icons