Skip to content

Commit

Permalink
previewgenerator - allow to clear all previews (#1985)
Browse files Browse the repository at this point in the history
  • Loading branch information
szaimen authored May 22, 2021
1 parent ed1bd40 commit b5bc04f
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions apps/previewgenerator.sh
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,17 @@ else
apt purge ffmpeg -y
fi
apt autoremove -y
if yesno_box_no "Do you want to remove all previews that were generated until now?
This will most likely clear a lot of space but your server will need to re-generate the previews \
if you should opt to re-enable previews again."
then
print_text_in_color "$ICyan" "Removing the preview folder. This can take a while..."
rm -r "$NCDATA"/appdata_*/preview
print_text_in_color "$ICyan" "Scanning Nextclouds appdata directory after removing all previews. \
This can take a while..."
nextcloud_occ files:scan-app-data -vvv
msg_box "All previews were successfully removed."
fi
# Show successful uninstall if applicable
removal_popup "$SCRIPT_NAME"
fi
Expand Down

0 comments on commit b5bc04f

Please sign in to comment.