3 @echo no default target
7 #################### compute emacs tags
8 # list files under git but exclude third-party stuff like bootstrap and jquery
10 @git ls-files | egrep -v 'insert_above/|/bootstrap/|/jquery/'
12 # in general it's right to rely on the contents as reported by git
14 $(MAKE) myfiles | xargs etags
16 # however sometimes we have stuff not yet added, so in this case
18 find . -type f | fgrep -v '/.git/' | xargs etags
20 #################### manage static contents (extract from all the modules into the single all-static location)
22 ./manage.py collectstatic --noinput
27 allst: clean-static static
29 #################### sync : push current code on a (devel) box running myslice
30 SSHURL:=root@$(MYSLICEBOX):/
31 SSHCOMMAND:=ssh root@$(MYSLICEBOX)
34 # the config file should probably not be overridden
35 LOCAL_RSYNC_EXCLUDES := --exclude '*.pyc' --exclude settings.py --exclude devel --exclude DataTables-1.9.4
37 RSYNC_EXCLUDES := --exclude .git --exclude '*~' --exclude TAGS --exclude .DS_Store $(LOCAL_RSYNC_EXCLUDES)
38 # make -n will propagate as rsync -n
39 RSYNC_COND_DRY_RUN := $(if $(findstring n,$(MAKEFLAGS)),--dry-run,)
41 RSYNC := rsync -a -v $(RSYNC_COND_DRY_RUN) $(RSYNC_EXCLUDES)
43 # xxx until we come up with a packaging this is going to be a wild guess
44 #INSTALLED=/usr/share/myslice
45 INSTALLED=/root/myslice
49 @echo "you need to set MYSLICEBOX, like in e.g."
50 @echo " $(MAKE) MYSLICEBOX=debian04.pl.sophia.inria.fr "$@""
53 +$(RSYNC) ./ $(SSHURL)/$(INSTALLED)/
56 # xxx likewise until we run this under apache it's probably hard to restart from here
59 @echo "you need to set MYSLICEBOX, like in e.g."
60 @echo " $(MAKE) MYSLICEBOX=debian04.pl.sophia.inria.fr "$@""
63 @echo "$@" target not yet implemented - for an apache based depl it would read ...; exit; @$(SSHCOMMAND) /etc/init.d/apache2 restart