Skip to content

Commit 5f1d9e6

Browse files
committed
Merge branch '4.4' into 5.2
* 4.4: More dependencies (#2) # Conflicts: # composer.json # composer.lock
2 parents a81b848 + 88e96fd commit 5f1d9e6

File tree

23 files changed

+208
-27
lines changed

23 files changed

+208
-27
lines changed

.env

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,4 +31,16 @@ APP_SECRET=1a9dfc83d27556f6cf6add5b65aed37e
3131
# DATABASE_URL="sqlite:///%kernel.project_dir%/var/data.db"
3232
# DATABASE_URL="mysql://db_user:db_password@127.0.0.1:3306/db_name?serverVersion=5.7"
3333
DATABASE_URL="postgresql://db_user:db_password@127.0.0.1:5432/db_name?serverVersion=13&charset=utf8"
34+
DATABASE_PASSWORD=db_password
3435
###< doctrine/doctrine-bundle ###
36+
37+
HTTP_PORT=80
38+
###> symfony/mercure-bundle ###
39+
# See https://symfony.com/doc/current/mercure.html#configuration
40+
# The URL of the Mercure hub, used by the app to publish updates (can be a local URL)
41+
MERCURE_URL=https://127.0.0.1:8000/.well-known/mercure
42+
# The public URL of the Mercure hub, used by the browser to connect
43+
MERCURE_PUBLIC_URL=https://127.0.0.1:8000/.well-known/mercure
44+
# The secret used to sign the JWTs
45+
MERCURE_JWT_SECRET="!ChangeMe!"
46+
###< symfony/mercure-bundle ###

.github/workflows/.editorconfig

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
[*.yml]
2+
indent_size = 2

.github/workflows/ci.yml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: CI
2+
3+
on:
4+
push: ~
5+
pull_request: ~
6+
7+
jobs:
8+
build:
9+
name: Test
10+
runs-on: Ubuntu-20.04
11+
12+
steps:
13+
- name: Checkout code
14+
uses: actions/checkout@v2
15+
16+
- name: Set up PHP
17+
uses: shivammathur/setup-php@v2
18+
with:
19+
php-version: 8.0
20+
coverage: none
21+
22+
- name: Download dependencies
23+
uses: ramsey/composer-install@v1
24+
25+
- name: Run tests
26+
run: ./bin/console cache:warmup --env dev

.gitignore

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,3 +14,10 @@
1414
.phpunit.result.cache
1515
/phpunit.xml
1616
###< symfony/phpunit-bridge ###
17+
18+
###> symfony/webpack-encore-bundle ###
19+
/node_modules/
20+
/public/build/
21+
npm-debug.log
22+
yarn-error.log
23+
###< symfony/webpack-encore-bundle ###

assets/app.js

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
/*
2+
* Welcome to your app's main JavaScript file!
3+
*
4+
* We recommend including the built version of this JavaScript file
5+
* (and its CSS file) in your base layout (base.html.twig).
6+
*/
7+
8+
// any CSS you import will output into a single css file (app.css in this case)
9+
import './styles/app.css';
10+
11+
// start the Stimulus application
12+
import './bootstrap';

assets/bootstrap.js

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
import { startStimulusApp } from '@symfony/stimulus-bridge';
2+
3+
// Registers Stimulus controllers from controllers.json and in the controllers/ directory
4+
export const app = startStimulusApp(require.context(
5+
'@symfony/stimulus-bridge/lazy-controller-loader!./controllers',
6+
true,
7+
/\.(j|t)sx?$/
8+
));
9+
10+
// register any custom, 3rd party controllers here
11+
// app.register('some_controller_name', SomeImportedController);

assets/controllers.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"controllers": [],
3+
"entrypoints": []
4+
}
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
import { Controller } from 'stimulus';
2+
3+
/*
4+
* This is an example Stimulus controller!
5+
*
6+
* Any element with a data-controller="hello" attribute will cause
7+
* this controller to be executed. The name "hello" comes from the filename:
8+
* hello_controller.js -> "hello"
9+
*
10+
* Delete this file or adapt it for your use!
11+
*/
12+
export default class extends Controller {
13+
connect() {
14+
this.element.textContent = 'Hello Stimulus! Edit me in assets/controllers/hello_controller.js';
15+
}
16+
}

assets/css/.gitignore

Whitespace-only changes.

assets/images/.gitignore

Whitespace-only changes.

assets/js/.gitignore

Whitespace-only changes.

assets/styles/app.css

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
body {
2+
background-color: lightgray;
3+
}

composer.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@
2222
"symfony/http-client": "5.2.*",
2323
"symfony/intl": "5.2.*",
2424
"symfony/mailer": "5.2.*",
25+
"symfony/mercure-bundle": "^0.3.2",
26+
"symfony/messenger": "5.2.*",
2527
"symfony/monolog-bundle": "^3.1",
2628
"symfony/process": "5.2.*",
2729
"symfony/property-access": "5.2.*",
@@ -33,6 +35,7 @@
3335
"symfony/twig-bundle": "5.2.*",
3436
"symfony/validator": "5.2.*",
3537
"symfony/web-link": "5.2.*",
38+
"symfony/webpack-encore-bundle": "^1.11",
3639
"symfony/yaml": "5.2.*",
3740
"twig/extra-bundle": "^3.0",
3841
"twig/twig": "^3.0"

config/bundles.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,6 @@
1212
Doctrine\Bundle\MigrationsBundle\DoctrineMigrationsBundle::class => ['all' => true],
1313
Symfony\Bundle\SecurityBundle\SecurityBundle::class => ['all' => true],
1414
Twig\Extra\TwigExtraBundle\TwigExtraBundle::class => ['all' => true],
15+
Symfony\Bundle\MercureBundle\MercureBundle::class => ['all' => true],
16+
Symfony\WebpackEncoreBundle\WebpackEncoreBundle::class => ['all' => true],
1517
];

config/packages/framework.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
# see https://symfony.com/doc/current/reference/configuration/framework.html
22
framework:
3-
secret: '%env(APP_SECRET)%'
43
#csrf_protection: true
54
#http_method_override: true
65

config/packages/mailer.yaml

Lines changed: 0 additions & 3 deletions
This file was deleted.

config/packages/mercure.yaml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
mercure:
2+
hubs:
3+
default:
4+
url: '%env(MERCURE_URL)%'
5+
public_url: '%env(MERCURE_PUBLIC_URL)%'
6+
jwt:
7+
secret: '%env(MERCURE_JWT_SECRET)%'
8+
publish: '*'

config/packages/messenger.yaml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
framework:
2+
messenger:
3+
# Uncomment this (and the failed transport below) to send failed messages to this transport for later handling.
4+
# failure_transport: failed
5+
6+
transports:
7+
# https://symfony.com/doc/current/messenger.html#transport-configuration
8+
# async: '%env(MESSENGER_TRANSPORT_DSN)%'
9+
# failed: 'doctrine://default?queue_name=failed'
10+
# sync: 'sync://'
11+
12+
routing:
13+
# Route your messages to the transports
14+
# 'App\Message\YourMessage': async

config/packages/security.yaml

Lines changed: 0 additions & 23 deletions
This file was deleted.

config/packages/webpack_encore.yaml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
webpack_encore:
2+
# The path where Encore is building the assets - i.e. Encore.setOutputPath()
3+
output_path: '%kernel.project_dir%/public/build'
4+
# If multiple builds are defined (as shown below), you can disable the default build:
5+
# output_path: false
6+
7+
# Set attributes that will be rendered on all script and link tags
8+
script_attributes:
9+
defer: true
10+
# link_attributes:
11+
12+
# If using Encore.enableIntegrityHashes() and need the crossorigin attribute (default: false, or use 'anonymous' or 'use-credentials')
13+
# crossorigin: 'anonymous'
14+
15+
# Preload all rendered script and link tags automatically via the HTTP/2 Link header
16+
# preload: true
17+
18+
# Throw an exception if the entrypoints.json file is missing or an entry is missing from the data
19+
# strict_mode: false
20+
21+
# If you have multiple builds:
22+
# builds:
23+
# pass "frontend" as the 3rg arg to the Twig functions
24+
# {{ encore_entry_script_tags('entry1', null, 'frontend') }}
25+
26+
# frontend: '%kernel.project_dir%/public/frontend/build'
27+
28+
# Cache the entrypoints.json (rebuild Symfony's cache when entrypoints.json changes)
29+
# Put in config/packages/prod/webpack_encore.yaml
30+
# cache: true

config/services.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,3 +29,6 @@ services:
2929

3030
# add more service definitions when explicit configuration is needed
3131
# please note that last definitions always *replace* previous ones
32+
33+
framework:
34+
secret: '%env(APP_SECRET)%'

email/default/templates/.gitignore

Whitespace-only changes.

symfony.lock

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,12 @@
9797
"laminas/laminas-zendframework-bridge": {
9898
"version": "1.2.0"
9999
},
100+
"lcobucci/clock": {
101+
"version": "2.0.0"
102+
},
103+
"lcobucci/jwt": {
104+
"version": "4.1.4"
105+
},
100106
"monolog/monolog": {
101107
"version": "1.26.0"
102108
},
@@ -290,6 +296,33 @@
290296
"ref": "fadbfe33303a76e25cb63401050439aa9b1a9c7f"
291297
}
292298
},
299+
"symfony/mercure": {
300+
"version": "v0.5.3"
301+
},
302+
"symfony/mercure-bundle": {
303+
"version": "0.3",
304+
"recipe": {
305+
"repo": "github.com/symfony/recipes",
306+
"branch": "master",
307+
"version": "0.3",
308+
"ref": "d1cdff3ae53bf6a5cbfb088c82f26032bdc14cc3"
309+
},
310+
"files": [
311+
"config/packages/mercure.yaml"
312+
]
313+
},
314+
"symfony/messenger": {
315+
"version": "4.3",
316+
"recipe": {
317+
"repo": "github.com/symfony/recipes",
318+
"branch": "master",
319+
"version": "4.3",
320+
"ref": "e9a414b113ceadbf4e52abe37bf8f1b443f06ccb"
321+
},
322+
"files": [
323+
"config/packages/messenger.yaml"
324+
]
325+
},
293326
"symfony/mime": {
294327
"version": "v4.4.21"
295328
},
@@ -499,6 +532,28 @@
499532
"config/routes/dev/web_profiler.yaml"
500533
]
501534
},
535+
"symfony/webpack-encore-bundle": {
536+
"version": "1.9",
537+
"recipe": {
538+
"repo": "github.com/symfony/recipes",
539+
"branch": "master",
540+
"version": "1.9",
541+
"ref": "9399a0bfc6ee7a0c019f952bca46d6a6045dd451"
542+
},
543+
"files": [
544+
"assets/app.js",
545+
"assets/bootstrap.js",
546+
"assets/controllers.json",
547+
"assets/controllers/hello_controller.js",
548+
"assets/styles/app.css",
549+
"config/packages/assets.yaml",
550+
"config/packages/prod/webpack_encore.yaml",
551+
"config/packages/test/webpack_encore.yaml",
552+
"config/packages/webpack_encore.yaml",
553+
"package.json",
554+
"webpack.config.js"
555+
]
556+
},
502557
"symfony/yaml": {
503558
"version": "v4.4.21"
504559
},

0 commit comments

Comments
 (0)