Compare commits
20 Commits
fd94f7ade8
...
864d69b582
Author | SHA1 | Date | |
---|---|---|---|
864d69b582 | |||
3cf00d0cd2 | |||
9fa5ce277e | |||
1a9ed580a0 | |||
c07cb59ff0 | |||
4c96bb9406 | |||
700235c52e | |||
9f9713a673 | |||
11f5d9da18 | |||
58b415ae8d | |||
275b811f0f | |||
2268c4c2bd | |||
ca054b9b6e | |||
a729acbbef | |||
d909158646 | |||
61afd40bfa | |||
66feb5daf6 | |||
af82c8bd40 | |||
2f029b03a7 | |||
22bcfe821b |
17
PKGBUILD
17
PKGBUILD
|
@ -1,6 +1,6 @@
|
||||||
# Maintainer: TROM <contact@tromsite.com>
|
# Maintainer: TROM <contact@tromsite.com>
|
||||||
pkgname=tromjaro-fixes
|
pkgname=tromjaro-fixes
|
||||||
pkgver=1.3.0
|
pkgver=1.3.1
|
||||||
pkgrel=1
|
pkgrel=1
|
||||||
pkgdesc="Various fixes for TROMjaro OS"
|
pkgdesc="Various fixes for TROMjaro OS"
|
||||||
arch=(any)
|
arch=(any)
|
||||||
|
@ -11,15 +11,15 @@ depends=('xfce4-appfinder'
|
||||||
'rsync'
|
'rsync'
|
||||||
'inotify-tools'
|
'inotify-tools'
|
||||||
'qt5-styleplugins'
|
'qt5-styleplugins'
|
||||||
'qt5ct'
|
|
||||||
'qt6ct'
|
|
||||||
'qt6gtk2'
|
'qt6gtk2'
|
||||||
'qqc2-desktop-style')
|
'qqc2-desktop-style')
|
||||||
provides=('tromjaro-fixes')
|
provides=('tromjaro-fixes')
|
||||||
backup=()
|
backup=()
|
||||||
options=(!strip)
|
options=(!strip)
|
||||||
source=('scalable.zip::https://www.drive.tromsite.com/s/y8Gm7q6wLrXmtEN/download')
|
source=('scalable.zip::https://www.drive.tromsite.com/s/y8Gm7q6wLrXmtEN/download'
|
||||||
sha256sums=('SKIP')
|
'tromjaro-fixes.sh')
|
||||||
|
sha256sums=('SKIP'
|
||||||
|
'SKIP')
|
||||||
install='fixes-package.install'
|
install='fixes-package.install'
|
||||||
prepare() {
|
prepare() {
|
||||||
cp -R ../bin ../flatpak-overrides ../alpm-hooks ../systemd .
|
cp -R ../bin ../flatpak-overrides ../alpm-hooks ../systemd .
|
||||||
|
@ -43,11 +43,16 @@ package() {
|
||||||
install -d ${pkgdir}/usr/lib/systemd/user
|
install -d ${pkgdir}/usr/lib/systemd/user
|
||||||
install -Dm644 ${srcdir}/systemd/services/* ${pkgdir}/usr/lib/systemd/user
|
install -Dm644 ${srcdir}/systemd/services/* ${pkgdir}/usr/lib/systemd/user
|
||||||
|
|
||||||
# copy zafiro icons dark
|
# copy zafiro dark icons
|
||||||
install -d ${pkgdir}/usr/local/share/icons/zafiro-dark/apps/scalable
|
install -d ${pkgdir}/usr/local/share/icons/zafiro-dark/apps/scalable
|
||||||
install -Dm755 ${srcdir}/scalable/* ${pkgdir}/usr/local/share/icons/zafiro-dark/apps/scalable
|
install -Dm755 ${srcdir}/scalable/* ${pkgdir}/usr/local/share/icons/zafiro-dark/apps/scalable
|
||||||
|
|
||||||
# copy zafiro icons
|
# copy zafiro icons
|
||||||
install -d ${pkgdir}/usr/local/share/icons/zafiro/apps/scalable
|
install -d ${pkgdir}/usr/local/share/icons/zafiro/apps/scalable
|
||||||
install -Dm755 ${srcdir}/scalable/* ${pkgdir}/usr/local/share/icons/zafiro/apps/scalable
|
install -Dm755 ${srcdir}/scalable/* ${pkgdir}/usr/local/share/icons/zafiro/apps/scalable
|
||||||
|
|
||||||
|
# copy tromjaro-fixes.sh
|
||||||
|
install -d ${pkgdir}/etc/profile.d/
|
||||||
|
install -Dm644 ${srcdir}/tromjaro-fixes.sh ${pkgdir}/etc/profile.d/
|
||||||
|
|
||||||
}
|
}
|
|
@ -2,10 +2,9 @@
|
||||||
Operation = Upgrade
|
Operation = Upgrade
|
||||||
Type = Package
|
Type = Package
|
||||||
Target = qt5-base
|
Target = qt5-base
|
||||||
Target = qt6-base
|
|
||||||
|
|
||||||
|
|
||||||
[Action]
|
[Action]
|
||||||
Description = Reinstalling needed packages for theming QT applications...
|
Description = Reinstalling needed packages for theming QT applications...
|
||||||
When = PostTransaction
|
When = PostTransaction
|
||||||
Exec = /usr/bin/reinstall-for-qt
|
Exec = /usr/bin/reinstall-for-qt5
|
10
alpm-hooks/reinstall-for-qt6.hook
Normal file
10
alpm-hooks/reinstall-for-qt6.hook
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
[Trigger]
|
||||||
|
Operation = Upgrade
|
||||||
|
Type = Package
|
||||||
|
Target = qt6-base
|
||||||
|
|
||||||
|
|
||||||
|
[Action]
|
||||||
|
Description = Reinstalling needed packages for theming QT applications...
|
||||||
|
When = PostTransaction
|
||||||
|
Exec = /usr/bin/reinstall-for-qt6
|
|
@ -12,36 +12,6 @@ sync_theme() {
|
||||||
gsettings set org.gnome.desktop.interface gtk-theme "$theme"
|
gsettings set org.gnome.desktop.interface gtk-theme "$theme"
|
||||||
}
|
}
|
||||||
|
|
||||||
setvalue() {
|
|
||||||
grep -qz "^\[Appearance\][^\[]*$1=$2" "$file" && return
|
|
||||||
if grep -qz "^\[Appearance\][^\[]*$1=" "$file"; then
|
|
||||||
sed -i "/\[Appearance\]/,/^\s*$1=/{s/^\s*$1=.*$/$1=$2/}" "$file"
|
|
||||||
else
|
|
||||||
sed -i "/\[Appearance\]/a $1=$2" "$file"
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
sync_icon_theme() {
|
|
||||||
# Get the current icon theme
|
|
||||||
icon_theme=$(xfconf-query -c xsettings -p /Net/IconThemeName)
|
|
||||||
# Apply the same theme in qt5ct and qt6ct configuration
|
|
||||||
for file in "$HOME"/.config/qt5ct/qt5ct.conf "$HOME"/.config/qt6ct/qt6ct.conf; do
|
|
||||||
# Create the config directory
|
|
||||||
dir=$(dirname "$file")
|
|
||||||
mkdir -p "$dir" || { echo "failed to make directory $dir"; continue; }
|
|
||||||
# Create the config file appropriately
|
|
||||||
if grep -q '^\[Appearance\]' "$file"; then
|
|
||||||
setvalue 'icon_theme' "$icon_theme"
|
|
||||||
setvalue 'style' 'gtk2'
|
|
||||||
elif grep -q '\S' "$file"; then
|
|
||||||
tail -n1 "$file" | grep -qx '\s*' && begin='' || begin='\n'
|
|
||||||
printf '%b[Appearance]\nicon_theme=%s\nstyle=gtk2\n' "$begin" "$icon_theme" >> "$file"
|
|
||||||
else
|
|
||||||
printf '[Appearance]\nicon_theme=%s\nstyle=gtk2\n' "$icon_theme" > "$file"
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
}
|
|
||||||
|
|
||||||
sync_font() {
|
sync_font() {
|
||||||
# Get the current system font
|
# Get the current system font
|
||||||
font=$(xfconf-query -c xsettings -p /Gtk/FontName)
|
font=$(xfconf-query -c xsettings -p /Gtk/FontName)
|
||||||
|
@ -50,13 +20,11 @@ sync_font() {
|
||||||
}
|
}
|
||||||
|
|
||||||
sync_theme
|
sync_theme
|
||||||
sync_icon_theme
|
|
||||||
sync_font
|
sync_font
|
||||||
|
|
||||||
while read -r line; do
|
while read -r line; do
|
||||||
case "$line" in
|
case "$line" in
|
||||||
'set: /Net/ThemeName') sync_theme ;;
|
'set: /Net/ThemeName') sync_theme ;;
|
||||||
'set: /Net/IconThemeName') sync_icon_theme ;;
|
|
||||||
'set: /Gtk/FontName') sync_font ;;
|
'set: /Gtk/FontName') sync_font ;;
|
||||||
esac
|
esac
|
||||||
done < <(xfconf-query -c xsettings -m)
|
done < <(xfconf-query -c xsettings -m)
|
||||||
|
|
|
@ -2,4 +2,4 @@
|
||||||
parent_process=$(ps -p $PPID -o comm=)
|
parent_process=$(ps -p $PPID -o comm=)
|
||||||
[ "$parent_process" = 'pacman' ] || [ "$parent_process" = 'pamac-daemon' ] || exit
|
[ "$parent_process" = 'pacman' ] || [ "$parent_process" = 'pamac-daemon' ] || exit
|
||||||
rm /var/lib/pacman/db.lck
|
rm /var/lib/pacman/db.lck
|
||||||
pacman --noconfirm -S qt5-styleplugins qt6gtk2
|
pamac build --no-confirm qt5-styleplugins
|
5
bin/standalone/reinstall-for-qt6
Normal file
5
bin/standalone/reinstall-for-qt6
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
#!/bin/bash
|
||||||
|
parent_process=$(ps -p $PPID -o comm=)
|
||||||
|
[ "$parent_process" = 'pacman' ] || [ "$parent_process" = 'pamac-daemon' ] || exit
|
||||||
|
rm /var/lib/pacman/db.lck
|
||||||
|
pamac build --no-confirm qt6gtk2
|
17
tromjaro-fixes.sh
Normal file
17
tromjaro-fixes.sh
Normal file
|
@ -0,0 +1,17 @@
|
||||||
|
# Sync the QT with GTK
|
||||||
|
export QT_QPA_PLATFORMTHEME="gtk2"
|
||||||
|
export QT_QUICK_CONTROLS_STYLE="gtk2"
|
||||||
|
export QT_AUTO_SCREEN_SCALE_FACTOR=1
|
||||||
|
|
||||||
|
# Show color output in less
|
||||||
|
export LESS=-R
|
||||||
|
export LESS_TERMCAP_mb=$'\e[1;31m'
|
||||||
|
export LESS_TERMCAP_md=$'\e[1;36m'
|
||||||
|
export LESS_TERMCAP_me=$'\e[0m'
|
||||||
|
export LESS_TERMCAP_so=$'\e[01;44;33m'
|
||||||
|
export LESS_TERMCAP_se=$'\e[0m'
|
||||||
|
export LESS_TERMCAP_us=$'\e[1;32m'
|
||||||
|
export LESS_TERMCAP_ue=$'\e[0m'
|
||||||
|
|
||||||
|
# Disable the beep sound
|
||||||
|
xset b off
|
Loading…
Reference in New Issue
Block a user