A community web log for monkey niches.

Makefile 388B

123456789101112131415161718
  1. all: version.py
  2. version.py: dummy
  3. echo __version__ = \'$(shell git describe --always --dirty --long)\' > $@
  4. dummy:
  5. DB=$(shell cat niche.ini | grep ^db= | cut -d= -f2)
  6. import: $(wildcard mofi-*.sql.gz)
  7. zcat $< \
  8. | sed -r "s# CHARSET\=latin1# CHARSET\=utf8#g" \
  9. | sed "s#ENGINE=MyISAM##" \
  10. | mysql -u root -p $(DB)
  11. update: $(wildcard update*.sql)
  12. cat $^ | mysql -u root -p $(DB)