diff --git a/Makefile b/Makefile index 69fba48..2494aa0 100644 --- a/Makefile +++ b/Makefile @@ -16,35 +16,53 @@ LDFLAGS := Q := @ -all: public/main.js public/style.css +all: kanband main.js style.css @: -public/main.js: public/main.bundle.js public - @echo '[01;31m MIN > [01;37mpublic/main.js[00m' - $(Q)npx babel --minified public/main.bundle.js -o public/main.js +kanband: src/main.cr + @echo '[01;35m CR > [01;37mkanband[00m' + $(Q)crystal src/main.cr -o 'kanband' -public/main.bundle.js: client/index.ls public - @echo '[01;32m BUN > [01;37mpublic/main.bundle.js[00m' - $(Q)npx browserify -t browserify-livescript client/index.ls -o public/main.bundle.js +kanband.install: kanband + @echo '[01;31m IN > [01;37m$(BINDIR)/kanband[00m' + $(Q)mkdir -p '$(DESTDIR)$(BINDIR)' + $(Q)install -m0755 kanband $(DESTDIR)$(BINDIR)/kanband + +kanband.clean: + @echo '[01;37m RM > [01;37mkanband[00m' + $(Q)rm -f kanband + +kanband.uninstall: + @echo '[01;37m RM > [01;37m$(BINDIR)/kanband[00m' + $(Q)rm -f '$(DESTDIR)$(BINDIR)/kanband' + +main.js: main.bundle.js + @echo '[01;31m MIN > [01;37mmain.js[00m' + $(Q)npx babel --minified main.bundle.js -o main.js -public/main.js.clean: - @echo '[01;37m RM > [01;37mpublic/main.js[00m' - $(Q)rm -f public/main.js - @echo '[01;37m RM > [01;37mpublic/main.bundle.js[00m' - $(Q)rm -f public/main.bundle.js +main.bundle.js: client/index.ls client/bulma.ls + @echo '[01;32m BUN > [01;37mmain.bundle.js[00m' + $(Q)npx browserify -t browserify-livescript client/index.ls -o main.bundle.js -public/style.css: client/style.sass public - @echo '[01;33m CSS > [01;37mpublic/style.css[00m' - $(Q)sassc client/style.sass > public/style.css +main.js.clean: + @echo '[01;37m RM > [01;37mmain.js[00m' + $(Q)rm -f main.js + @echo '[01;37m RM > [01;37mmain.bundle.js[00m' + $(Q)rm -f main.bundle.js -public/style.css.clean: +style.css: client/style.sass + @echo '[01;33m CSS > [01;37mstyle.css[00m' + $(Q)sassc client/style.sass > style.css + + +style.css.clean: + @echo '[01;37m RM > [01;37mstyle.css[00m' + $(Q)rm -f style.css -public: - $(Q)mkdir -p public $(DESTDIR)$(PREFIX): @echo '[01;35m DIR > [01;37m$(PREFIX)[00m' $(Q)mkdir -p $(DESTDIR)$(PREFIX) @@ -63,12 +81,12 @@ $(DESTDIR)$(INCLUDEDIR): $(DESTDIR)$(MANDIR): @echo '[01;35m DIR > [01;37m$(MANDIR)[00m' $(Q)mkdir -p $(DESTDIR)$(MANDIR) -install: subdirs.install public/main.js.install public/style.css.install +install: subdirs.install kanband.install main.js.install style.css.install @: subdirs.install: -uninstall: subdirs.uninstall public/main.js.uninstall public/style.css.uninstall +uninstall: subdirs.uninstall kanband.uninstall main.js.uninstall style.css.uninstall @: subdirs.uninstall: @@ -78,7 +96,7 @@ test: all subdirs subdirs.test subdirs.test: -clean: public/main.js.clean public/style.css.clean +clean: kanband.clean main.js.clean style.css.clean distclean: clean @@ -93,22 +111,28 @@ dist-gz: $(PACKAGE)-$(VERSION).tar.gz $(PACKAGE)-$(VERSION).tar.gz: distdir @echo '[01;33m TAR > [01;37m$(PACKAGE)-$(VERSION).tar.gz[00m' $(Q)tar czf $(PACKAGE)-$(VERSION).tar.gz \ + $(PACKAGE)-$(VERSION)/src/main.cr \ $(PACKAGE)-$(VERSION)/client/index.ls \ - $(PACKAGE)-$(VERSION)/client/style.sass + $(PACKAGE)-$(VERSION)/client/style.sass \ + $(PACKAGE)-$(VERSION)/client/bulma.ls dist-xz: $(PACKAGE)-$(VERSION).tar.xz $(PACKAGE)-$(VERSION).tar.xz: distdir @echo '[01;33m TAR > [01;37m$(PACKAGE)-$(VERSION).tar.xz[00m' $(Q)tar cJf $(PACKAGE)-$(VERSION).tar.xz \ + $(PACKAGE)-$(VERSION)/src/main.cr \ $(PACKAGE)-$(VERSION)/client/index.ls \ - $(PACKAGE)-$(VERSION)/client/style.sass + $(PACKAGE)-$(VERSION)/client/style.sass \ + $(PACKAGE)-$(VERSION)/client/bulma.ls dist-bz2: $(PACKAGE)-$(VERSION).tar.bz2 $(PACKAGE)-$(VERSION).tar.bz2: distdir @echo '[01;33m TAR > [01;37m$(PACKAGE)-$(VERSION).tar.bz2[00m' $(Q)tar cjf $(PACKAGE)-$(VERSION).tar.bz2 \ + $(PACKAGE)-$(VERSION)/src/main.cr \ $(PACKAGE)-$(VERSION)/client/index.ls \ - $(PACKAGE)-$(VERSION)/client/style.sass + $(PACKAGE)-$(VERSION)/client/style.sass \ + $(PACKAGE)-$(VERSION)/client/bulma.ls help: @echo '[01;37m :: kanban-0.1[00m' @@ -134,8 +158,9 @@ help: @echo ' - [01;34mMANDIR [37m ${MANDIR}[00m' @echo '' @echo '[01;37mProject targets: [00m' - @echo ' - [01;33mpublic/main.js[37m livescript[00m' - @echo ' - [01;33mpublic/style.css[37m css[00m' + @echo ' - [01;33mkanband [37m crystal[00m' + @echo ' - [01;33mmain.js [37m livescript[00m' + @echo ' - [01;33mstyle.css [37m css[00m' @echo '' @echo '[01;37mMakefile options:[00m' @echo ' - gnu: false' diff --git a/index.html b/index.html index 779c98b..237f9ee 100644 --- a/index.html +++ b/index.html @@ -4,9 +4,9 @@