Skip to content

Commit

Permalink
Merge branch '9.4.x' into 8.4-fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
aembler authored Nov 23, 2024
2 parents c1a6a57 + b469389 commit 6c799d2
Show file tree
Hide file tree
Showing 3,071 changed files with 16,703 additions and 12,741 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
86 changes: 86 additions & 0 deletions .github/workflows/build-assets.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,86 @@
name: Build assets

on:
pull_request:
push:
branches:
- "**"
tags-ignore:
- "**"

jobs:
build-assets:
strategy:
matrix:
include:
- os: ubuntu-latest
nodejs-version: 18
# Just one case may have this set to yes
update-repo: yes
name: Build assets (node ${{ matrix.nodejs-version }} on ${{ matrix.os }})
runs-on: ${{ matrix.os }}
steps:
- name: Setup NodeJS
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.nodejs-version }}
- name: Checkout
uses: actions/checkout@v3
- name: Install NodeJS dependencies
run: |
cd "${{ github.workspace }}/build"
npm ci
- name: Build assets (dev)
run: |
cd "${{ github.workspace }}/build"
npm run-script dev
- name: Tell git to ignore the built files
run: |
cd "${{ github.workspace }}/build"
npm run-script git-skip
- name: Check that git thinks the repo is clean
run: |
cd "${{ github.workspace }}"
git diff --exit-code --name-status
- name: Revert changed files
run: |
cd "${{ github.workspace }}/build"
npm run-script git-revert
- name: Check that git thinks the repo is clean
run: |
cd "${{ github.workspace }}"
git diff --exit-code --name-status
- name: Build assets (prod)
run: |
cd "${{ github.workspace }}/build"
npm run-script prod
- name: Check if we need to create a pull request
if: matrix.update-repo == 'yes'
id: pr-test
run: |
cd '${{ github.workspace }}'
if git diff --exit-code --name-status; then
echo "We won't create a pull request because no change has been detected"
elif [ '${{ github.event_name }}' != 'push' ]; then
echo "We won't create a pull request because it's a '${{ github.event_name }}' operation and not a 'push' one"
elif [ '${{ github.repository }}' != 'concretecms/concretecms' ]; then
echo "We won't create a pull request because the current repository is '${{ github.repository }}' and not 'concretecms/concretecms'"
else
echo 'Changes detected and pull request needed!'
echo "result=yes" >>"$GITHUB_OUTPUT"
echo "branch-name=auto-assets/$(date --utc +%Y%m%d-%H%M%S)" >>"$GITHUB_OUTPUT"
fi
- name: Create pull request
id: pr-create
if: steps.pr-test.outputs.result == 'yes'
uses: peter-evans/create-pull-request@v5
with:
commit-message: Automatic assets rebuilding
committer: GitHub Action <[email protected]>
author: GitHub Action <[email protected]>
branch: '${{ steps.pr-test.outputs.branch-name }}'
title: "Automatic assets rebuilding for ${{ github.ref_name }}"
body: "Created by ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}"
- name: Pull request info
if: steps.pr-test.outputs.result == 'yes'
run: printf 'Pull request created:\n%s' "${{ steps.pr-create.outputs.pull-request-url }}"
31 changes: 31 additions & 0 deletions .github/workflows/check-syntax.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Check Syntax

on:
pull_request:
push:

jobs:
check-syntax:
name: PHP
runs-on: ubuntu-latest
steps:
-
name: Checkout
uses: actions/checkout@v4
-
name: Install PHP
uses: shivammathur/setup-php@v2
with:
# This should be the value of Concrete\Core\Install\Preconditions\PhpVersion::MINIMUM_PHP_VERSION
php-version: 7.3
extensions: opcache
coverage: none
tools: none
-
name: Check syntax
uses: mlocati/check-php-syntax@main
with:
directory: concrete
include: |
bin/concrete
bin/concrete5
4 changes: 4 additions & 0 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
include:
- template: Jobs/SAST.latest.gitlab-ci.yml
- template: Jobs/Dependency-Scanning.latest.gitlab-ci.yml
- template: Jobs/Secret-Detection.latest.gitlab-ci.yml
3,506 changes: 2 additions & 3,504 deletions CHANGELOG.md

Large diffs are not rendered by default.

18 changes: 7 additions & 11 deletions application/bootstrap/autoload.php
Original file line number Diff line number Diff line change
@@ -1,18 +1,14 @@
<?php

defined('C5_EXECUTE') or die('Access Denied.');
declare(strict_types=1);

/*
* ----------------------------------------------------------------------------
* Load all composer autoload items.
* ----------------------------------------------------------------------------
*/
defined('C5_EXECUTE') or die('Access Denied.');

// If the checker class is already provided, likely we have been included in a separate composer project
if (!class_exists(\DoctrineXml\Checker::class)) {
// Otherwise, lets try to load composer ourselves
if (!@include(DIR_BASE_CORE . '/' . DIRNAME_VENDOR . '/autoload.php')) {
// If the follwing class is already provided, we are likely in a composer-based Concrete installation
if (!class_exists(Illuminate\Container\Container::class)) {
// Otherwise, let's try to load composer ourselves
if (!@include DIR_BASE_CORE . '/' . DIRNAME_VENDOR . '/autoload.php') {
echo 'Third party libraries not installed. Make sure that composer has required libraries in the concrete/ directory.';
die(1);
exit(1);
}
}
1 change: 1 addition & 0 deletions application/images/countries/.gitkeep
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@

1 change: 0 additions & 1 deletion build/assets/themes/dashboard/js/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ import './groups/group-manager';
import './translator';

// Marketplace support
import './remote-marketplace';
import 'magnific-popup'
import '@concretecms/bedrock/assets/imagery/js/frontend/responsive-slides';

Expand Down
73 changes: 0 additions & 73 deletions build/assets/themes/dashboard/js/remote-marketplace.js

This file was deleted.

3 changes: 3 additions & 0 deletions build/libraries/built-assets.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ function getBuiltFiles()
'css/features/profile/frontend.css',
'css/features/search/frontend.css',
'css/features/social/frontend.css',
'css/features/staging/frontend.css',
'css/features/taxonomy/frontend.css',
'css/features/testimonials/frontend.css',
'css/features/video/frontend.css',
Expand All @@ -96,10 +97,12 @@ function getBuiltFiles()
'js/features/desktop/frontend.js',
'js/features/documents/frontend.js',
'js/features/express/frontend.js',
'js/features/forms/frontend.js',
'js/features/imagery/frontend.js',
'js/features/maps/frontend.js',
'js/features/multilingual/frontend.js',
'js/features/navigation/frontend.js',
'js/features/forms/frontend.js',
'js/fullcalendar.js',
'js/jquery.js',
'js/tui-image-editor.js',
Expand Down
Loading

0 comments on commit 6c799d2

Please sign in to comment.