diff --git a/debian.sh b/debian.sh index 2efd808..0bfeea9 100755 --- a/debian.sh +++ b/debian.sh @@ -181,7 +181,15 @@ live-os-restore() { chroot $TARGET /usr/bin/debian.sh bootloader $1 $5 $2 chroot $TARGET /usr/bin/debian.sh btrfs-tweaks chroot $TARGET /usr/bin/debian.sh accounts - userTweaks + read -p 'Would you like to run your UserTweaks? :' -e -i 'y' user_tweaks + + if [[ $user_tweaks = *y* ]]; then + userTweaks + else + echo + echo "Skipping User Tweaks" + fi + chown -R $USER:$USER $TARGET/home/$USER auto_login cd @@ -189,6 +197,10 @@ live-os-restore() { #unmount } +userTweaks() { + echo "Nothing here yet!" +} + os-restore() { partitions rm -rf $TARGET/usr $TARGET/sbin $TARGET/lib32 $TARGET/libx32 $TARGET/lib $TARGET/vmlinuz* $TARGET/initrd* $TARGET/bin $TARGET/var $TARGET/root $TARGET/opt $TARGET/etc $TARGET/run @@ -257,7 +269,6 @@ configure-repository() { chroot $TARGET /usr/bin/bash -c "export DEBIAN_FRONTEND=noninteractive;/usr/bin/apt dist-upgrade -y -t $DEBIAN_RELEASE-backports" chroot $TARGET /usr/bin/bash -c "export DEBIAN_FRONTEND=noninteractive;/usr/bin/apt install -y $TROUBLESOME_PACKAGES" chroot $TARGET /usr/bin/bash -c "export DEBIAN_FRONTEND=noninteractive;/usr/bin/apt auto-remove -y" - echo 'DPkg::Post-Invoke {"/usr/bin/debian.sh snapshot";};' >$TARGET/etc/apt/apt.conf } make-image() { @@ -309,6 +320,20 @@ install() { #unmount } +installPython() { + clear + VERSION="3.10.6" + sudo apt update + sudo apt install -y liblzma-dev libbz2-dev wget build-essential libreadline-dev libncursesw5-dev libssl-dev libsqlite3-dev tk-dev libgdbm-dev libc6-dev libbz2-dev libffi-dev zlib1g-dev + cd /tmp + wget https://www.python.org/ftp/python/$VERSION/Python-$VERSION.tgz + tar xf Python-$VERSION.tgz + cd Python-$VERSION + ./configure --enable-optimizations + make -j12 + make install +} + stableDiffusion() { clear VERSION="3.10.6" @@ -319,8 +344,7 @@ stableDiffusion() { unzip "v$STABLE_VERSION.zip" cd /home/$USER/stable-diffusion-webui-$STABLE_VERSION /usr/local/bin/python3.10 -m venv venv - source venv/bin/activate - bash webui.sh + chown -R root:root /home/$USER/stable-diffusion-webui-$STABLE_VERSION } desktop() {