drop custom font
This commit is contained in:
parent
e1039049b8
commit
f92102a2c6
|
@ -1,82 +0,0 @@
|
|||
#!/sbin/sh
|
||||
#
|
||||
# ADDOND_VERSION=2
|
||||
#
|
||||
# /system/addon.d/99-font.sh
|
||||
#
|
||||
|
||||
# we partially use the script at install, if so, $SYSTEM is allready defined
|
||||
if [ -z $SYSTEM ]; then
|
||||
. /tmp/backuptool.functions
|
||||
else
|
||||
S=$SYSTEM
|
||||
fi
|
||||
if [ -z $backuptool_ab ]; then
|
||||
SYS=$S
|
||||
TMP="/tmp"
|
||||
else
|
||||
SYS="/postinstall/$S"
|
||||
TMP="/postinstall/tmp"
|
||||
fi
|
||||
|
||||
# path is needed when running from recovery (at install)
|
||||
export PATH="${PATH}:$S/bin:$S/xbin"
|
||||
|
||||
list_files() {
|
||||
cat <<EOF
|
||||
fonts/IBMPlexSans-Black.ttf
|
||||
fonts/IBMPlexSans-BlackItalic.ttf
|
||||
fonts/IBMPlexSans-Bold.ttf
|
||||
fonts/IBMPlexSans-BoldItalic.ttf
|
||||
fonts/IBMPlexSans-Hairline.ttf
|
||||
fonts/IBMPlexSans-HairlineItalic.ttf
|
||||
fonts/IBMPlexSans-Heavy.ttf
|
||||
fonts/IBMPlexSans-HeavyItalic.ttf
|
||||
fonts/IBMPlexSans-Italic.ttf
|
||||
fonts/IBMPlexSans-Light.ttf
|
||||
fonts/IBMPlexSans-LightItalic.ttf
|
||||
fonts/IBMPlexSans-Medium.ttf
|
||||
fonts/IBMPlexSans-MediumItalic.ttf
|
||||
fonts/IBMPlexSans-Regular.ttf
|
||||
fonts/IBMPlexSans-Semibold.ttf
|
||||
fonts/IBMPlexSans-SemiboldItalic.ttf
|
||||
fonts/IBMPlexSans-Thin.ttf
|
||||
fonts/IBMPlexSans-ThinItalic.ttf
|
||||
EOF
|
||||
}
|
||||
|
||||
case "$1" in
|
||||
backup)
|
||||
list_files | while read FILE DUMMY; do
|
||||
backup_file $S/"$FILE"
|
||||
done
|
||||
;;
|
||||
restore)
|
||||
list_files | while read FILE REPLACEMENT; do
|
||||
R=""
|
||||
[ -n "$REPLACEMENT" ] && R="$S/$REPLACEMENT"
|
||||
[ -f "$C/$S/$FILE" ] && restore_file $S/"$FILE" "$R"
|
||||
done
|
||||
;;
|
||||
pre-backup)
|
||||
# Stub
|
||||
;;
|
||||
post-backup)
|
||||
# Stub
|
||||
;;
|
||||
pre-restore)
|
||||
# Stub
|
||||
;;
|
||||
post-restore)
|
||||
# update fonts.xml
|
||||
cp -p "$SYS/etc/fonts.xml" "$SYS/etc/fonts.xml.bak"
|
||||
sed -i -e "s/Roboto-/IBMPlexSans-/g" \
|
||||
"$SYS/etc/fonts.xml"
|
||||
# Fix ownership/permissions
|
||||
for i in $(list_files); do
|
||||
chown root:root "$SYS/$i"
|
||||
chmod 644 "$SYS/$i"
|
||||
chmod 755 "$(dirname "$SYS/$i")"
|
||||
done
|
||||
;;
|
||||
esac
|
|
@ -1 +0,0 @@
|
|||
db0429c8-b4b1-4467-9896-c04eaba7b86e
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
@ -1,28 +0,0 @@
|
|||
#!/sbin/sh
|
||||
|
||||
set -e
|
||||
|
||||
# $SYSTEM set by the caller
|
||||
|
||||
cd "$(dirname $0)"
|
||||
|
||||
export PATH="${PATH}:${SYSTEM}/bin:${SYSTEM}/xbin"
|
||||
|
||||
# install iptables script
|
||||
echo "Installing font"
|
||||
cp cm-data/IBMPlexSans/IBMPlexSans*.ttf ${SYSTEM}/fonts/
|
||||
chown root:root ${SYSTEM}/fonts/IBMPlexSans*.ttf
|
||||
chmod 750 ${SYSTEM}/fonts/IBMPlexSans*.ttf
|
||||
|
||||
# install restore script
|
||||
echo "Installing restore script"
|
||||
cp cm-data/99-font.sh.addon ${SYSTEM}/addon.d/99-font.sh
|
||||
chown root:root ${SYSTEM}/addon.d/99-font.sh
|
||||
chmod 755 ${SYSTEM}/addon.d/99-font.sh
|
||||
|
||||
# call restore script post to remove bloat
|
||||
export SYSTEM
|
||||
${SYSTEM}/addon.d/99-font.sh post-restore
|
||||
|
||||
echo "Done"
|
||||
|
Loading…
Reference in New Issue