mirror of
https://github.com/vim/vim.git
synced 2025-10-14 07:04:10 -04:00
patch 9.0.0946: CI: Error in Coverity flow is not reported
Problem: CI: Error in Coverity flow is not reported. Solution: Use another way to avoid errors in a forked repository. (Ken Takata, closes #11609)
This commit is contained in:
25
.github/workflows/coverity.yml
vendored
25
.github/workflows/coverity.yml
vendored
@@ -15,21 +15,22 @@ jobs:
|
|||||||
CC: gcc
|
CC: gcc
|
||||||
CFLAGS: -Wno-deprecated-declarations
|
CFLAGS: -Wno-deprecated-declarations
|
||||||
DEBIAN_FRONTEND: noninteractive
|
DEBIAN_FRONTEND: noninteractive
|
||||||
|
TOKEN: ${{ secrets.COVERITY_SCAN_TOKEN }}
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout repository from github
|
- name: Checkout repository from github
|
||||||
|
if: env.TOKEN
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
|
|
||||||
- name: Download Coverity
|
- name: Download Coverity
|
||||||
|
if: env.TOKEN
|
||||||
run: |
|
run: |
|
||||||
# probably no TOKEN if it was a forked repo
|
wget -q https://scan.coverity.com/download/cxx/linux64 --post-data "token=$TOKEN&project=vim" -O coverity_tool.tgz
|
||||||
[ -n "${TOKEN}" ] && wget -q https://scan.coverity.com/download/cxx/linux64 --post-data "token=$TOKEN&project=vim" -O coverity_tool.tgz || exit 0
|
|
||||||
mkdir cov-scan
|
mkdir cov-scan
|
||||||
tar ax -f coverity_tool.tgz --strip-components=1 -C cov-scan
|
tar ax -f coverity_tool.tgz --strip-components=1 -C cov-scan
|
||||||
env:
|
|
||||||
TOKEN: ${{ secrets.COVERITY_SCAN_TOKEN }}
|
|
||||||
|
|
||||||
- name: Install packages
|
- name: Install packages
|
||||||
|
if: env.TOKEN
|
||||||
run: |
|
run: |
|
||||||
sudo apt update && sudo apt install -y \
|
sudo apt update && sudo apt install -y \
|
||||||
autoconf \
|
autoconf \
|
||||||
@@ -48,6 +49,7 @@ jobs:
|
|||||||
libsodium-dev
|
libsodium-dev
|
||||||
|
|
||||||
- name: Set up environment
|
- name: Set up environment
|
||||||
|
if: env.TOKEN
|
||||||
run: |
|
run: |
|
||||||
echo "$(pwd)/cov-scan/bin" >> $GITHUB_PATH
|
echo "$(pwd)/cov-scan/bin" >> $GITHUB_PATH
|
||||||
(
|
(
|
||||||
@@ -56,6 +58,7 @@ jobs:
|
|||||||
) >> $GITHUB_ENV
|
) >> $GITHUB_ENV
|
||||||
|
|
||||||
- name: Configure
|
- name: Configure
|
||||||
|
if: env.TOKEN
|
||||||
run: |
|
run: |
|
||||||
./configure --with-features=huge ${CONFOPT} --enable-fail-if-missing
|
./configure --with-features=huge ${CONFOPT} --enable-fail-if-missing
|
||||||
# Append various warning flags to CFLAGS.
|
# Append various warning flags to CFLAGS.
|
||||||
@@ -63,21 +66,19 @@ jobs:
|
|||||||
sed -i -f ci/config.mk.${CC}.sed src/auto/config.mk
|
sed -i -f ci/config.mk.${CC}.sed src/auto/config.mk
|
||||||
|
|
||||||
- name: Build/scan vim
|
- name: Build/scan vim
|
||||||
|
if: env.TOKEN
|
||||||
run: |
|
run: |
|
||||||
# if no 'cov-build' there, then just cancel the process
|
cov-build --dir cov-int make -j${NPROC}
|
||||||
[ -x "$(which cov-build)" ] && cov-build --dir cov-int make -j${NPROC} || exit 0
|
|
||||||
|
|
||||||
- name: Submit results
|
- name: Submit results
|
||||||
|
if: env.TOKEN
|
||||||
run: |
|
run: |
|
||||||
[ -d 'cov-int' ] && tar zcf cov-scan.tgz cov-int
|
tar zcf cov-scan.tgz cov-int
|
||||||
[ -n "${TOKEN}" ] \
|
curl --form token=$TOKEN \
|
||||||
&& curl --form token=$TOKEN \
|
|
||||||
--form email=$EMAIL \
|
--form email=$EMAIL \
|
||||||
--form file=@cov-scan.tgz \
|
--form file=@cov-scan.tgz \
|
||||||
--form version="$(git rev-parse HEAD)" \
|
--form version="$(git rev-parse HEAD)" \
|
||||||
--form description="Automatic GHA scan" \
|
--form description="Automatic GHA scan" \
|
||||||
'https://scan.coverity.com/builds?project=vim' \
|
'https://scan.coverity.com/builds?project=vim'
|
||||||
|| exit 0
|
|
||||||
env:
|
env:
|
||||||
TOKEN: ${{ secrets.COVERITY_SCAN_TOKEN }}
|
|
||||||
EMAIL: ${{ secrets.COVERITY_SCAN_EMAIL }}
|
EMAIL: ${{ secrets.COVERITY_SCAN_EMAIL }}
|
||||||
|
@@ -695,6 +695,8 @@ static char *(features[]) =
|
|||||||
|
|
||||||
static int included_patches[] =
|
static int included_patches[] =
|
||||||
{ /* Add new patch number below this line */
|
{ /* Add new patch number below this line */
|
||||||
|
/**/
|
||||||
|
946,
|
||||||
/**/
|
/**/
|
||||||
945,
|
945,
|
||||||
/**/
|
/**/
|
||||||
|
Reference in New Issue
Block a user