2015-12-02 18:21:44 -05:00
|
|
|
|
2015-12-04 02:31:39 -05:00
|
|
|
BIO_DIR := ~/Documents/Administrivia/Bios
|
|
|
|
|
2015-12-02 18:21:44 -05:00
|
|
|
all:
|
|
|
|
node build.js
|
|
|
|
|
2015-12-04 02:31:39 -05:00
|
|
|
fetch:
|
2015-12-16 12:39:48 -05:00
|
|
|
@echo Retrieving Website Repo Head
|
2015-12-15 11:11:06 -05:00
|
|
|
@git pull
|
2015-12-04 02:31:39 -05:00
|
|
|
@if [ -f $(BIO_DIR)/Rakefile ] ; then \
|
2015-12-08 08:58:28 -05:00
|
|
|
echo "Fetching Updates"; \
|
2015-12-11 08:28:08 -05:00
|
|
|
/bin/bash -c "cd $(BIO_DIR); pwd; git pull;"\
|
2015-12-04 02:31:39 -05:00
|
|
|
echo "Building JSON"; \
|
|
|
|
rake -f $(BIO_DIR)/Rakefile -E "Dir.chdir(File.expand_path '$(BIO_DIR)')" okennedy.json;\
|
|
|
|
cp $(BIO_DIR)/okennedy.json src/metadata/;\
|
|
|
|
else\
|
|
|
|
echo "Fetching JSON";\
|
|
|
|
cd src/metadata;\
|
|
|
|
curl -O http://www.cse.buffalo.edu/~okennedy/okennedy.json;\
|
|
|
|
fi
|
|
|
|
|
2015-12-04 22:42:41 -05:00
|
|
|
push: fetch all
|
2016-01-08 11:02:58 -05:00
|
|
|
@echo "Cleaning up OSX Crap"
|
2015-12-04 12:10:33 -05:00
|
|
|
find . -name .DS_Store | xargs rm
|
2016-01-08 11:02:58 -05:00
|
|
|
@echo "Making sure that you've pushed the repo"
|
2016-01-08 11:04:43 -05:00
|
|
|
git add .; git commit; git push
|
2016-01-08 11:02:58 -05:00
|
|
|
@echo "Actually uploading the site"
|
2016-01-15 12:29:14 -05:00
|
|
|
rsync -avz -e ssh --safe-links --progress site/ okennedy@gram.cse.buffalo.edu:/var/www/static/
|
2016-01-26 14:46:06 -05:00
|
|
|
rsync -avz -e ssh --safe-links --progress static/ okennedy@gram.cse.buffalo.edu:/var/www/static/
|
2015-12-04 02:31:39 -05:00
|
|
|
|
2016-01-08 10:42:12 -05:00
|
|
|
open: all
|
|
|
|
open site/index.html
|
2015-12-02 18:21:44 -05:00
|
|
|
|
2016-01-08 10:42:12 -05:00
|
|
|
.PHONY: all fetch push open
|