From 69f242811bfa5b3dc4c2e6e265312c6d77b11755 Mon Sep 17 00:00:00 2001 From: Nabeel Shahzad Date: Thu, 4 Jan 2018 15:17:55 -0600 Subject: [PATCH] move version generation so it doesnt recreate some of the cached files --- .travis/deploy_script.sh | 15 +++++++++------ Makefile | 10 +++++----- 2 files changed, 14 insertions(+), 11 deletions(-) diff --git a/.travis/deploy_script.sh b/.travis/deploy_script.sh index 7c551dd9..25bfbb08 100755 --- a/.travis/deploy_script.sh +++ b/.travis/deploy_script.sh @@ -19,12 +19,19 @@ if [ "$TRAVIS" = "true" ]; then cd $TRAVIS_BUILD_DIR + echo "Version:" + php artisan version:show --format compact --suppress-app-name > VERSION + cat VERSION + make clean - echo "" rm -rf env.php find ./vendor -type d -name ".git" -print0 | xargs rm -rf + # clear any app specific stuff that might have been loaded in + find storage/app/public -not -name '.gitignore' -print0 | xargs -0 rm -rf + find storage/app -not -name '.gitignore' -not -name public -print0 | xargs -0 rm -rf + # Remove any development files rm -rf .sass-cache rm -rf .idea phpvms.iml .travis .dpl @@ -37,13 +44,9 @@ if [ "$TRAVIS" = "true" ]; then # delete files in vendor that are rather large rm -rf vendor/willdurand/geocoder/tests - echo "Creating tar for version" - php artisan version:show --format compact --suppress-app-name > VERSION - cat VERSION - echo "creating tarball" cd /tmp - tar -czf $TAR_NAME -C $TRAVIS_BUILD_DIR/../ phpvms phpvms/.* + tar -czf $TAR_NAME -C $TRAVIS_BUILD_DIR/../ phpvms #git archive --format=tar.gz --prefix=phpvms/ --output=test.tar.gz HEAD echo "running rsync" diff --git a/Makefile b/Makefile index e6cda293..8bfd208e 100644 --- a/Makefile +++ b/Makefile @@ -17,11 +17,11 @@ clean: @php artisan config:clear @php artisan view:clear @find bootstrap/cache -type f -not -name '.gitignore' -print0 | xargs -0 rm -rf - @find storage/app/public -type f -not -name '.gitignore' -print0 | xargs -0 rm -rf - @find storage/app -type f -not -name '.gitignore' -not -name public -print0 | xargs -0 rm -rf - @find storage/framework/cache/ -type f -or -type d -not -name '.gitignore' -mindepth 1 -print0 | xargs -0 rm -rf - @find storage/framework/sessions/ -type f -or -type d -not -name '.gitignore' -print0 | xargs -0 rm -rf - @find storage/framework/views/ -type f -or -type d -not -name '.gitignore' -print0 | xargs -0 rm -rf + + @find storage/framework/cache/ -not -name '.gitignore' -mindepth 1 -print0 | xargs -0 rm -rf + @find storage/framework/sessions/ -type f -not -name '.gitignore' -mindepth 1 -print0 | xargs -0 rm -rf + @find storage/framework/views/ -not -name '.gitignore' -mindepth 1 -print0 | xargs -0 rm -rf + @find storage/logs -type f -not -name '.gitignore' -print0 | xargs -0 rm -rf .PHONY: clean-routes