forked from littleredbutton/cloud_bbb
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
73 lines (52 loc) · 1.46 KB
/
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
# This file is licensed under the Affero General Public License version 3 or
# later. See the COPYING file.
app_name=$(notdir $(CURDIR))
build_tools_directory=$(CURDIR)/build/tools
composer=$(shell which composer 2> /dev/null)
all: dev-setup lint build-js-production test
build: install-composer-deps build-js
# Dev env management
dev-setup: clean clean-dev install-composer-deps-dev js-init
composer.phar:
curl -sS https://getcomposer.org/installer | php
install-composer-deps: composer.phar
php composer.phar install --no-dev -o
install-composer-deps-dev: composer.phar
php composer.phar install -o
js-init:
yarn install
yarn-update:
yarn update
# Building
build-js: js-init
yarn run dev
build-js-production: js-init
yarn run build
watch-js: js-init
yarn run watch
# Linting
lint: js-init
yarn run lint
lint-fix: js-init
yarn run lint:fix
# Style linting
stylelint: js-init
yarn run stylelint
stylelint-fix: js-init
yarn run stylelint:fix
phplint:
./vendor/bin/php-cs-fixer fix --dry-run
phplint-fix:
./vendor/bin/php-cs-fixer fix
# Cleaning
clean:
rm -rf js/*
clean-dev:
rm -rf node_modules
pack:
mkdir -p archive
tar --exclude='./Makefile' --exclude='./webpack*' --exclude='./.*' --exclude='./ts' --exclude='./tests' --exclude='./node_modules' --exclude='./archive' -zcvf ./archive/cloud_bbb.tar.gz . --transform s/^./bbb/
# Tests
test:
./vendor/phpunit/phpunit/phpunit -c phpunit.xml
./vendor/phpunit/phpunit/phpunit -c phpunit.integration.xml