generated from amazon-archives/__template_Custom
-
Notifications
You must be signed in to change notification settings - Fork 96
45 lines (39 loc) · 1.24 KB
/
oelint-adv.yml
File metadata and controls
45 lines (39 loc) · 1.24 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
name: oelint-adv
on:
pull_request:
branches:
- '*-next'
merge_group:
jobs:
oelint-adv:
runs-on: ubuntu-22.04
steps:
- name: install required packages to run oelint_adv
run: |
sudo apt-get -y install python3-pip
sudo pip3 install oelint_adv
- name: checkout meta-aws branch to test
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: get changed bb files
id: changes
env:
PR_BASE_SHA: ${{ github.event.pull_request.base.sha }}
MERGE_GROUP_BASE_SHA: ${{ github.event.merge_group.base_sha }}
HEAD_SHA: ${{ github.sha }}
run: |
if [ -n "$PR_BASE_SHA" ]; then
BASE_SHA="$PR_BASE_SHA"
elif [ -n "$MERGE_GROUP_BASE_SHA" ]; then
BASE_SHA="$MERGE_GROUP_BASE_SHA"
else
echo "No base SHA found"
exit 1
fi
BB_FILES=$(git diff --name-only --diff-filter=ACMRT "$BASE_SHA" "$HEAD_SHA" | grep .bb | xargs)
echo "bb=$BB_FILES" >> $GITHUB_OUTPUT
- name: run oelint_adv
if: ${{steps.changes.outputs.bb}}
run: |
oelint-adv --nowarn --noinfo ${{steps.changes.outputs.bb}} --release scarthgap