.drone.yml 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. ---
  2. kind: pipeline
  3. name: default
  4. steps:
  5. - name: scan-build
  6. image: debian:stretch
  7. pull: true
  8. commands:
  9. - apt-get update && apt-get install -yq build-essential autotools-dev lsb-release pkg-config automake autoconf libtool-bin clang-tools-4.0
  10. - apt-get install -yq cmake uuid-dev libssl1.0-dev
  11. - sed -i '/cotire/d' ./CMakeLists.txt
  12. - mkdir -p scan-build
  13. - scan-build-4.0 -o ./scan-build/ cmake .
  14. - echo '#!/bin/bash\nscan-build-4.0 -o ./scan-build/ make -j`nproc --all` |& tee ./scan-build-result.txt\nexitstatus=$${PIPESTATUS[0]}\necho $$exitstatus > ./scan-build-status.txt\n' > scan.sh
  15. - chmod +x scan.sh
  16. - ./scan.sh
  17. - exitstatus=`cat ./scan-build-status.txt`
  18. - echo "*** Exit status is $exitstatus"
  19. - name: notify
  20. image: signalwire/drone-notify
  21. pull: true
  22. environment:
  23. SLACK_WEBHOOK_URL:
  24. from_secret: slack_webhook_url
  25. ENV_FILE:
  26. from_secret: notify_env
  27. commands:
  28. - /root/scan-build-notify.sh
  29. trigger:
  30. branch:
  31. - master
  32. trigger:
  33. event:
  34. - pull_request
  35. - push
  36. ---
  37. kind: signature
  38. hmac: a6f0bb1ddbf48095fda5120398ac7b9acb2153c951569da32e3fb7a07b29d635
  39. ...