Get image file extension

This commit is contained in:
Bob Mottram 2016-10-27 19:23:11 +01:00
parent fc2d6ad5d8
commit 24ae7aecbd
1 changed files with 5 additions and 0 deletions

View File

@ -954,6 +954,11 @@ function install_gnusocial_theme {
exit 356723 exit 356723
fi fi
if [ $GNUSOCIAL_BACKGROUND_IMAGE_URL ]; then
filename=$(basename "$GNUSOCIAL_BACKGROUND_IMAGE_URL")
GNUSOCIAL_BACKGROUND_IMAGE_URL_EXT="${filename##*.}"
fi
gnusocial_config_file=/var/www/$GNUSOCIAL_DOMAIN_NAME/htdocs/config.php gnusocial_config_file=/var/www/$GNUSOCIAL_DOMAIN_NAME/htdocs/config.php
if ! grep -q "addPlugin('Qvitter')" $gnusocial_config_file; then if ! grep -q "addPlugin('Qvitter')" $gnusocial_config_file; then
GNUSOCIAL_WELCOME_MESSAGE=$(echo $GNUSOCIAL_WELCOME_MESSAGE | sed "s|\$GNUSOCIAL_DOMAIN_NAME|$GNUSOCIAL_DOMAIN_NAME|g") GNUSOCIAL_WELCOME_MESSAGE=$(echo $GNUSOCIAL_WELCOME_MESSAGE | sed "s|\$GNUSOCIAL_DOMAIN_NAME|$GNUSOCIAL_DOMAIN_NAME|g")