16 lines
416 B
Bash
Executable File
16 lines
416 B
Bash
Executable File
#!/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 "/^Installed-Size:/c\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"
|