Created make clean target

This commit is contained in:
Jeroen De Meerleer 2019-06-18 15:13:14 +02:00
parent 82858a89fe
commit 9781c2895f
Signed by: JeroenED
GPG Key ID: 28CCCB8F62BFADD6
2 changed files with 15 additions and 2 deletions

View File

View File

@ -14,6 +14,7 @@ view-coverage: ## Shows the code coverage report
open build/coverage/index.html open build/coverage/index.html
api: ## Generates api-docs api: ## Generates api-docs
mkdir -p vendor/bin/
wget -O vendor/bin/phpdoc http://www.phpdoc.org/phpDocumentor.phar wget -O vendor/bin/phpdoc http://www.phpdoc.org/phpDocumentor.phar
chmod +x vendor/bin/phpdoc chmod +x vendor/bin/phpdoc
vendor/bin/phpdoc vendor/bin/phpdoc
@ -28,14 +29,26 @@ dist: ## Generates distribution
rm dist/composer.json rm dist/composer.json
rm dist/composer.lock rm dist/composer.lock
mv dist/composer-dist-installed.json dist/composer.json mv dist/composer-dist-installed.json dist/composer.json
git reset --hard HEAD^ mkdir -p vendor/bin/
wget -O vendor/bin/phpdoc http://www.phpdoc.org/phpDocumentor.phar wget -O vendor/bin/phpdoc http://www.phpdoc.org/phpDocumentor.phar
chmod +x vendor/bin/phpdoc chmod +x vendor/bin/phpdoc
vendor/bin/phpdoc vendor/bin/phpdoc
mkdir -p dist/doc mkdir -p dist/doc
cp -r doc/api dist/doc cp -r doc/api dist/doc
cd dist && zip -r ../libpairtwo-dist * cd dist && zip -r ../libpairtwo-dist *
mv res/composer* res/ git reset --hard HEAD^
mv res/composer* dist/
clean: ## Cleans the repository
rm -rf dist/doc
rm -rf doc/api
rm -rf .idea
rm -rf .libpairtwo-distro
rm -rf vendor
rm -rf composer.lock
rm -rf dist/vendor
rm -rf dist/composer.json
rm -rf libpairtwo-dist.zip
cs: ## Fixes coding standard problems cs: ## Fixes coding standard problems
vendor/bin/php-cs-fixer fix || true vendor/bin/php-cs-fixer fix || true