forked from klaviyo/magento2-klaviyo
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmakefile
More file actions
22 lines (19 loc) · 777 Bytes
/
makefile
File metadata and controls
22 lines (19 loc) · 777 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
# Adapted from https://stackoverflow.com/a/14061796
# If the first argument is "composer"...
ifeq (composer,$(firstword $(MAKECMDGOALS)))
# use the rest as arguments for "composer"
COMPOSER_ARGS := $(wordlist 2,$(words $(MAKECMDGOALS)),$(MAKECMDGOALS))
# ...and turn them into do-nothing targets
$(eval $(COMPOSER_ARGS):;@:)
endif
composer:
COMPOSER=composer.json composer $(COMPOSER_ARGS)
# If the first argument is "composer-dev"...
ifeq (composer-dev,$(firstword $(MAKECMDGOALS)))
# use the rest as arguments for "composer"
COMPOSER_DEV_ARGS := $(wordlist 2,$(words $(MAKECMDGOALS)),$(MAKECMDGOALS))
# ...and turn them into do-nothing targets
$(eval $(COMPOSER_DEC_ARGS):;@:)
endif
composer-dev:
COMPOSER=composer.dev.json composer $(COMPOSER_DEV_ARGS)