This commit is contained in:
2025-03-25 14:03:19 -07:00
commit 5433d237e9
6 changed files with 152 additions and 0 deletions

15
build.sh Executable file
View File

@@ -0,0 +1,15 @@
#!/bin/bash
# Path to the package root directory
PKG_DIR="./chillcraftos-default-settings"
# Calculate installed size in KB
PKG_SIZE=$(du -sk "$PKG_DIR" | cut -f1)
# Update control file
sed -i "s/Installed-Size: INSTSIZE/Installed-Size: $PKG_SIZE/" "$PKG_DIR/DEBIAN/control"
# Build the .deb package
dpkg-deb --build "$PKG_DIR" ../chillcraftos-default-settings.deb
echo "Package built with Installed-Size: $PKG_SIZE KB"

View File

@@ -0,0 +1,12 @@
Package: chillcraftos-default-settings
Version: 1.0
Maintainer: Seth Olivarez <contact@oxmc.me>
Section: metapackages
Priority: required
Architecture: all
Depends: base-files (>= 10)
Replaces: base-files (>= 10)
Breaks: base-files (<< 10)
Installed-Size: 212
Description: Default settings for ChillcraftOS
This package contains the default settings and files for ChillcraftOS.

View File

@@ -0,0 +1,57 @@
#!/bin/bash
set -e
# List of system identity files to divert
identity_files=(
"/etc/os-release"
"/etc/issue"
"/etc/issue.net"
)
echo "Diverting and replacing system identity files..."
for file in "${identity_files[@]}"; do
if [ -f "$file" ]; then
dpkg-divert --add --rename --divert "${file}.diverted" "$file"
ln -sf "/etc/chillcraft/$(basename "$file")" "$file"
fi
done
# Set the Vendor-recommended default mirror using apt-manage
#echo "Setting the Vendor-recommended default mirror..."
#apt-manage modify system --default-mirror "http://cdn.oxmc.me/apt"
# Ensure custom logo exists
cp /etc/chillcraft/chillcraft.png /usr/share/pixmaps/chillcraft.png
# List of Debian branding images to divert
branding_files=(
"/usr/share/plymouth/themes/debian-logo.png"
"/usr/share/pixmaps/debian-logo.png"
"/usr/share/icons/hicolor/256x256/apps/debian-logo.png"
"/usr/share/icons/hicolor/128x128/apps/debian-logo.png"
"/usr/share/icons/hicolor/64x64/apps/debian-logo.png"
"/usr/share/icons/hicolor/48x48/apps/debian-logo.png"
"/usr/share/icons/hicolor/32x32/apps/debian-logo.png"
"/usr/share/icons/hicolor/16x16/apps/debian-logo.png"
"/usr/share/desktop-base/active-theme/grub/grub-background.png"
)
echo "Diverting and replacing Debian branding images..."
for file in "${branding_files[@]}"; do
if [ -f "$file" ]; then
dpkg-divert --add --rename --divert "${file}.diverted" "$file"
ln -sf /usr/share/pixmaps/chillcraft.png "$file"
fi
done
# Update the initramfs
echo "Updating initramfs..."
update-initramfs -u || true
# Update the icon cache
echo "Updating icon cache..."
gtk-update-icon-cache /usr/share/icons/hicolor/
exit 0

View File

@@ -0,0 +1,58 @@
#!/bin/bash
set -e
# List of system identity files to restore
identity_files=(
"/etc/os-release"
"/etc/issue"
"/etc/issue.net"
)
echo "Restoring system identity files..."
for file in "${identity_files[@]}"; do
if [ -f "${file}.diverted" ]; then
mv "${file}.diverted" "$file"
dpkg-divert --rename --remove "$file"
fi
done
# Remove the custom mirror configuration
#echo "Removing Vendor-recommended mirror..."
#apt-manage modify system --default-mirror ""
# Remove the custom logo
echo "Removing custom logo..."
rm -f /usr/share/pixmaps/chillcraft.png
# List of Debian branding images to restore
branding_files=(
"/usr/share/plymouth/themes/debian-logo.png"
"/usr/share/pixmaps/debian-logo.png"
"/usr/share/icons/hicolor/256x256/apps/debian-logo.png"
"/usr/share/icons/hicolor/128x128/apps/debian-logo.png"
"/usr/share/icons/hicolor/64x64/apps/debian-logo.png"
"/usr/share/icons/hicolor/48x48/apps/debian-logo.png"
"/usr/share/icons/hicolor/32x32/apps/debian-logo.png"
"/usr/share/icons/hicolor/16x16/apps/debian-logo.png"
"/usr/share/desktop-base/active-theme/grub/grub-background.png"
)
echo "Restoring Debian branding images..."
for file in "${branding_files[@]}"; do
if [ -f "${file}.diverted" ]; then
mv "${file}.diverted" "$file"
dpkg-divert --rename --remove "$file"
fi
done
# Update the initramfs
echo "Updating initramfs..."
update-initramfs -u || true
# Update the icon cache
echo "Updating icon cache..."
gtk-update-icon-cache /usr/share/icons/hicolor/
exit 0

Binary file not shown.

After

Width:  |  Height:  |  Size: 183 KiB

View File

@@ -0,0 +1,10 @@
PRETTY_NAME="ChillcraftOS (bonfire)"
NAME="Debian GNU/Linux"
VERSION_ID="16.4"
VERSION="12 (bookworm)"
VERSION_CODENAME=bookworm
ID=debian
ID_LIKE="debian"
HOME_URL="https://www.debian.org/"
SUPPORT_URL="https://www.debian.org/support"
BUG_REPORT_URL="https://bugs.debian.org/"