On the server, create a separate directory for ngrams:
mkdir -p "/home/$USER/ngrams"
cd "/home/$USER/ngrams"
Download and extract ngrams:
#!/bin/bash | |
# This program is free software; you can redistribute it and/or modify | |
# it under the terms of the GNU General Public License as published by | |
# the Free Software Foundation; either version 2 of the License, or | |
# (at your option) any later version. | |
# | |
# This program is distributed in the hope that it will be useful, | |
# but WITHOUT ANY WARRANTY; without even the implied warranty of | |
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
#!/usr/bin/env bash | |
# This program is free software; you can redistribute it and/or modify | |
# it under the terms of the GNU General Public License as published by | |
# the Free Software Foundation; either version 2 of the License, or | |
# (at your option) any later version. | |
# | |
# This program is distributed in the hope that it will be useful, | |
# but WITHOUT ANY WARRANTY; without even the implied warranty of | |
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
#!/usr/bin/env bash | |
echo "-----------------------------------------" | |
echo " Enter a domain name (example: hello.xyz)" | |
echo " Press ENTER" | |
echo "-----------------------------------------" | |
echo | |
read domain_name | |
touch /etc/apache2/sites-available/$domain_name.conf |
#!/usr/bin/env bash | |
if [ "$(whoami)" != "root" ]; then | |
echo "You must run this script as root" | |
exit 1 | |
fi | |
apt update | |
apt upgrade | |
apt install apache2 php libapache2-mod-php php-gd \ |