Skip to content

Commit e03a0f7

Browse files
committed
feat(dotcms-symfony): Add development configuration and update README for local SDK setup
- Introduced composer.dev.json and symfony.dev.lock for local SDK development. - Updated README.md with instructions for using the local SDK version during development.
1 parent cf631fc commit e03a0f7

4 files changed

Lines changed: 11105 additions & 0 deletions

File tree

examples/dotcms-symfony/README.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,27 @@ DOTCMS_HOST=https://demo.dotcms.com
109109
DOTCMS_API_KEY=your-api-key-here
110110
```
111111

112+
### Using Local SDK Development Setup
113+
114+
If you want to test the Symfony example with a local version of the PHP SDK (for development or testing new changes), you can use the `composer.dev.json` configuration:
115+
116+
1. First, ensure you're in the Symfony example directory:
117+
```bash
118+
cd examples/dotcms-symfony
119+
```
120+
121+
2. If you have previously run `composer install`, remove the vendor directory:
122+
```bash
123+
rm -rf vendor
124+
```
125+
126+
3. Install dependencies using the development configuration:
127+
```bash
128+
COMPOSER=composer.dev.json composer install
129+
```
130+
131+
This will use the local SDK from the parent directory instead of the published package version.
132+
112133
## Configuration
113134

114135
All the configuration described below is already implemented in this example project. The following sections explain the key components and how they work together to integrate DotCMS with Symfony.
Lines changed: 120 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,120 @@
1+
{
2+
"type": "project",
3+
"license": "proprietary",
4+
"minimum-stability": "stable",
5+
"prefer-stable": true,
6+
"repositories": [
7+
{
8+
"type": "path",
9+
"url": "../../"
10+
}
11+
],
12+
"require": {
13+
"dotcms/php-sdk": "dev-main",
14+
"php": ">=8.2",
15+
"ext-ctype": "*",
16+
"ext-iconv": "*",
17+
"doctrine/dbal": "^3.9.4",
18+
"doctrine/doctrine-bundle": "^2.13.2",
19+
"doctrine/doctrine-migrations-bundle": "^3.4.1",
20+
"doctrine/orm": "^3.3.2",
21+
"phpdocumentor/reflection-docblock": "^5.6.1",
22+
"phpstan/phpdoc-parser": "^2.1",
23+
"symfony/asset": "7.2.*",
24+
"symfony/asset-mapper": "7.2.*",
25+
"symfony/console": "7.2.*",
26+
"symfony/doctrine-messenger": "7.2.*",
27+
"symfony/dotenv": "7.2.*",
28+
"symfony/expression-language": "7.2.*",
29+
"symfony/flex": "^2.5",
30+
"symfony/form": "7.2.*",
31+
"symfony/framework-bundle": "7.2.*",
32+
"symfony/http-client": "7.2.*",
33+
"symfony/intl": "7.2.*",
34+
"symfony/mailer": "7.2.*",
35+
"symfony/mime": "7.2.*",
36+
"symfony/monolog-bundle": "^3.10",
37+
"symfony/notifier": "7.2.*",
38+
"symfony/process": "7.2.*",
39+
"symfony/property-access": "7.2.*",
40+
"symfony/property-info": "7.2.*",
41+
"symfony/runtime": "7.2.*",
42+
"symfony/security-bundle": "7.2.*",
43+
"symfony/serializer": "7.2.*",
44+
"symfony/stimulus-bundle": "^2.23",
45+
"symfony/string": "7.2.*",
46+
"symfony/translation": "7.2.*",
47+
"symfony/twig-bundle": "7.2.*",
48+
"symfony/ux-turbo": "^2.23",
49+
"symfony/validator": "7.2.*",
50+
"symfony/web-link": "7.2.*",
51+
"symfony/yaml": "7.2.*",
52+
"twig/extra-bundle": "^2.12|^3.20",
53+
"twig/twig": "^2.12|^3.20"
54+
},
55+
"config": {
56+
"allow-plugins": {
57+
"php-http/discovery": true,
58+
"symfony/flex": true,
59+
"symfony/runtime": true
60+
},
61+
"bump-after-update": true,
62+
"sort-packages": true
63+
},
64+
"autoload": {
65+
"psr-4": {
66+
"App\\": "src/"
67+
}
68+
},
69+
"autoload-dev": {
70+
"psr-4": {
71+
"App\\Tests\\": "tests/"
72+
}
73+
},
74+
"replace": {
75+
"symfony/polyfill-ctype": "*",
76+
"symfony/polyfill-iconv": "*",
77+
"symfony/polyfill-php72": "*",
78+
"symfony/polyfill-php73": "*",
79+
"symfony/polyfill-php74": "*",
80+
"symfony/polyfill-php80": "*",
81+
"symfony/polyfill-php81": "*",
82+
"symfony/polyfill-php82": "*"
83+
},
84+
"scripts": {
85+
"auto-scripts": {
86+
"cache:clear": "symfony-cmd",
87+
"assets:install %PUBLIC_DIR%": "symfony-cmd",
88+
"importmap:install": "symfony-cmd"
89+
},
90+
"post-install-cmd": [
91+
"@auto-scripts"
92+
],
93+
"post-update-cmd": [
94+
"@auto-scripts"
95+
],
96+
"dev": [
97+
"Composer\\Config::disableProcessTimeout",
98+
"npx concurrently -c \"#93c5fd,#c4b5fd,#fb7185,#fdba74\" \"symfony server:start\" \"symfony run -d --watch=config,src,templates,vendor/symfony,tests public/index.php\" \"symfony console messenger:consume --time-limit=3600\" \"npm run dev\" --names=server,php,queue,vite"
99+
]
100+
},
101+
"conflict": {
102+
"symfony/symfony": "*"
103+
},
104+
"extra": {
105+
"symfony": {
106+
"allow-contrib": false,
107+
"require": "7.2.*"
108+
}
109+
},
110+
"require-dev": {
111+
"phpunit/phpunit": "^9.6.22",
112+
"symfony/browser-kit": "7.2.*",
113+
"symfony/css-selector": "7.2.*",
114+
"symfony/debug-bundle": "7.2.*",
115+
"symfony/maker-bundle": "^1.62.1",
116+
"symfony/phpunit-bridge": "^7.2",
117+
"symfony/stopwatch": "7.2.*",
118+
"symfony/web-profiler-bundle": "7.2.*"
119+
}
120+
}

0 commit comments

Comments
 (0)