-
Notifications
You must be signed in to change notification settings - Fork 1
42 lines (40 loc) · 1.19 KB
/
doc.yaml
File metadata and controls
42 lines (40 loc) · 1.19 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
name: PHP Doc
on:
push:
tags:
- "*"
workflow_dispatch:
jobs:
doc:
runs-on: ubuntu-22.04
steps:
- name: Checkout code
uses: actions/checkout@v3
with:
token: ${{ secrets.WORKFLOW_PAT }}
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: "7.4"
- name: Download PHP Documentor v3.1.2
run: wget https://github.com/phpDocumentor/phpDocumentor/releases/download/v3.1.2/phpDocumentor.phar
- name: Run PHP Documentor
run: php phpDocumentor.phar -d src -t ./
- name: Configure git
run: |
git config --global user.email ops@ironcorelabs.com
git config --global user.name "Leeroy Travis"
- name: Commit and push changes to gh-pages branch
run: |
# Remove generated cache folder
rm -rf .phpdoc/
# Stash all the documentation changes we just made
git stash -u
git fetch -a
git checkout gh-pages
# Remove old documentation files
rm -rf *
git stash pop
git add .
git commit -m "Update docs for tag ${{ github.ref }}."
git push