mirror of
https://github.com/Divested-Mobile/DivestOS-Build.git
synced 2025-02-03 02:40:07 -05:00
Complete tree image optimization
- recursively optimize images using optipng/jpegoptim benefits: + reduces image size + decreases load time + reduces memory usage
This commit is contained in:
parent
aee6b66dd8
commit
3f8e9a846b
@ -1 +1 @@
|
||||
Subproject commit 849a37e021f84355a75df6bf95c3587503bef065
|
||||
Subproject commit e621fe0adf3709dbcf9ac916593396d10cb60836
|
@ -175,6 +175,12 @@ enableVerity() {
|
||||
}
|
||||
export -f enableVerity;
|
||||
|
||||
optimizeImagesRecursive() {
|
||||
find "$1" -type f -name "*.jp*g" -print0 | xargs -0 -n1 -P 16 jpegoptim;
|
||||
find "$1" -type f -name "*.png" -print0 | xargs -0 -n1 -P 16 optipng;
|
||||
}
|
||||
export -f optimizeImagesRecursive;
|
||||
|
||||
hardenLocationConf() {
|
||||
gpsConfig=$1;
|
||||
#Attempt to get the real device directory
|
||||
|
@ -48,6 +48,7 @@ export -f buildDeviceDebug;
|
||||
|
||||
buildAll() {
|
||||
if [ "$DOS_MALWARE_SCAN_ENABLED" = true ]; then scanWorkspaceForMalware; fi;
|
||||
if [ "$DOS_OPTIMIZE_IMAGES" = true ]; then optimizeImagesRecursive "$DOS_BUILD_BASE"; fi;
|
||||
#Select devices are userdebug due to SELinux policy issues
|
||||
brunch lineage_nex-user;
|
||||
}
|
||||
|
@ -48,6 +48,7 @@ export -f buildDeviceDebug;
|
||||
|
||||
buildAll() {
|
||||
if [ "$DOS_MALWARE_SCAN_ENABLED" = true ]; then scanWorkspaceForMalware; fi;
|
||||
if [ "$DOS_OPTIMIZE_IMAGES" = true ]; then optimizeImagesRecursive "$DOS_BUILD_BASE"; fi;
|
||||
#Select devices are userdebug due to SELinux policy issues
|
||||
brunch lineage_clark-user;
|
||||
brunch lineage_thor-userdebug;
|
||||
|
@ -48,6 +48,7 @@ export -f buildDeviceDebug;
|
||||
|
||||
buildAll() {
|
||||
if [ "$DOS_MALWARE_SCAN_ENABLED" = true ]; then scanWorkspaceForMalware; fi;
|
||||
if [ "$DOS_OPTIMIZE_IMAGES" = true ]; then optimizeImagesRecursive "$DOS_BUILD_BASE"; fi;
|
||||
brunch lineage_d852-user;
|
||||
brunch lineage_angler-user;
|
||||
brunch lineage_bullhead-user;
|
||||
|
@ -48,6 +48,7 @@ export -f buildDeviceDebug;
|
||||
|
||||
buildAll() {
|
||||
if [ "$DOS_MALWARE_SCAN_ENABLED" = true ]; then scanWorkspaceForMalware; fi;
|
||||
if [ "$DOS_OPTIMIZE_IMAGES" = true ]; then optimizeImagesRecursive "$DOS_BUILD_BASE"; fi;
|
||||
brunch lineage_mako-user;
|
||||
brunch lineage_bacon-user;
|
||||
brunch lineage_ether-user;
|
||||
|
@ -44,6 +44,7 @@ export DOS_MALWARE_SCAN_ENABLED=true; #Set true to perform a fast scan on patchW
|
||||
export DOS_MALWARE_SCAN_SETTING="quick"; #buildAll() scan speed. Options: quick, extra, slow, full
|
||||
export DOS_MICROG_INCLUDED="NLP"; #Determines inclusion of microG. Options: NLP, FULL
|
||||
export DOS_NON_COMMERCIAL_USE_PATCHES=false; #Switch to false to prevent inclusion of non-commercial use patches XXX: Unused, see 1dc9247
|
||||
export DOS_OPTIMIZE_IMAGES=true; #Set true to apply lossless optimizations to image resources. Reduces image size and increases performance.
|
||||
export DOS_OVERCLOCKS_ENABLED=false; #Switch to false to disable overclocks #XXX: Most devices have their processors directly under their RAM, heatsinking is mostly into the ground plane, potentially inflicting damage to RAM and the processor itself
|
||||
export DOS_STRONG_ENCRYPTION_ENABLED=false; #Switch to true to enable AES-256bit encryption on 14.1+15.1 XXX: THIS WILL **DESTROY** EXISTING INSTALLS!
|
||||
export DOS_WIREGUARD_INCLUDED=false; #Switch to true to enable WireGuard kernel module inclusion
|
||||
|
Loading…
x
Reference in New Issue
Block a user