Skip to content
Snippets Groups Projects
Commit c5648289 authored by Imran Hussain's avatar Imran Hussain
Browse files

Update setup.sh to check if the script is int eh right place in a better way

parent d9387cf9
No related branches found
No related tags found
No related merge requests found
......@@ -3,11 +3,7 @@
# Setup script for SUCS website in users' public_html dirs
echo "SUCS website setup script"
# (try and) make sure we're running this from the right place
# SUCS website
# ^ a nasty kludge cause I don't know how to do it more sensibly
# test for the magic phrase on line 7 of this very file
head -n 7 setup.sh 2> /dev/null | tail -n 1 | grep -q "SUCS website"
ls $(pwd)/setup.sh &> /dev/null
if [ $? -ne 0 ]; then echo "Please run this script from its containing directory"; exit; fi
# generate correct .htaccess
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment