mirror of
https://github.com/okalachev/flix.git
synced 2026-09-06 00:10:58 +00:00
Add additional files to website build
This commit is contained in:
@@ -26,15 +26,28 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: markdownlint
|
needs: markdownlint
|
||||||
env:
|
env:
|
||||||
BINARIES: ${{ github.event_name == 'push' && (github.ref_name == 'master' || github.ref_name == 'dev') && github.repository == 'okalachev/flix' }}
|
FULL: ${{ github.event_name == 'push' && (github.ref_name == 'master' || github.ref_name == 'dev') && github.repository == 'okalachev/flix' }}
|
||||||
|
QUADCOPTER_DEV_TOKEN: ${{ secrets.QUADCOPTER_DEV_TOKEN }}
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v7
|
- uses: actions/checkout@v7
|
||||||
- name: Install mdBook
|
- name: Install mdBook
|
||||||
run: cargo install mdbook --vers 0.4.43 --locked
|
run: cargo install mdbook --vers 0.4.43 --locked
|
||||||
- name: Build book
|
- name: Build book
|
||||||
run: cd docs && mdbook build
|
run: cd docs && mdbook build
|
||||||
|
- name: Download additional files
|
||||||
|
if: ${{ env.QUADCOPTER_DEV_TOKEN && env.FULL }}
|
||||||
|
uses: actions/checkout@v7
|
||||||
|
with:
|
||||||
|
repository: okalachev/quadcopter.dev
|
||||||
|
ref: content
|
||||||
|
token: ${{ secrets.QUADCOPTER_DEV_TOKEN }}
|
||||||
|
path: quadcopter.dev
|
||||||
|
fetch-depth: 1
|
||||||
|
- name: Add additional files to build
|
||||||
|
if: ${{ env.QUADCOPTER_DEV_TOKEN && env.FULL }}
|
||||||
|
run: cp -a -n quadcopter.dev/. docs/build/
|
||||||
- name: Wait for Build to complete
|
- name: Wait for Build to complete
|
||||||
if: ${{ env.BINARIES }}
|
if: ${{ env.FULL }}
|
||||||
uses: lewagon/wait-on-check-action@v1.9.1
|
uses: lewagon/wait-on-check-action@v1.9.1
|
||||||
with:
|
with:
|
||||||
ref: ${{ github.sha }}
|
ref: ${{ github.sha }}
|
||||||
@@ -42,7 +55,7 @@ jobs:
|
|||||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
wait-interval: 30
|
wait-interval: 30
|
||||||
- name: Find firmware binaries
|
- name: Find firmware binaries
|
||||||
if: ${{ env.BINARIES }}
|
if: ${{ env.FULL }}
|
||||||
id: build_run
|
id: build_run
|
||||||
run: |
|
run: |
|
||||||
RUN_ID=$(gh api "repos/${{ github.repository }}/actions/workflows/build.yml/runs?head_sha=${{ github.sha }}&per_page=1" --jq '.workflow_runs[0].id')
|
RUN_ID=$(gh api "repos/${{ github.repository }}/actions/workflows/build.yml/runs?head_sha=${{ github.sha }}&per_page=1" --jq '.workflow_runs[0].id')
|
||||||
@@ -50,7 +63,7 @@ jobs:
|
|||||||
env:
|
env:
|
||||||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
- name: Download firmware binaries
|
- name: Download firmware binaries
|
||||||
if: ${{ env.BINARIES }}
|
if: ${{ env.FULL }}
|
||||||
uses: actions/download-artifact@v7
|
uses: actions/download-artifact@v7
|
||||||
with:
|
with:
|
||||||
github-token: ${{ secrets.GITHUB_TOKEN }}
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
@@ -59,7 +72,7 @@ jobs:
|
|||||||
name: firmware-binary
|
name: firmware-binary
|
||||||
path: docs/build
|
path: docs/build
|
||||||
- name: Create shortcuts for firmware binaries
|
- name: Create shortcuts for firmware binaries
|
||||||
if: ${{ env.BINARIES }}
|
if: ${{ env.FULL }}
|
||||||
working-directory: docs/build
|
working-directory: docs/build
|
||||||
run: |
|
run: |
|
||||||
for FQBN in esp32.esp32.*; do
|
for FQBN in esp32.esp32.*; do
|
||||||
|
|||||||
Reference in New Issue
Block a user