Skip to content

Commit

Permalink
Fix #57829 : Implement the ability to add fonts without reinstall (#108)
Browse files Browse the repository at this point in the history
  • Loading branch information
romandemidov authored Jul 11, 2022
1 parent 603baa1 commit 2e1d938
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
9 changes: 9 additions & 0 deletions bin/documentserver-start.sh
Original file line number Diff line number Diff line change
Expand Up @@ -53,4 +53,13 @@ fi

export LC_ALL=C.UTF-8

#check fonts
FONTS_HASH_FILE=$SNAP_DATA/fonts-hash.md5
FONTS_HASH_NEW=$(find /usr/share/fonts | md5sum | cut -f 1 -d ' ')
FONTS_HASH_OLD=$(cat $FONTS_HASH_FILE)
if [ "${FONTS_HASH_NEW}" != "${FONTS_HASH_OLD}" ]; then
echo "${FONTS_HASH_NEW}" > $FONTS_HASH_FILE
$SNAP/usr/sbin/generate-all-fonts.sh
fi

$SNAP/usr/bin/python $SNAP/usr/bin/supervisord -n -c $SNAP_DATA/etc/supervisor/supervisord.conf
4 changes: 4 additions & 0 deletions snap/snapcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,10 @@ apps:
command: mysqldump --defaults-file=$SNAP_DATA/mysql/root.ini --lock-tables onlyoffice
plugs: [network, network-bind]

generate-all-fonts:
command: usr/sbin/generate-all-fonts.sh
plugs: [desktop, unity7]

hooks:
configure:
plugs: [network, network-bind, account-control, gpg-keys, accounts-service, system-observe] #system-files,
Expand Down

0 comments on commit 2e1d938

Please sign in to comment.