forked from neos/flow-development-collection
-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'task/render-api-docs' into 8.2
# Conflicts: # Neos.Flow/Classes/Persistence/QueryInterface.php # Neos.Flow/Configuration/Settings.DocTools.yaml
- Loading branch information
Showing
6 changed files
with
80 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
<?php | ||
declare(strict_types=1); | ||
|
||
use Doctum\Doctum; | ||
use Doctum\RemoteRepository\GitHubRemoteRepository; | ||
use Symfony\Component\Finder\Finder; | ||
|
||
$iterator = Finder::create() | ||
->files() | ||
->name('*.php') | ||
->path('/Classes/') | ||
->in(__DIR__); | ||
|
||
return new Doctum($iterator, [ | ||
'title' => 'Flow Framework', | ||
'base_url' => 'https://neos.github.io/', | ||
'favicon' => 'https://www.neos.io/favicon-32x32.png', | ||
'language' => 'en', | ||
'remote_repository' => new GitHubRemoteRepository('neos/flow-development-collection', __DIR__), | ||
'footer_link' => [ | ||
'href' => 'https://flow.neos.io', | ||
'rel' => 'noreferrer noopener', | ||
'target' => '_blank', | ||
'before_text' => 'Learn more about the', | ||
'link_text' => 'Flow Framework', | ||
'after_text' => 'if you like!', | ||
] | ||
]); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
name: Build API documentation | ||
|
||
on: | ||
workflow_dispatch: | ||
push: | ||
branches: [ '[0-9]+.[0-9]' ] | ||
|
||
jobs: | ||
build-api-docs: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- name: Build API documentation | ||
uses: sudo-bot/action-doctum@v5 | ||
with: | ||
config-file: .doctum.php | ||
method: "update" | ||
# use of --only-version fixes branch name in "View source" links to GitHub | ||
cli-args: "--output-format=github --no-ansi --no-progress --ignore-parse-errors --only-version=${{ github.ref_name }}" | ||
|
||
- name: Check out documentation site | ||
uses: actions/checkout@v3 | ||
with: | ||
repository: neos/neos.github.io | ||
path: docs-site | ||
|
||
- name: Move rendered docs to site | ||
run: | | ||
rm -rf docs-site/flow/${{ github.ref_name }} | ||
mkdir -p docs-site/flow/${{ github.ref_name }} | ||
mv build/* docs-site/flow/${{ github.ref_name }}/ | ||
- name: Commit update | ||
run: | | ||
cd docs-site | ||
git config --local --unset-all "http.https://github.com/.extraheader" | ||
git config --global user.email "[email protected]" | ||
git config --global user.name "Neos Bot" | ||
git add . | ||
git commit -m "TASK: Update API docs from ${{ github.ref_name }}" | ||
- name: Push to git | ||
uses: ad-m/[email protected] | ||
with: | ||
github_token: ${{ secrets.NEOS_BOT_TOKEN }} | ||
repository: neos/neos.github.io | ||
directory: docs-site | ||
branch: main |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters