1
- name : Generate Docs and Update Documentation Repository
1
+ name : Generate and Update API Docs
2
2
3
3
on :
4
- push :
5
4
workflow_dispatch : # Allow manual triggering
5
+ release :
6
+ types : [published] # Runs when release is published
6
7
7
8
jobs :
8
9
update-docs :
19
20
with :
20
21
python-version : ' 3.12'
21
22
23
+
24
+ - name : Clone C/C
25
+ uses : GuillaumeFalourd/clone-github-repo-action@v2.3
26
+ with :
27
+ branch : ' 3.4'
28
+ owner : ' mariadb-corporation'
29
+ repository : ' mariadb-connector-c'
30
+
31
+ - name : c/c make ubuntu
32
+ run : |
33
+ cd ${{ github.workspace }}/mariadb-connector-c
34
+ cmake . -DCMAKE_BUILD_TYPE=Release -DWITH_EXTERNAL_ZLIB=On -DCMAKE_INSTALL_PREFIX=/usr
35
+ make -j4
36
+ sudo make install
37
+ echo "MARIADB_PLUGIN_DIR=`mariadb_config --plugindir`" >> $GITHUB_ENV
38
+ echo "LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/lib/mariadb" >> $GITHUB_ENV
39
+
40
+
22
41
- name : Install dependencies
23
42
run : |
24
43
# Install your project dependencies
@@ -32,26 +51,27 @@ jobs:
32
51
- name : Checkout documentation repository
33
52
uses : actions/checkout@v4
34
53
with :
35
- repository : rusher /mariadb-docs # Replace with actual repo
36
- token : ${{ secrets.DOCS_REPO_TOKEN }}
37
- path : docs-repo
54
+ repository : mariadb-corporation /mariadb-docs # Replace with actual repo
55
+ token : ${{ secrets.SPHINX_TOKEN }}
56
+ path : mariadb-docs
38
57
39
58
- name : Update documentation subdirectory
40
59
run : |
41
60
# Remove existing documentation in target subdirectory
42
- rm -rf docs-repo/mariadb-docs/connectors/mariadb-connector-python/api/*
43
61
62
+ mkdir -p mariadb-docs/connectors/mariadb-connector-python/api/
63
+ rm -rf mariadb-docs/connectors/mariadb-connector-python/api/*
44
64
# Copy new documentation
45
- cp -r docs/_build/markdown/* docs-repo/ mariadb-docs/connectors/mariadb-connector-python/api/
65
+ cp -r docs/_build/markdown/* mariadb-docs/connectors/mariadb-connector-python/api/
46
66
47
67
# Optional: Add any additional processing here
48
68
# e.g., update index files, fix relative links, etc.
49
69
50
70
- name : Create Pull Request
51
71
uses : peter-evans/create-pull-request@v5
52
72
with :
53
- token : ${{ secrets.DOCS_REPO_TOKEN }}
54
- path : docs-repo
73
+ token : ${{ secrets.SPHINX_TOKEN }}
74
+ path : mariadb-docs
55
75
commit-message : " Update API documentation from ${{ github.repository }}"
56
76
title : " Auto-update: API Documentation from ${{ github.repository }}"
57
77
body : |
0 commit comments