Guest User

Untitled

a guest
Dec 14th, 2018
66
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.91 KB | None | 0 0
  1. COFFEEC = coffee
  2. SASSC = sass
  3.  
  4.  
  5. # Build app package
  6. COFFEESRC = scripts/main.coffee
  7. COFFEEJS = ${COFFEESRC:.coffee=.js}
  8. APPJS = scripts/app.js
  9.  
  10. $(APPJS): $(COFFEEJS)
  11. cat $^ > $@
  12.  
  13. %.js: %.coffee
  14. $(COFFEEC) -bc $<
  15.  
  16. .PHONY: scripts
  17. scripts: $(APPJS)
  18.  
  19.  
  20. # Build vendor package
  21. VENDORSRC = scripts/vendor/zepto.js \
  22. scripts/vendor/underscore.js \
  23. scripts/vendor/backbone.js \
  24. scripts/vendor/handlebars-1.0.0.beta.6.js
  25. VENDORJS = scripts/vendor.js
  26.  
  27. $(VENDORJS): $(VENDORSRC)
  28. cat $^ > $@
  29.  
  30. .PHONY: vendor
  31. vendor: $(VENDORJS)
  32.  
  33.  
  34. # Build stylesheets
  35. STYLESRC = styles/main.sass \
  36. styles/mixins.sass \
  37. styles/reset.sass
  38. STYLEOBJ = ${STYLESRC:.sass=.css}
  39. STYLEOUT = styles/app.css
  40.  
  41. $(STYLEOUT): $(STYLEOBJ)
  42. cp $< $@
  43.  
  44. %.css: %.sass
  45. $(SASSC) -C $< > $@
  46.  
  47. .PHONY: styles
  48. styles: $(STYLEOUT)
  49.  
  50.  
  51. .PHONY: all
  52. all: scripts vendor styles
  53.  
  54. .PHONY: clean
  55. clean:
  56. -rm $(COFFEEJS)
  57. -rm $(APPJS)
  58. -rm $(VENDORJS)
  59. -rm $(STYLEOBJ)
  60. -rm $(STYLEOUT)
Add Comment
Please, Sign In to add comment