Skip to content

Instantly share code, notes, and snippets.

View akaguny's full-sized avatar
🏠
Working from home

Alexey akaguny

🏠
Working from home
View GitHub Profile
@akaguny
akaguny / xampp.sh
Last active February 7, 2021 05:10 — forked from dflynn15/xampp.sh
Linux bash script to write to XAMPP vhost and add symbolic link.
#!/bin/bash
# Format of command: ./xampp.sh new.website.name.com
# arguments: name=virtual adress site
# edited files by script: /opt/lampp/etc/extra/httpd-vhosts.conf, /etc/hosts
XAMPP_DIR="/opt/lampp" # Youre installation folder
PROJECTS_DIR="/home/alexey/webprojects" # Youre projects folder
#todo: change /home/alexey to variable $HOME, but if run script whit sudo $home = root
PROJECT_DIR="$PROJECTS_DIR/$1"
# Number of expected arguments