Skip to content

Commit c1047b3

Browse files
authored
Merge pull request #12216 from paulinevos/docs-builder
Use docs builder in ORM repo
2 parents 96f9b29 + aa62efa commit c1047b3

File tree

7 files changed

+14
-37
lines changed

7 files changed

+14
-37
lines changed

.github/workflows/documentation.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,4 @@ on:
1717
jobs:
1818
documentation:
1919
name: "Documentation"
20-
uses: "doctrine/.github/.github/workflows/documentation.yml@10.1.0"
20+
uses: "doctrine/.github/.github/workflows/documentation.yml@12.0.0"

composer.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,9 @@
1212
{"name": "Jonathan Wage", "email": "[email protected]"},
1313
{"name": "Marco Pivetta", "email": "[email protected]"}
1414
],
15+
"scripts": {
16+
"docs": "composer --working-dir docs update && ./docs/vendor/bin/build-docs.sh @additional_args"
17+
},
1518
"config": {
1619
"allow-plugins": {
1720
"composer/package-versions-deprecated": true,

docs/.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
composer.lock
22
vendor/
3-
build/
3+
output/

docs/Makefile

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

docs/README.md

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,19 +4,15 @@ The documentation is written in [ReStructured Text](https://docutils.sourceforge
44

55
## How to Generate:
66

7-
In the `docs/` folder, run
7+
In the project root, run
88

9-
composer update
9+
composer docs
1010

11-
Then compile the documentation with:
12-
13-
make html
14-
15-
This will generate the documentation into the `build` subdirectory.
11+
This will generate the documentation into the `docs/output` subdirectory.
1612

1713
To browse the documentation, you need to run a webserver:
1814

19-
cd build/html
15+
cd docs/output
2016
php -S localhost:8000
2117

2218
Now the documentation is available at [http://localhost:8000](http://localhost:8000).

docs/composer.json

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,7 @@
33
"description": "Documentation for the Object-Relational Mapper\"",
44
"type": "library",
55
"license": "MIT",
6-
"require": {
7-
"phpdocumentor/guides-cli": "1.7.1",
8-
"phpdocumentor/filesystem": "1.7.1"
6+
"require-dev": {
7+
"doctrine/docs-builder": "^1.0"
98
}
109
}

tests/Tests/ORM/Functional/Ticket/GH12174Test.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@ class GH12174Smurf
6161
* @ORM\Id
6262
* @ORM\GeneratedValue
6363
* @ORM\Column(type="integer")
64+
*
6465
* @var int
6566
*/
6667
#[ORM\Id]
@@ -70,13 +71,15 @@ class GH12174Smurf
7071

7172
/**
7273
* @ORM\ManyToOne(inversedBy="children", targetEntity="GH12174Smurf")
74+
*
7375
* @var GH12174Smurf
7476
*/
7577
#[ManyToOne(inversedBy: 'children')]
7678
private $parent;
7779

7880
/**
7981
* @ORM\OneToMany(targetEntity="GH12174Smurf", mappedBy="parent")
82+
*
8083
* @var Collection
8184
*/
8285
#[OneToMany(targetEntity: self::class, mappedBy: 'parent')]

0 commit comments

Comments
 (0)