Skip to content

Commit

Permalink
Merge tag 'v1.6.0' into production
Browse files Browse the repository at this point in the history
  • Loading branch information
jobara committed Dec 10, 2024
2 parents 2ff92dd + b078b51 commit ceabc90
Show file tree
Hide file tree
Showing 320 changed files with 10,864 additions and 10,772 deletions.
3 changes: 0 additions & 3 deletions .commitlintrc.json

This file was deleted.

14 changes: 0 additions & 14 deletions .github/dependabot.yml

This file was deleted.

15 changes: 9 additions & 6 deletions .github/workflows/analyze.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
php: [8.2]
php: [8.4]

steps:
- uses: actions/checkout@v4
- uses: technote-space/get-diff-action@v6
- uses: greguintow/get-diff-action@v7
id: git-diff
with:
patterns: |
Expand All @@ -27,12 +27,15 @@ jobs:
with:
php-version: ${{ matrix.php }}
coverage: none
- name: Cache Composer packages
if: steps.git-diff.outputs.diff
- name: Get composer cache directory
id: composer-cache
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT
- name: Cache composer dependencies
uses: actions/cache@v4
with:
path: vendor
key: php-${{ hashFiles('**/composer.lock') }}
path: ${{ steps.composer-cache.outputs.dir }}
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
restore-keys: ${{ runner.os }}-composer-
- name: Install dependencies
if: steps.git-diff.outputs.diff
run: composer install -q --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist
Expand Down
15 changes: 9 additions & 6 deletions .github/workflows/asset-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
php: [8.2]
php: [8.4]

steps:
- uses: actions/checkout@v4
- uses: technote-space/get-diff-action@v6
- uses: greguintow/get-diff-action@v7
id: git-diff
with:
patterns: |
Expand All @@ -28,12 +28,15 @@ jobs:
with:
php-version: ${{ matrix.php }}
coverage: none
- name: Cache Composer packages
if: steps.git-diff.outputs.diff
- name: Get composer cache directory
id: composer-cache
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT
- name: Cache composer dependencies
uses: actions/cache@v4
with:
path: vendor
key: php-${{ hashFiles('**/composer.lock') }}
path: ${{ steps.composer-cache.outputs.dir }}
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
restore-keys: ${{ runner.os }}-composer-
- name: Install dependencies
if: steps.git-diff.outputs.diff
run: composer install -q --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist
Expand Down
17 changes: 10 additions & 7 deletions .github/workflows/frontend.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
php: [8.2]
php: [8.4]

steps:
- uses: actions/checkout@v4
- uses: technote-space/get-diff-action@v6
- uses: greguintow/get-diff-action@v7
id: git-diff
with:
patterns: |
Expand All @@ -31,12 +31,15 @@ jobs:
with:
php-version: ${{ matrix.php }}
coverage: none
- name: Cache Composer packages
if: steps.git-diff.outputs.diff
- name: Get composer cache directory
id: composer-cache
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT
- name: Cache composer dependencies
uses: actions/cache@v4
with:
path: vendor
key: php-${{ hashFiles('**/composer.lock') }}
path: ${{ steps.composer-cache.outputs.dir }}
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
restore-keys: ${{ runner.os }}-composer-
- name: Install Dependencies
if: steps.git-diff.outputs.diff
run: composer install -q --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist
Expand Down Expand Up @@ -73,7 +76,7 @@ jobs:
run: php artisan dusk:chrome-driver `/opt/google/chrome/chrome --version | cut -d " " -f3 | cut -d "." -f1`
- name: Start Chrome Driver
if: steps.git-diff.outputs.diff
run: ./vendor/laravel/dusk/bin/chromedriver-linux &
run: ./vendor/laravel/dusk/bin/chromedriver-linux --port=9515 &
- name: Run Laravel Server
if: steps.git-diff.outputs.diff
run: |
Expand Down
23 changes: 13 additions & 10 deletions .github/workflows/laravel.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
strategy:
fail-fast: true
matrix:
php: [8.2, 8.3]
php: [8.4]

name: tests - PHP ${{ matrix.php }}

Expand All @@ -21,7 +21,7 @@ jobs:

steps:
- uses: actions/checkout@v4
- uses: technote-space/get-diff-action@v6
- uses: greguintow/get-diff-action@v7
id: git-diff
with:
patterns: |
Expand All @@ -33,12 +33,15 @@ jobs:
with:
php-version: ${{ matrix.php }}
coverage: pcov
- name: Cache Composer packages
if: steps.git-diff.outputs.diff
- name: Get composer cache directory
id: composer-cache
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT
- name: Cache composer dependencies
uses: actions/cache@v4
with:
path: vendor
key: php-${{ hashFiles('**/composer.lock') }}
path: ${{ steps.composer-cache.outputs.dir }}
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
restore-keys: ${{ runner.os }}-composer-
- name: Install Dependencies
if: steps.git-diff.outputs.diff
run: composer install -q --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist
Expand Down Expand Up @@ -74,7 +77,7 @@ jobs:
if: steps.git-diff.outputs.diff
run: chmod -R 777 storage bootstrap/cache
- name: Run tests
if: steps.git-diff.outputs.diff && matrix.php == '8.3'
if: steps.git-diff.outputs.diff && matrix.php != '8.4'
env:
DB_DATABASE: tae-test
DB_PASSWORD: root
Expand All @@ -84,7 +87,7 @@ jobs:
php artisan storage:link
php artisan test
- name: Run tests with coverage
if: steps.git-diff.outputs.diff && matrix.php == '8.2'
if: steps.git-diff.outputs.diff && matrix.php == '8.4'
env:
DB_DATABASE: tae-test
DB_PASSWORD: root
Expand All @@ -95,7 +98,7 @@ jobs:
php artisan test --coverage-clover coverage.xml
- name: Save code coverage to artifact
uses: actions/upload-artifact@v4
if: steps.git-diff.outputs.diff && matrix.php == '8.2'
if: steps.git-diff.outputs.diff && matrix.php == '8.4'
with:
name: code-coverage
path: "coverage.xml"
Expand All @@ -113,7 +116,7 @@ jobs:
with:
name: code-coverage
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4
uses: codecov/codecov-action@v5
with:
token: ${{ secrets.CODECOV_TOKEN }}
fail_ci_if_error: true
15 changes: 9 additions & 6 deletions .github/workflows/lighthouse.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,13 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
php: [8.2]
php: [8.4]

steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.sha }} # https://github.com/GoogleChrome/lighthouse-ci/issues/172
- uses: technote-space/get-diff-action@v6
- uses: greguintow/get-diff-action@v7
id: git-diff
with:
patterns: |
Expand All @@ -34,12 +34,15 @@ jobs:
with:
php-version: ${{ matrix.php }}
coverage: none
- name: Cache Composer packages
if: steps.git-diff.outputs.diff
- name: Get composer cache directory
id: composer-cache
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT
- name: Cache composer dependencies
uses: actions/cache@v4
with:
path: vendor
key: php-${{ hashFiles('**/composer.lock') }}
path: ${{ steps.composer-cache.outputs.dir }}
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
restore-keys: ${{ runner.os }}-composer-
- name: Install Dependencies
if: steps.git-diff.outputs.diff
run: composer install -q --no-dev --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist
Expand Down
87 changes: 87 additions & 0 deletions .github/workflows/merge-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
name: Merge Release

on:
release:
types: [released]
workflow_dispatch:
inputs:
branch:
description: 'Branch to merge into'
required: true
type: string
default: production
tag:
description: 'Tag to merge'
required: true
type: string

jobs:
merge-release:
timeout-minutes: 5
runs-on: ubuntu-latest
permissions:
contents: write
strategy:
fail-fast: true

name: Merge tag

steps:
- uses: actions/create-github-app-token@v1
id: app-token
with:
app-id: ${{ vars.GHA_APP_ID }}
private-key: ${{ secrets.GHA_PRIVATE_KEY }}

- name: Determine branch
run: |
echo 'BRANCH='${{ inputs.branch || 'staging' }} >> $GITHUB_ENV
- name: Checkout "${{ env.BRANCH }}" branch locally
uses: actions/checkout@v4
with:
ref: ${{ env.BRANCH }}
fetch-tags: true
fetch-depth: 0
token: ${{ steps.app-token.outputs.token }}

- name: Get GitHub App User ID
if: ${{ github.event_name == 'release' }}
id: get-user-id
run: echo "user-id=$(gh api "/users/${{ steps.app-token.outputs.app-slug }}[bot]" --jq .id)" >> "$GITHUB_OUTPUT"
env:
GH_TOKEN: ${{ steps.app-token.outputs.token }}

- name: Update values for git user config (release)
if: ${{ github.event_name == 'release' }}
run: |
echo "GIT_USER_NAME=${{ steps.app-token.outputs.app-slug }}[bot]" >> $GITHUB_ENV
echo "GIT_USER_EMAIL=${{ steps.get-user-id.outputs.user-id }}+${{ steps.app-token.outputs.app-slug }}[bot]@users.noreply.github.com>" >> $GITHUB_ENV
- name: Update values for git user config (workflow_dispatch)
if: ${{ github.event_name == 'workflow_dispatch' }}
run: |
# fetch user info
user=$(gh api \
-H "Accept: application/vnd.github+json" \
-H "X-GitHub-Api-Version: 2022-11-28" \
/user/$ACCOUNT_ID )
# get user's name and email
# email will be set to null if it is private
name=$(echo $user | jq '.name')
email=$(echo $user | jq '.email')
# store in environment variables to use for setting up git user
echo "GIT_USER_NAME=$name" >> $GITHUB_ENV
echo "GIT_USER_EMAIL=$email" >> $GITHUB_ENV
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
ACCOUNT_ID: ${{ github.actor_id }}

- name: Merge tag to "${{ env.BRANCH }}" branch
run: |
git config --local user.email "$GIT_USER_EMAIL"
git config --local user.name "$GIT_USER_NAME"
git merge ${{ inputs.tag || github.event.release.tag_name }}
git push
1 change: 1 addition & 0 deletions .github/workflows/mirror-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ jobs:
- name: Checkout code
uses: actions/checkout@v4
with:
ref: dev
fetch-depth: 0

- name: Set up Git
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/mirror-production.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ jobs:
- name: Checkout code
uses: actions/checkout@v4
with:
ref: production
fetch-depth: 0

- name: Set up Git
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/mirror-staging.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ jobs:
- name: Checkout code
uses: actions/checkout@v4
with:
ref: staging
fetch-depth: 0

- name: Set up Git
Expand Down
14 changes: 11 additions & 3 deletions .github/workflows/release-please.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,18 @@ on:
jobs:
release-please:
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
steps:
- uses: google-github-actions/release-please-action@v4
id: release
- uses: actions/create-github-app-token@v1
id: app-token
with:
token: ${{ secrets.GITHUB_TOKEN }}
app-id: ${{ vars.GHA_APP_ID }}
private-key: ${{ secrets.GHA_PRIVATE_KEY }}

- uses: googleapis/release-please-action@v4
with:
token: ${{ steps.app-token.outputs.token }}
config-file: release-please-config.json
manifest-file: .release-please-manifest.json
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
/public/sitemap.xml
/resources/lang/lsq
/resources/lang/lsq.json
/resources/lang/vendor/hearth/lsq
/resources/lang/vendor/hearth-components/lsq
/storage/*.key
/vendor
.DS_Store
Expand Down
3 changes: 0 additions & 3 deletions .husky/commit-msg
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

npx --no-install commitlint --edit $1
3 changes: 0 additions & 3 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

npx --no-install lint-staged
Loading

0 comments on commit ceabc90

Please sign in to comment.