mirror of
https://github.com/end-4/dots-hyprland.git
synced 2026-06-06 07:19:27 -05:00
feat: use uv to manage dependencies (#1060)
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
#!/usr/bin/env python3
|
||||
#!/usr/bin/env -S\_/bin/sh\_-xc\_"source\_\$(eval\_echo\_\$ILLOGICAL_IMPULSE_VIRTUAL_ENV)/bin/activate&&exec\_python\_-E\_"\$0"\_"\$@""
|
||||
import argparse
|
||||
import math
|
||||
import json
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
#!/usr/bin/env python3
|
||||
#!/usr/bin/env -S\_/bin/sh\_-xc\_"source\_\$(eval\_echo\_\$ILLOGICAL_IMPULSE_VIRTUAL_ENV)/bin/activate&&exec\_python\_-E\_"\$0"\_"\$@""
|
||||
import argparse
|
||||
import re
|
||||
import os
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
#!/usr/bin/env python
|
||||
|
||||
#!/usr/bin/env -S\_/bin/sh\_-xc\_"source\_\$(eval\_echo\_\$ILLOGICAL_IMPULSE_VIRTUAL_ENV)/bin/activate&&exec\_python\_-E\_"\$0"\_"\$@""
|
||||
import sys
|
||||
from dataclasses import dataclass
|
||||
from signal import SIGINT, SIGTERM, signal
|
||||
|
||||
@@ -17,5 +17,8 @@ env = QT_QPA_PLATFORMTHEME, qt5ct
|
||||
# ######## Screen tearing #########
|
||||
# env = WLR_DRM_NO_ATOMIC, 1
|
||||
|
||||
# ######## Virtual envrionment #########
|
||||
env = ILLOGICAL_IMPULSE_VIRTUAL_ENV, ~/.local/state/ags/.venv
|
||||
|
||||
# ############ Others #############
|
||||
|
||||
|
||||
@@ -1,13 +0,0 @@
|
||||
pkgname=illogical-impulse-pymyc-aur
|
||||
pkgver=1.0
|
||||
pkgrel=1
|
||||
pkgdesc='Illogical Impulse PyMYC Dependencies'
|
||||
arch=(any)
|
||||
license=(None)
|
||||
depends=(
|
||||
python-materialyoucolor-git
|
||||
gradience
|
||||
python-libsass
|
||||
python-material-color-utilities
|
||||
)
|
||||
|
||||
@@ -1,14 +1,15 @@
|
||||
pkgname=illogical-impulse-python
|
||||
pkgver=1.0
|
||||
pkgver=1.1
|
||||
pkgrel=1
|
||||
pkgdesc='Illogical Impulse Python Dependencies'
|
||||
arch=(any)
|
||||
license=(None)
|
||||
depends=(
|
||||
python-build
|
||||
python-pillow
|
||||
python-pywal
|
||||
python-setuptools-scm
|
||||
python-wheel
|
||||
gtk4
|
||||
libadwaita
|
||||
libsoup3
|
||||
libportal-gtk4
|
||||
blueprint-compiler
|
||||
gobject-introspection
|
||||
sassc
|
||||
)
|
||||
|
||||
|
||||
+22
-12
@@ -116,7 +116,7 @@ install-local-pkgbuild() {
|
||||
}
|
||||
|
||||
# Install core dependencies from the meta-packages
|
||||
metapkgs=(./arch-packages/illogical-impulse-{audio,backlight,basic,fonts-themes,gnome,gtk,portal,python,screencapture,widgets})
|
||||
metapkgs=(./arch-packages/illogical-impulse-{audio,python,backlight,basic,fonts-themes,gnome,gtk,portal,screencapture,widgets})
|
||||
metapkgs+=(./arch-packages/illogical-impulse-ags)
|
||||
metapkgs+=(./arch-packages/illogical-impulse-microtex-git)
|
||||
metapkgs+=(./arch-packages/illogical-impulse-oneui4-icons-git)
|
||||
@@ -130,18 +130,28 @@ for i in "${metapkgs[@]}"; do
|
||||
v install-local-pkgbuild "$i" "$metainstallflags"
|
||||
done
|
||||
|
||||
# https://github.com/end-4/dots-hyprland/issues/428#issuecomment-2081690658
|
||||
# https://github.com/end-4/dots-hyprland/issues/428#issuecomment-2081701482
|
||||
# https://github.com/end-4/dots-hyprland/issues/428#issuecomment-2081707099
|
||||
case $SKIP_PYMYC_AUR in
|
||||
true) sleep 0;;
|
||||
*)
|
||||
pymycinstallflags=""
|
||||
$ask && showfun install-local-pkgbuild || pymycinstallflags="$pymycinstallflags --noconfirm"
|
||||
v install-local-pkgbuild "./arch-packages/illogical-impulse-pymyc-aur" "$pymycinstallflags"
|
||||
;;
|
||||
esac
|
||||
ags_state_dir=~/.local/state/ags
|
||||
|
||||
showfun install-uv
|
||||
v install-uv
|
||||
|
||||
x mkdir -p $ags_state_dir
|
||||
# we need python 3.12 https://github.com/python-pillow/Pillow/issues/8089
|
||||
x uv venv --prompt .venv $PYTHON_VENV_PATH -p 3.12
|
||||
x source $PYTHON_VENV_PATH/bin/activate
|
||||
x uv pip install -r scriptdata/requirements.txt
|
||||
|
||||
# install gradience
|
||||
gradience_dir=/tmp/gradience
|
||||
x git clone https://github.com/ZeyadMoustafaKamal/Gradience.git $gradience_dir
|
||||
x cd $gradience_dir
|
||||
x git submodule update --init --recursive
|
||||
x uv pip install -r requirements.txt
|
||||
x meson setup build --prefix=$VIRTUAL_ENV
|
||||
x meson compile -C build
|
||||
x meson install -C build
|
||||
x cd -
|
||||
x deactivate # We don't need the virtual environment anymore
|
||||
|
||||
# Why need cleanbuild? see https://github.com/end-4/dots-hyprland/issues/389#issuecomment-2040671585
|
||||
# Why install deps by running a seperate command? see pinned comment of https://aur.archlinux.org/packages/hyprland-git
|
||||
|
||||
@@ -3,4 +3,3 @@
|
||||
|
||||
### Most dependencies have been moved to meta packages as declared in arch-packages.
|
||||
### Use this file for declaring extra dependencies which you need but are not declared by default.
|
||||
|
||||
|
||||
@@ -5,4 +5,6 @@ XDG_CONFIG_HOME=${XDG_CONFIG_HOME:-$HOME/.config}
|
||||
XDG_DATA_HOME=${XDG_DATA_HOME:-$HOME/.local/share}
|
||||
XDG_STATE_HOME=${XDG_STATE_HOME:-$HOME/.local/state}
|
||||
BACKUP_DIR=${BACKUP_DIR:-$HOME/backup}
|
||||
|
||||
UV_NO_MODIFY_PATH=1
|
||||
PYTHON_VENV_PATH=$XDG_STATE_HOME/ags/.venv
|
||||
PYTHON_BIN_PATH=$PYTHON_VENV_PATH/bin/python
|
||||
|
||||
@@ -112,3 +112,8 @@ install-MicroTeX (){
|
||||
x sudo cp -r ./res /opt/MicroTeX/
|
||||
x cd $base
|
||||
}
|
||||
|
||||
install-uv (){
|
||||
x curl -LsSf https://astral.sh/uv/install.sh | sh
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
build
|
||||
pillow
|
||||
pywal
|
||||
setuptools-scm
|
||||
wheel
|
||||
pywayland
|
||||
psutil
|
||||
git+https://github.com/T-Dynamos/materialyoucolor-python.git
|
||||
libsass
|
||||
material-color-utilities
|
||||
@@ -0,0 +1,38 @@
|
||||
# This file was autogenerated by uv via the following command:
|
||||
# uv pip compile scriptdata/requirements.in -o scriptdata/requirements.txt
|
||||
build==1.2.2.post1
|
||||
# via -r scriptdata/requirements.in
|
||||
cffi==1.17.1
|
||||
# via pywayland
|
||||
libsass==0.23.0
|
||||
# via -r scriptdata/requirements.in
|
||||
material-color-utilities==0.2.1
|
||||
# via -r scriptdata/requirements.in
|
||||
materialyoucolor @ git+https://github.com/T-Dynamos/materialyoucolor-python.git@73080739dc7c46d378a7624881e9c1e6b20b23f1
|
||||
# via -r scriptdata/requirements.in
|
||||
numpy==2.2.2
|
||||
# via material-color-utilities
|
||||
packaging==24.2
|
||||
# via
|
||||
# build
|
||||
# setuptools-scm
|
||||
pillow==11.1.0
|
||||
# via
|
||||
# -r scriptdata/requirements.in
|
||||
# material-color-utilities
|
||||
psutil==6.1.1
|
||||
# via -r scriptdata/requirements.in
|
||||
pycparser==2.22
|
||||
# via cffi
|
||||
pyproject-hooks==1.2.0
|
||||
# via build
|
||||
pywal==3.3.0
|
||||
# via -r scriptdata/requirements.in
|
||||
pywayland==0.4.18
|
||||
# via -r scriptdata/requirements.in
|
||||
setuptools==75.8.0
|
||||
# via setuptools-scm
|
||||
setuptools-scm==8.1.0
|
||||
# via -r scriptdata/requirements.in
|
||||
wheel==0.45.1
|
||||
# via -r scriptdata/requirements.in
|
||||
Reference in New Issue
Block a user