Skip to content

Commit 8ed55c5

Browse files
berfinyukselberfinyuksel
authored andcommitted
Use reusable documentation workflow (#1510)
* Use reusable documentation workflow and disable old docs workflow * Remove docs workflow backup files * Rename docs.yaml to docs.yaml.bak and update new-docs.yml --------- Co-authored-by: berfinyuksel <berfin.yuksel@gmail.com>
1 parent 96822e5 commit 8ed55c5

3 files changed

Lines changed: 103 additions & 67 deletions

File tree

.github/workflows/docs.yaml

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

.github/workflows/docs.yaml.bak

Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
# Original docs workflow disabled in favor of new-docs.yml
2+
# This file is kept only for reference. The active workflow is .github/workflows/new-docs.yml
3+
# Backup of the original content: .github/workflows/docs.yaml.bak
4+
5+
#
6+
# name: "Documentation"
7+
#
8+
# on:
9+
# pull_request_target:
10+
# types: [opened, closed, synchronize]
11+
# paths:
12+
# - 'doc/**'
13+
# - '.github/workflows/docs.yaml'
14+
# - 'README.md'
15+
# push:
16+
# branches:
17+
# - "[0-9]+.[0-9]+"
18+
# - "[0-9]+.x"
19+
# - "*_actions"
20+
# paths:
21+
# - 'doc/**'
22+
# - '.github/workflows/docs.yaml'
23+
# - 'README.md'
24+
#
25+
# permissions:
26+
# contents: read
27+
#
28+
# jobs:
29+
# docs:
30+
# name: "Generate docs Pimcore Docs Generator"
31+
# runs-on: "ubuntu-latest"
32+
# steps:
33+
# - name: "Checkout code"
34+
# uses: "actions/checkout@v4"
35+
#
36+
# - name: "Checkout Docs Generator"
37+
# uses: "actions/checkout@v4"
38+
# with:
39+
# repository: "pimcore/docs-generator"
40+
# ref: "main"
41+
# path: "./docs-generator"
42+
# token: ${{ secrets.DOCS_GENERATOR_ACCESS_TOKEN }}
43+
#
44+
# - name: "Install Node"
45+
# uses: actions/setup-node@v4
46+
# with:
47+
# node-version: 'lts/*'
48+
# registry-url: 'https://registry.npmjs.org'
49+
#
50+
# - name: Prepare Docs
51+
# working-directory: "./docs-generator"
52+
# run: |
53+
# mkdir docs
54+
# # copy docs to working directory
55+
# cp -r ../doc ./docs/
56+
#
57+
# # copy readme to working directory
58+
# cp -r ../README.md ./docs/
59+
#
60+
# # copy index page
61+
# cp bin/resources/00_index_empty.md ./docs/00_index.md
62+
#
63+
# # use special docusaurus config (to exclude search plugin) and check for broken links
64+
# mv docusaurus.config.js.repos-tests docusaurus.config.js
65+
#
66+
# - name: Build Docs
67+
# working-directory: "./docs-generator"
68+
# run: |
69+
# npm install
70+
# npm run build
71+
#

.github/workflows/new-docs.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: "Documentation (Reusable)"
2+
3+
on:
4+
pull_request_target:
5+
branches:
6+
- "[0-9]+.[0-9]+"
7+
- "[0-9]+.x"
8+
- "docs_actions"
9+
paths:
10+
- "doc/**"
11+
- ".github/workflows/new-docs.yml"
12+
- "README.md"
13+
push:
14+
branches:
15+
- "[0-9]+.[0-9]+"
16+
- "[0-9]+.x"
17+
- "docs_actions"
18+
paths:
19+
- "doc/**"
20+
- ".github/workflows/new-docs.yml"
21+
- "README.md"
22+
23+
permissions:
24+
contents: read
25+
26+
jobs:
27+
docs:
28+
uses: pimcore/workflows-collection-public/.github/workflows/reusable-docs.yaml@reusable-workflows
29+
with:
30+
docs_path: "doc"
31+
secrets:
32+
DOCS_GENERATOR_ACCESS_TOKEN: ${{ secrets.DOCS_GENERATOR_ACCESS_TOKEN }}

0 commit comments

Comments
 (0)