mirror of
https://github.com/qmk/qmk_firmware.git
synced 2025-03-04 02:41:10 +00:00
update github workflow for docusaurus
This commit is contained in:
parent
d2c755c3dd
commit
29f2e9f19a
17
.github/workflows/docs.yml
vendored
17
.github/workflows/docs.yml
vendored
@ -27,20 +27,33 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
fetch-depth: 1
|
fetch-depth: 1
|
||||||
|
|
||||||
|
- uses: actions/setup-node@v3
|
||||||
|
with:
|
||||||
|
node-version: 16
|
||||||
|
cache: yarn
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: |
|
run: |
|
||||||
apt-get update && apt-get install -y rsync nodejs npm doxygen
|
apt-get update && apt-get install -y rsync nodejs npm doxygen
|
||||||
npm install -g moxygen
|
npm install -g moxygen
|
||||||
|
|
||||||
- name: Build docs
|
- name: Build doxygen docs
|
||||||
run: |
|
run: |
|
||||||
qmk --verbose generate-docs
|
qmk --verbose generate-docs
|
||||||
|
|
||||||
|
- name: Install yarn dependencies
|
||||||
|
working-directory: .build/docs
|
||||||
|
run: yarn install --frozen-lockfile
|
||||||
|
|
||||||
|
- name: Build Docusaurus
|
||||||
|
working-directory: .build/docs
|
||||||
|
run: yarn build
|
||||||
|
|
||||||
- name: Deploy
|
- name: Deploy
|
||||||
uses: JamesIves/github-pages-deploy-action@v4.4.1
|
uses: JamesIves/github-pages-deploy-action@v4.4.1
|
||||||
with:
|
with:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
BASE_BRANCH: master
|
BASE_BRANCH: master
|
||||||
BRANCH: gh-pages
|
BRANCH: gh-pages
|
||||||
FOLDER: .build/docs
|
FOLDER: .build/docs/build
|
||||||
GIT_CONFIG_EMAIL: hello@qmk.fm
|
GIT_CONFIG_EMAIL: hello@qmk.fm
|
||||||
|
4
docs/package-lock.json
generated
4
docs/package-lock.json
generated
@ -1,11 +1,11 @@
|
|||||||
{
|
{
|
||||||
"name": "test",
|
"name": "qmk_firmware_docs",
|
||||||
"version": "0.0.0",
|
"version": "0.0.0",
|
||||||
"lockfileVersion": 3,
|
"lockfileVersion": 3,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"packages": {
|
"packages": {
|
||||||
"": {
|
"": {
|
||||||
"name": "test",
|
"name": "qmk_firmware_docs",
|
||||||
"version": "0.0.0",
|
"version": "0.0.0",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@docusaurus/core": "2.4.0",
|
"@docusaurus/core": "2.4.0",
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
"name": "test",
|
"name": "qmk_firmware_docs",
|
||||||
"version": "0.0.0",
|
"version": "0.0.0",
|
||||||
"private": true,
|
"private": true,
|
||||||
"scripts": {
|
"scripts": {
|
||||||
|
@ -26,7 +26,8 @@ def generate_docs(cli):
|
|||||||
if DOXYGEN_PATH.exists():
|
if DOXYGEN_PATH.exists():
|
||||||
shutil.rmtree(DOXYGEN_PATH)
|
shutil.rmtree(DOXYGEN_PATH)
|
||||||
|
|
||||||
shutil.copytree(DOCS_PATH, BUILD_DOCS_PATH)
|
# ignore node_modules when we're testing locally
|
||||||
|
shutil.copytree(DOCS_PATH, BUILD_DOCS_PATH, ignore=shutil.ignore_patterns("node_modules"))
|
||||||
|
|
||||||
# When not verbose we want to hide all output
|
# When not verbose we want to hide all output
|
||||||
args = {
|
args = {
|
||||||
|
Loading…
Reference in New Issue
Block a user