.drone.yml 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. ---
  2. kind: pipeline
  3. name: default
  4. steps:
  5. - name: scan-build
  6. image: debian:buster
  7. pull: always
  8. commands:
  9. - apt-get update && apt-get install -yq build-essential autotools-dev lsb-release pkg-config automake autoconf libtool-bin clang-tools-7
  10. - apt-get install -yq cmake uuid-dev libssl-dev
  11. - sed -i '/cotire/d' ./CMakeLists.txt
  12. - mkdir -p scan-build
  13. - scan-build-7 -o ./scan-build/ cmake .
  14. - echo '#!/bin/bash\nscan-build-7 -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: always
  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. - v2.0
  33. trigger:
  34. event:
  35. - pull_request
  36. - push
  37. ---
  38. kind: signature
  39. hmac: b5f3149fdddd80d6162b2c1bda737d5c1d19ce7b0b1769798607dc670a90e85c
  40. ...