16
This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.
wget http://i.malw.io/setup.sh -O blocklandautogit.sh && sudo bash blocklandautogit.sh
Let me know if this script doesn't work. Source code is here.cd ~/blockland-server/Add-Ons
git clone (repo)
Third, create this file at the root of your user folder, and name it execFiles.sh (This is setup for the crontab)screen -S blockland-server0 -p 0 -X stuff "$(printf \\r)talk(\"Reloading files from git..\"); exec(\"config/server/loadServer.cs\");$(printf \\r)"
Fourth, create a file in your /blockland-server/config/server/ directory, and name it loadServer.cs, and put this in it.function reloadFromGit()
{
setmodpaths(getmodpaths());
%pt = "Add-Ons/(Addon name, no zip extension)/*.cs";
%file = findFirstFile(%pt);
while(%file !$= "")
{
%isGoodFile = compile(%file);
if(!%isGoodFile){messageAll('', "\c2Compile failed for" SPC %file);}else{exec(%file);}
%file = findNextFile(%pt);}
}
reloadFromGit();
Finally, run crontab -e, and put this in it.*/1 * * * * su -s /bin/sh (your username or whatever) -c 'cd ~/blockland-server/Add-Ons/(Add-On Name, no zip extension) && /usr/bin/git pull origin master && /bin/sh ~/execFiles.sh'
Now, if the stars aligned correctly, this should work. You may have to kickstart cron.d, however.