qBittorrent/.github/workflows/coverity-scan.yml
xavier2k6 b740cc23d3
GHA CI: Update dependencies
Update `libtorrent` version(s) to `2.0.6` & `1.2.16` in `GHA CI`
- https://github.com/arvidn/libtorrent/releases/tag/v2.0.6
- https://github.com/arvidn/libtorrent/releases/tag/v1.2.16

Update `Boost` version to `1.79.0`
- https://www.boost.org/users/history/version_1_79_0.html

Bump `pre-commit-hooks` version to `4.2.0`
- https://github.com/pre-commit/pre-commit-hooks/releases/tag/v4.2.0

Update `Qt6` version to `6.3.0`
- https://www.qt.io/blog/qt-6.3-released
- https://code.qt.io/cgit/qt/qtreleasenotes.git/about/qt/6.3.0/release-note.md

Note: used `aqtinstall 2.1.0` with `jurplel/install-qt-action` for support of `Qt 6.2.1+`
(this requirement can be removed on official release of `jurplel/install-qt-action v3`)

PR #16888.
2022-04-19 10:32:56 +08:00

74 lines
2.2 KiB
YAML

name: Coverity Scan
on:
schedule:
- cron: '0 0 1 * *' # Monthly (1st day of month at midnight)
workflow_dispatch: # Mainly for testing. Don't forget the Coverity usage limits.
jobs:
coverity_scan:
name: Scan
runs-on: ubuntu-20.04
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Install dependencies
run: |
sudo apt update
sudo apt install \
build-essential cmake ninja-build pkg-config \
libboost-dev libssl-dev zlib1g-dev
- name: Install Qt
uses: jurplel/install-qt-action@v2
with:
version: "5.15.2"
- name: Install libtorrent
run: |
git clone \
--branch "v2.0.6" \
--depth 1 \
--recurse-submodules \
https://github.com/arvidn/libtorrent.git
cd libtorrent
cmake \
-B build \
-G "Ninja" \
-DCMAKE_BUILD_TYPE=RelWithDebInfo \
-Ddeprecated-functions=OFF
cmake --build build
sudo cmake --install build
- name: Download Coverity Build Tool
run: |
wget \
-q \
https://scan.coverity.com/download/linux64 \
--post-data "token=${{ secrets.COVERITY_SCAN_TOKEN }}&project=qbittorrent%2FqBittorrent" \
-O coverity_tool.tgz
mkdir coverity_tool
tar xzf coverity_tool.tgz --strip 1 -C coverity_tool
- name: Build qBittorrent
run: |
cmake \
-B build \
-G "Ninja" \
-DCMAKE_BUILD_TYPE=RelWithDebInfo \
-DGUI=ON \
-DVERBOSE_CONFIGURE=ON
export PATH="$(pwd)/coverity_tool/bin:$PATH"
cov-build --dir cov-int cmake --build build
- name: Submit the result to Coverity Scan
run: |
tar caf qbittorrent.xz cov-int
curl \
--form token="${{ secrets.COVERITY_SCAN_TOKEN }}" \
--form email=sledgehammer999@qbittorrent.org \
--form file=@qbittorrent.xz \
--form version="$(git rev-parse --short HEAD)" \
--form description="master" \
https://scan.coverity.com/builds?project=qbittorrent%2FqBittorrent