This commit is contained in:
parent
d515bc0691
commit
0f0bbf077d
48
.drone.yml
Normal file
48
.drone.yml
Normal file
@ -0,0 +1,48 @@
|
|||||||
|
---
|
||||||
|
kind: pipeline
|
||||||
|
type: kubernetes
|
||||||
|
name: rename-server-build
|
||||||
|
platform:
|
||||||
|
os: linux
|
||||||
|
arch: arm64
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: build
|
||||||
|
image: docker.zvon.tech/cppbuilder:v0.09
|
||||||
|
commands:
|
||||||
|
- export CXX=g++
|
||||||
|
- cmake .
|
||||||
|
- cmake --build .
|
||||||
|
- name: coverage
|
||||||
|
image: docker.zvon.tech/cppbuilder:v0.09
|
||||||
|
commands:
|
||||||
|
- ./test
|
||||||
|
- "find . -type f -name \"*.gcno\" -execdir gcov -pb -r {} +"
|
||||||
|
- "gcovr --root . -k -j 2 --xml -o gcovr_report.xml --exclude-directories \"tests\""
|
||||||
|
- bash <(curl -Ls https://coverage.codacy.com/get.sh) report -r "gcovr_report.xml" --language CPP --force-language
|
||||||
|
environment:
|
||||||
|
CODACY_PROJECT_TOKEN:
|
||||||
|
from_secret: project_token
|
||||||
|
when:
|
||||||
|
status:
|
||||||
|
- success
|
||||||
|
- name: formatting-check
|
||||||
|
image: docker.zvon.tech/cppbuilder:v0.09
|
||||||
|
commands:
|
||||||
|
- find . -path "./build" -prune -or -path "./.cache" -prune -or -iname "*.cpp" -or -iname "*.hpp" -print | xargs -P0 -I{} clang-format -style=file --dry-run -Werror {}
|
||||||
|
when:
|
||||||
|
status:
|
||||||
|
- failure
|
||||||
|
- success
|
||||||
|
- name: notify
|
||||||
|
image: docker.zvon.tech/drone-email:v0.01
|
||||||
|
settings:
|
||||||
|
host: mail.zvon.tech
|
||||||
|
username:
|
||||||
|
from_secret: email_user
|
||||||
|
password:
|
||||||
|
from_secret: email_password
|
||||||
|
port: 465
|
||||||
|
from: Drone <drone@zvon.tech>
|
||||||
|
when:
|
||||||
|
status: [ changed, failure ]
|
Loading…
Reference in New Issue
Block a user