From 1f77cad30b0f793d33e91171662d9276391c8986 Mon Sep 17 00:00:00 2001 From: Christian Fritsch Date: Wed, 19 Jan 2022 17:08:44 +0100 Subject: [PATCH 1/7] feat: create lock --- .github/workflows/create-lock.yml | 41 +++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 .github/workflows/create-lock.yml diff --git a/.github/workflows/create-lock.yml b/.github/workflows/create-lock.yml new file mode 100644 index 000000000..2086d2094 --- /dev/null +++ b/.github/workflows/create-lock.yml @@ -0,0 +1,41 @@ +name: Deploy docs + +on: + push: + tags: + - '*' + branches: + - test-create-lock +jobs: + docs: + runs-on: ubuntu-20.04 + + steps: + - uses: actions/checkout@v1 + + - uses: shivammathur/setup-php@v2 + with: + coverage: none + php-version: 8.0 + extensions: Imagick + + - name: Cache composer dependencies + uses: actions/cache@v1 + with: + path: ~/.composer/cache + key: ${{ runner.os }}-composer-cache-${{ hashFiles('**/composer.json') }} + restore-keys: ${{ runner.os }}-composer-cache- + + - name: Get build environment + run: | + composer global require thunder/drupal-testing + + - name: Prepare the build + run: test-drupal-project prepare_build + + - name: Build the docroot + run: test-drupal-project build + + # Start a debug session. + - name: Setup tmate session + uses: mxschmitt/action-tmate@v3 From 0e18b96a4c9652d3e27e5bee7221b0a2018c3aa9 Mon Sep 17 00:00:00 2001 From: Christian Fritsch Date: Wed, 19 Jan 2022 17:12:17 +0100 Subject: [PATCH 2/7] fix: env --- .github/workflows/create-lock.yml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/.github/workflows/create-lock.yml b/.github/workflows/create-lock.yml index 2086d2094..bc1fff32a 100644 --- a/.github/workflows/create-lock.yml +++ b/.github/workflows/create-lock.yml @@ -1,4 +1,4 @@ -name: Deploy docs +name: Create composer.lock on: push: @@ -6,8 +6,13 @@ on: - '*' branches: - test-create-lock + +env: + DRUPAL_TESTING_COMPOSER_PROJECT: thunder/thunder-project + DRUPAL_TESTING_TEST_CODING_STYLES: false + jobs: - docs: + run: runs-on: ubuntu-20.04 steps: From 04f37f54a32c10585252a598a0c60080e74e0739 Mon Sep 17 00:00:00 2001 From: Christian Fritsch Date: Wed, 19 Jan 2022 17:33:19 +0100 Subject: [PATCH 3/7] empty --- .github/workflows/create-lock.yml | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/.github/workflows/create-lock.yml b/.github/workflows/create-lock.yml index bc1fff32a..da1088b2a 100644 --- a/.github/workflows/create-lock.yml +++ b/.github/workflows/create-lock.yml @@ -7,15 +7,20 @@ on: branches: - test-create-lock -env: - DRUPAL_TESTING_COMPOSER_PROJECT: thunder/thunder-project - DRUPAL_TESTING_TEST_CODING_STYLES: false - jobs: run: runs-on: ubuntu-20.04 steps: + + - name: Set env + run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV + + - name: Test + run: | + echo $RELEASE_VERSION + echo ${{ env.RELEASE_VERSION }} + - uses: actions/checkout@v1 - uses: shivammathur/setup-php@v2 @@ -33,7 +38,7 @@ jobs: - name: Get build environment run: | - composer global require thunder/drupal-testing + composer create-project thunder/thunder-project thunder --no-interaction --no-install - name: Prepare the build run: test-drupal-project prepare_build From 8ff07098421b293e674785f2c4f8d2f740f9e16a Mon Sep 17 00:00:00 2001 From: Christian Fritsch Date: Wed, 19 Jan 2022 17:34:35 +0100 Subject: [PATCH 4/7] empty --- .github/workflows/create-lock.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/create-lock.yml b/.github/workflows/create-lock.yml index da1088b2a..585cbd010 100644 --- a/.github/workflows/create-lock.yml +++ b/.github/workflows/create-lock.yml @@ -14,7 +14,7 @@ jobs: steps: - name: Set env - run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV + run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV - name: Test run: | From da297e8376d1fa18e684c7bf6d5ff74d180ab3a9 Mon Sep 17 00:00:00 2001 From: Christian Fritsch Date: Wed, 19 Jan 2022 17:37:07 +0100 Subject: [PATCH 5/7] empty --- .github/workflows/create-lock.yml | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/.github/workflows/create-lock.yml b/.github/workflows/create-lock.yml index 585cbd010..23e028dca 100644 --- a/.github/workflows/create-lock.yml +++ b/.github/workflows/create-lock.yml @@ -39,12 +39,8 @@ jobs: - name: Get build environment run: | composer create-project thunder/thunder-project thunder --no-interaction --no-install - - - name: Prepare the build - run: test-drupal-project prepare_build - - - name: Build the docroot - run: test-drupal-project build + composer require thunder/thunder-distribution:dev-${{ env.RELEASE_VERSION }} --no-install + composer update # Start a debug session. - name: Setup tmate session From e0cd5e7e502fa67d4d8a8a3db4d101150ced7e2c Mon Sep 17 00:00:00 2001 From: Christian Fritsch Date: Wed, 19 Jan 2022 17:39:06 +0100 Subject: [PATCH 6/7] empty --- .github/workflows/create-lock.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/create-lock.yml b/.github/workflows/create-lock.yml index 23e028dca..9ca6487a3 100644 --- a/.github/workflows/create-lock.yml +++ b/.github/workflows/create-lock.yml @@ -39,6 +39,7 @@ jobs: - name: Get build environment run: | composer create-project thunder/thunder-project thunder --no-interaction --no-install + cd thunder composer require thunder/thunder-distribution:dev-${{ env.RELEASE_VERSION }} --no-install composer update From 3b25c92c07806daabc3b98edce64df1e68dccddb Mon Sep 17 00:00:00 2001 From: Christian Fritsch Date: Thu, 20 Jan 2022 09:29:41 +0100 Subject: [PATCH 7/7] empty --- .github/workflows/create-lock.yml | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/.github/workflows/create-lock.yml b/.github/workflows/create-lock.yml index 9ca6487a3..c4d96f540 100644 --- a/.github/workflows/create-lock.yml +++ b/.github/workflows/create-lock.yml @@ -16,18 +16,12 @@ jobs: - name: Set env run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV - - name: Test - run: | - echo $RELEASE_VERSION - echo ${{ env.RELEASE_VERSION }} - - uses: actions/checkout@v1 - uses: shivammathur/setup-php@v2 with: coverage: none php-version: 8.0 - extensions: Imagick - name: Cache composer dependencies uses: actions/cache@v1 @@ -36,13 +30,10 @@ jobs: key: ${{ runner.os }}-composer-cache-${{ hashFiles('**/composer.json') }} restore-keys: ${{ runner.os }}-composer-cache- - - name: Get build environment + - name: Build Thunder run: | composer create-project thunder/thunder-project thunder --no-interaction --no-install cd thunder composer require thunder/thunder-distribution:dev-${{ env.RELEASE_VERSION }} --no-install composer update - # Start a debug session. - - name: Setup tmate session - uses: mxschmitt/action-tmate@v3