forked from FreshRSS/Extensions
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
39 lines (35 loc) · 789 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
.DEFAULT_GOAL := help
ifdef NO_DOCKER
PHP = $(shell which php)
else
PHP = docker run \
--interactive \
--tty \
--rm \
--volume $(shell pwd):/usr/src/app:z \
--workdir /usr/src/app \
--name freshrss-extension-php-cli \
freshrss-extension-php-cli \
php
endif
############
## Docker ##
############
.PHONY: build
build: ## Build a Docker image
docker build \
--pull \
--tag freshrss-extension-php-cli \
--file Docker/Dockerfile .
###########
## TOOLS ##
###########
.PHONY: generate
generate: ## Generate the extensions.json file
@$(PHP) ./generate.php
##########
## HELP ##
##########
.PHONY: help
help:
@grep --extended-regexp '^[a-zA-Z0-9_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}'