Skip to content

Commit a962dc9

Browse files
committed
github action file updates
1 parent b92a3f2 commit a962dc9

File tree

4 files changed

+44
-80
lines changed

4 files changed

+44
-80
lines changed

.github/workflows/bandit.yml

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,6 @@
11
name: Bandit
22

3-
on:
4-
workflow_dispatch:
5-
push:
6-
branches:
7-
- actions
8-
pull_request:
9-
branches:
10-
- main
3+
on: push
114

125
jobs:
136
build:

.github/workflows/cfn-nag.yml

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,6 @@
11
name: CFN Nag
22

3-
on:
4-
workflow_dispatch:
5-
push:
6-
branches:
7-
- actions
8-
pull_request:
9-
branches:
10-
- main
3+
on: push
114

125
jobs:
136
build:

.github/workflows/python-license-check.yml

Lines changed: 41 additions & 57 deletions
Original file line numberDiff line numberDiff line change
@@ -10,66 +10,50 @@ jobs:
1010
matrix:
1111
python-version: [3.9]
1212
steps:
13-
- uses: actions/checkout@v3
14-
- name: Set up Python ${{ matrix.python-version }}
13+
#----------------------------------------------
14+
# check-out repo and set-up python
15+
#----------------------------------------------
16+
- name: Check out repository
17+
uses: actions/checkout@v3
18+
- name: Set up python
19+
id: setup-python
1520
uses: actions/setup-python@v3
1621
with:
17-
python-version: ${{ matrix.python-version }}
22+
python-version: 3.9
23+
#----------------------------------------------
24+
# ----- install & configure poetry -----
25+
#----------------------------------------------
26+
- name: Load Cached Poetry Installation
27+
uses: actions/cache@v3
28+
with:
29+
path: ~/.local # the path depends on the OS
30+
key: poetry-no-dev-2 # increment to reset cache
1831
- name: Install Poetry
32+
uses: snok/install-poetry@v1
33+
with:
34+
virtualenvs-create: true
35+
virtualenvs-in-project: true
36+
installer-parallel: true
37+
#----------------------------------------------
38+
# load cached venv if cache exists
39+
#----------------------------------------------
40+
- name: Load cached venv
41+
id: cached-poetry-no-dev-dependencies
42+
uses: actions/cache@v3
43+
with:
44+
path: .venv
45+
key: venv-no-dev-depend-${{ runner.os }}-${{ steps.setup-python.outputs.python-version }}-${{ hashFiles('**/poetry.lock') }}
46+
#----------------------------------------------
47+
# install dependencies if cache does not exist
48+
#----------------------------------------------
49+
- name: Install dependencies
50+
if: steps.cached-poetry-no-dev-dependencies.outputs.cache-hit != 'true'
51+
run: poetry install --no-dev
52+
#----------------------------------------------
53+
# Run pylic check
54+
#----------------------------------------------
55+
- name: pylic check
1956
run: |
20-
python -m pip install --upgrade pip
21-
python -m pip install poetry
22-
poetry install --no-dev
23-
- name: Pylic License Check
24-
run: |
57+
poetry show
2558
poetry run pip install pylic
26-
ls -l
2759
poetry run pylic check
28-
# steps:
29-
# #----------------------------------------------
30-
# # check-out repo and set-up python
31-
# #----------------------------------------------
32-
# - name: Check out repository
33-
# uses: actions/checkout@v3
34-
# - name: Set up python
35-
# id: setup-python
36-
# uses: actions/setup-python@v3
37-
# with:
38-
# python-version: 3.9
39-
# #----------------------------------------------
40-
# # ----- install & configure poetry -----
41-
# #----------------------------------------------
42-
# - name: Load Cached Poetry Installation
43-
# uses: actions/cache@v3
44-
# with:
45-
# path: ~/.local # the path depends on the OS
46-
# key: poetry-no-dev-2 # increment to reset cache
47-
# - name: Install Poetry
48-
# uses: snok/install-poetry@v1
49-
# with:
50-
# virtualenvs-create: true
51-
# virtualenvs-in-project: true
52-
# installer-parallel: true
53-
# #----------------------------------------------
54-
# # load cached venv if cache exists
55-
# #----------------------------------------------
56-
# - name: Load cached venv
57-
# id: cached-poetry-no-dev-dependencies
58-
# uses: actions/cache@v3
59-
# with:
60-
# path: .venv
61-
# key: venv-no-dev-depend-${{ runner.os }}-${{ steps.setup-python.outputs.python-version }}-${{ hashFiles('**/poetry.lock') }}
62-
# #----------------------------------------------
63-
# # install dependencies if cache does not exist
64-
# #----------------------------------------------
65-
# - name: Install dependencies
66-
# if: steps.cached-poetry-no-dev-dependencies.outputs.cache-hit != 'true'
67-
# run: poetry install --no-dev
68-
# #----------------------------------------------
69-
# # Run pylic check
70-
# #----------------------------------------------
71-
# - name: pylic check
72-
# run: |
73-
# poetry install --no-dev
74-
# poetry run pip install pylic
75-
# poetry run pylic check

.github/workflows/static-checking.yml

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,6 @@
11
name: Static Checking with Linters
22

3-
on:
4-
push:
5-
branches:
6-
- actions
7-
pull_request:
8-
branches:
9-
- main
3+
on: push
104

115
jobs:
126
Linting:

0 commit comments

Comments
 (0)