2023-08-05 13:53:25 +00:00
|
|
|
---
|
|
|
|
kind: pipeline
|
|
|
|
type: docker
|
|
|
|
name: default
|
|
|
|
|
|
|
|
steps:
|
2023-08-05 15:22:46 +00:00
|
|
|
- name: build
|
2023-08-05 13:53:25 +00:00
|
|
|
image: ghcr.io/rikorose/gcc-cmake
|
|
|
|
commands:
|
|
|
|
- mkdir build && cd build
|
2023-08-05 15:28:48 +00:00
|
|
|
- cmake -DCMAKE_BUILD_TYPE=Release ..
|
2023-08-05 15:22:46 +00:00
|
|
|
- make
|
2023-08-05 15:20:34 +00:00
|
|
|
- name: docs
|
|
|
|
image: docker.io/corentinaltepe/doxygen
|
|
|
|
commands:
|
2023-08-05 15:22:46 +00:00
|
|
|
- doxygen
|
|
|
|
- ls docs
|
2023-08-05 15:28:48 +00:00
|
|
|
depends_on:
|
|
|
|
- build
|
|
|
|
- name: rebuild-cache
|
|
|
|
image: drillster/drone-volume-cache
|
|
|
|
volumes:
|
|
|
|
- name: cache
|
|
|
|
path: /cache
|
|
|
|
settings:
|
|
|
|
rebuild: true
|
|
|
|
mount:
|
|
|
|
- ./docs/html
|
|
|
|
depends_on:
|
|
|
|
- docs
|
|
|
|
|
|
|
|
volumes:
|
|
|
|
- name: cache
|
|
|
|
host:
|
|
|
|
path: /tmp/cache
|
|
|
|
|
|
|
|
---
|
|
|
|
kind: pipeline
|
|
|
|
type: docker
|
|
|
|
name: deploy-docs
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- name: restore-cache
|
|
|
|
image: drillster/drone-volume-cache
|
|
|
|
volumes:
|
|
|
|
- name: cache
|
|
|
|
path: /cache
|
|
|
|
settings:
|
|
|
|
restore: true
|
|
|
|
mount:
|
|
|
|
- ./docs/html
|
|
|
|
- name: prepare-pages
|
|
|
|
image: bitnami/git
|
|
|
|
volumes:
|
|
|
|
- name: cache
|
|
|
|
path: /cache
|
|
|
|
commands:
|
|
|
|
- ls -la
|
2023-08-05 16:02:03 +00:00
|
|
|
- git pull
|
2023-08-05 15:59:48 +00:00
|
|
|
- git checkout pages
|
|
|
|
- shopt -s extglob; rm -rf !(.git)
|
|
|
|
- ls -la
|
2023-08-05 15:28:48 +00:00
|
|
|
depends_on:
|
|
|
|
- restore-cache
|
2023-08-05 15:59:48 +00:00
|
|
|
# - name: deploy-pages
|
|
|
|
# image: appleboy/drone-git-push
|
|
|
|
# volumes:
|
|
|
|
# - name: pages
|
|
|
|
# path: /tmp/pages
|
|
|
|
# settings:
|
|
|
|
# remote:
|
|
|
|
# from_secret: deploy_remote
|
|
|
|
# force: false
|
|
|
|
# commit: true
|
|
|
|
# commit_message: "[CI] Deploy pages"
|
|
|
|
# branch: pages
|
|
|
|
# local_ref: pages
|
|
|
|
# path: /tmp/pages
|
|
|
|
# depends_on:
|
|
|
|
# - prepare-pages
|
2023-08-05 15:28:48 +00:00
|
|
|
|
|
|
|
volumes:
|
|
|
|
- name: cache
|
|
|
|
host:
|
|
|
|
path: /tmp/cache
|
|
|
|
|
|
|
|
depends_on:
|
|
|
|
- default
|
|
|
|
|
|
|
|
trigger:
|
|
|
|
branch:
|
|
|
|
- main
|
|
|
|
event:
|
|
|
|
- push
|
|
|
|
- promote
|