Rename musala-push to musala
This commit is contained in:
parent
69dd1308ad
commit
d337f57adc
6 changed files with 25 additions and 21 deletions
16
Makefile
16
Makefile
|
@ -1,20 +1,20 @@
|
||||||
|
|
||||||
GOFILES=$(wildcard *.go)
|
GOFILES=$(wildcard *.go)
|
||||||
NAME=musala-push
|
BINDIR=bin
|
||||||
|
NAME=musala
|
||||||
MJML_TEMPLATES=$(wildcard templates/*.mjml)
|
MJML_TEMPLATES=$(wildcard templates/*.mjml)
|
||||||
MJML_OUTPUT=$(patsubst %.mjml,%.mjml.html,$(MJML_TEMPLATES))
|
MJML_OUTPUT=$(patsubst %.mjml,%.mjml.html,$(MJML_TEMPLATES))
|
||||||
|
|
||||||
all: build
|
all: help
|
||||||
|
|
||||||
%.mjml.html: %.mjml
|
%.mjml.html: %.mjml
|
||||||
npx mjml $< --config.minify > $@
|
npx mjml $< --config.minify > $@
|
||||||
|
|
||||||
|
|
||||||
.PHONY: build build-binaries build-templates
|
.PHONY: build build-binaries build-templates
|
||||||
build: build-binaries build-templates ## build executable
|
build: build-binaries build-templates ## build executable
|
||||||
|
|
||||||
build-binaries: build-templates
|
build-binaries: build-templates
|
||||||
go build ./...
|
cd $(BINDIR) && go build ../...
|
||||||
|
|
||||||
build-templates: $(MJML_OUTPUT)
|
build-templates: $(MJML_OUTPUT)
|
||||||
|
|
||||||
|
@ -27,7 +27,11 @@ shellcheck: ## run shellcheck validation
|
||||||
|
|
||||||
.PHONY: help
|
.PHONY: help
|
||||||
help: ## print this help
|
help: ## print this help
|
||||||
@awk 'BEGIN {FS = ":.*?## "} /^[a-zA-Z_-]+:.*?## / {sub("\\\\n",sprintf("\n%22c"," "), $$2);printf "\033[36m%-20s\033[0m %s\n", $$1, $$2}' $(MAKEFILE_LIST)
|
@awk 'BEGIN {FS = ":.*?## "} \
|
||||||
|
/^[a-zA-Z_-]+:.*?## / \
|
||||||
|
{sub("\\\\n",sprintf("\n%22c"," "), \
|
||||||
|
$$2);printf "\033[36m%-20s\033[0m %s\n", $$1, $$2}' \
|
||||||
|
$(MAKEFILE_LIST)
|
||||||
|
|
||||||
.PHONY: clean clean-templates clean-binaries
|
.PHONY: clean clean-templates clean-binaries
|
||||||
clean: clean-templates clean-binaries ## remove build artifacts
|
clean: clean-templates clean-binaries ## remove build artifacts
|
||||||
|
@ -36,7 +40,7 @@ clean-templates:
|
||||||
rm -f ./templates/*.mjml.html
|
rm -f ./templates/*.mjml.html
|
||||||
|
|
||||||
clean-binaries:
|
clean-binaries:
|
||||||
rm -rf ./_build/*
|
rm -rf $(BINDIR)/*
|
||||||
|
|
||||||
test: build
|
test: build
|
||||||
./test.sh
|
./test.sh
|
||||||
|
|
20
README.md
20
README.md
|
@ -1,8 +1,8 @@
|
||||||
# <img src="doc/logo-title-paths.svg" width="50%" style="display: block; margin: 0 auto;" alt="Musala" />
|
# <img src="doc/logo-title-paths.svg" width="50%" style="display: block; margin: 0 auto;" alt="Musala" />
|
||||||
|
|
||||||
![Build](https://github.com/glenux/musala-push/workflows/build/badge.svg?branch=master)
|
![Build](https://github.com/glenux/musala/workflows/build/badge.svg?branch=master)
|
||||||
<!-- [![Gem Version](https://badge.fury.io/rb/musala-push.svg)](https://rubygems.org/gems/musala-push) -->
|
<!-- [![Gem Version](https://badge.fury.io/rb/musala.svg)](https://rubygems.org/gems/musala) -->
|
||||||
[![GitHub license](https://img.shields.io/github/license/glenux/musala-push.svg)](https://github.com/glenux/musala-push/blob/master/LICENSE.txt)
|
[![GitHub license](https://img.shields.io/github/license/glenux/musala.svg)](https://github.com/glenux/musala/blob/master/LICENSE.txt)
|
||||||
[![Donate on patreon](https://img.shields.io/badge/patreon-donate-orange.svg)](https://patreon.com/glenux)
|
[![Donate on patreon](https://img.shields.io/badge/patreon-donate-orange.svg)](https://patreon.com/glenux)
|
||||||
|
|
||||||
Every morning, get the content of your favorite kanban board by email, WhatsApp or SMS.
|
Every morning, get the content of your favorite kanban board by email, WhatsApp or SMS.
|
||||||
|
@ -39,7 +39,7 @@ Delivery via:
|
||||||
|
|
||||||
Make sure you have Go installed, then type:
|
Make sure you have Go installed, then type:
|
||||||
|
|
||||||
$ go install github.com/glenux/musala-push/...
|
$ go install github.com/glenux/musala/...
|
||||||
|
|
||||||
It will install Musala Mail binary in `$GOPATH/bin`
|
It will install Musala Mail binary in `$GOPATH/bin`
|
||||||
|
|
||||||
|
@ -48,7 +48,7 @@ It will install Musala Mail binary in `$GOPATH/bin`
|
||||||
|
|
||||||
Make sure you have Docker installed, then type:
|
Make sure you have Docker installed, then type:
|
||||||
|
|
||||||
$ docker build -t musala-push -f docker/Dockerfile .
|
$ docker build -t musala -f docker/Dockerfile .
|
||||||
|
|
||||||
## Usage
|
## Usage
|
||||||
|
|
||||||
|
@ -90,11 +90,11 @@ SMTP_SECURITY_TYPE: tls
|
||||||
|
|
||||||
Then run the program:
|
Then run the program:
|
||||||
|
|
||||||
$ $GOPATH/bin/musala-push
|
$ $GOPATH/bin/musala
|
||||||
|
|
||||||
### Using with docker
|
### Using with docker
|
||||||
|
|
||||||
$ docker build -f docker/Dockerfile -t musala-push .
|
$ docker build -f docker/Dockerfile -t musala .
|
||||||
$ docker run \
|
$ docker run \
|
||||||
-e EMAIL_FROM=
|
-e EMAIL_FROM=
|
||||||
-e EMAIL_TO=
|
-e EMAIL_TO=
|
||||||
|
@ -102,12 +102,12 @@ Then run the program:
|
||||||
-e EMAIL_FROM=
|
-e EMAIL_FROM=
|
||||||
-e EMAIL_TO=
|
-e EMAIL_TO=
|
||||||
-e EMAIL_SUBJECT=
|
-e EMAIL_SUBJECT=
|
||||||
-v /var/lib/musala-push/musala-push.cron:/app/musala-push.cron \
|
-v /var/lib/musala/musala.cron:/app/musala.cron \
|
||||||
-it musala-push:latest
|
-it musala:latest
|
||||||
|
|
||||||
## Contributing
|
## Contributing
|
||||||
|
|
||||||
1. Fork it ( http://github.com/glenux/musala-push/fork )
|
1. Fork it ( http://github.com/glenux/musala/fork )
|
||||||
2. Create your feature branch (`git checkout -b my-new-feature`)
|
2. Create your feature branch (`git checkout -b my-new-feature`)
|
||||||
3. Commit your changes (`git commit -am 'Add some feature'`)
|
3. Commit your changes (`git commit -am 'Add some feature'`)
|
||||||
4. Push to the branch (`git push origin my-new-feature`)
|
4. Push to the branch (`git push origin my-new-feature`)
|
||||||
|
|
|
@ -11,7 +11,7 @@ import (
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
programBinary string = "musala-push"
|
programBinary string = "musala"
|
||||||
)
|
)
|
||||||
|
|
||||||
var (
|
var (
|
|
@ -6,7 +6,7 @@ FROM golang:1.12 AS build
|
||||||
RUN git clone \
|
RUN git clone \
|
||||||
--single-branch \
|
--single-branch \
|
||||||
--branch develop \
|
--branch develop \
|
||||||
https://github.com/glenux/musala-push \
|
https://github.com/glenux/musala \
|
||||||
/app \
|
/app \
|
||||||
&& rm -f /app/contrib-trello \
|
&& rm -f /app/contrib-trello \
|
||||||
&& git clone \
|
&& git clone \
|
||||||
|
@ -30,9 +30,9 @@ RUN apk update \
|
||||||
&& rm -rf /var/cache/apk/*
|
&& rm -rf /var/cache/apk/*
|
||||||
|
|
||||||
RUN mkdir /app
|
RUN mkdir /app
|
||||||
COPY --from=build /app/musala-push /app/
|
COPY --from=build /app/musala /app/
|
||||||
COPY docker/musala-push.cron /app/
|
COPY docker/musala.cron /app/
|
||||||
COPY templates/ /app/templates
|
COPY templates/ /app/templates
|
||||||
|
|
||||||
CMD ["/bin/sh", "-c", "/usr/bin/crontab /app/musala-push.cron && /usr/sbin/crond -f"]
|
CMD ["/bin/sh", "-c", "/usr/bin/crontab /app/musala.cron && /usr/sbin/crond -f"]
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue