forked from netty/netty
-
Notifications
You must be signed in to change notification settings - Fork 0
86 lines (73 loc) · 2.75 KB
/
Copy pathcodeql-analysis.yml
File metadata and controls
86 lines (73 loc) · 2.75 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
# ----------------------------------------------------------------------------
# Copyright 2021 The Netty Project
#
# The Netty Project licenses this file to you under the Apache License,
# version 2.0 (the "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at:
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
# ----------------------------------------------------------------------------
name: "CodeQL"
on:
push:
branches: ["4.1", "4.2"]
pull_request:
# The branches below must be a subset of the branches above
branches: ["4.1", "4.2"]
schedule:
- cron: '0 13 * * 3'
env:
MAVEN_OPTS: -Xmx6g -Dhttp.keepAlive=false -Dmaven.wagon.http.pool=false -Dmaven.wagon.http.retryhandler.count=5 -Dmaven.wagon.httpconnectionManager.ttlSeconds=240
permissions:
contents: read
security-events: write
# Cancel running jobs when a new push happens to the same branch as otherwise it will
# tie up too many resources without providing much value.
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
# Override automatic language detection by changing the below list
# Supported options are ['csharp', 'cpp', 'go', 'java', 'javascript', 'python']
language: [ 'java', 'cpp' ]
steps:
- name: Checkout repository
uses: actions/checkout@v5
- name: Cache local Maven repository
uses: actions/cache@v4
continue-on-error: true
with:
path: ~/.m2/repository
key: cache-maven-${{ hashFiles('**/pom.xml') }}
restore-keys: |
cache-maven-${{ hashFiles('**/pom.xml') }}
cache-maven-
- name: Setup Java
uses: actions/setup-java@v5
with:
distribution: 'zulu'
java-version: '11'
- name: Initialize CodeQL
uses: github/codeql-action/init@v3
with:
tools: linked
build-mode: manual
languages: ${{ matrix.language }}
- name: Install tools / libraries
run: sudo apt-get update && sudo apt-get -y install autoconf automake libtool make tar cmake perl ninja-build git cargo
- name: Compile project
run: ./mvnw -B -ntp clean package -DskipTests=true
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3