Skip to content

Commit 57a54e9

Browse files
authored
Merge branch 'main' into aea-0000-optimise-qc
2 parents 785a628 + 55dba96 commit 57a54e9

22 files changed

+960
-1142
lines changed

.github/workflows/cdk_package_code.yml

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -22,23 +22,22 @@ jobs:
2222
packages: read
2323
steps:
2424
- name: Checkout code
25-
uses: actions/checkout@v5
25+
uses: actions/checkout@93cb6efe18208431cddfb8368fd83d5badbf9bfd
2626
with:
2727
ref: ${{ env.BRANCH_NAME }}
2828

2929
- name: Get asdf version
3030
id: asdf-version
3131
run: echo "version=$(awk '!/^#/ && NF {print $1; exit}' .tool-versions.asdf)" >> "$GITHUB_OUTPUT"
3232

33-
3433
# using git commit sha for version of action to ensure we have stable version
3534
- name: Install asdf
3635
uses: asdf-vm/actions/setup@1902764435ca0dd2f3388eea723a4f92a4eb8302
3736
with:
3837
asdf_version: ${{ steps.asdf-version.outputs.version }}
3938

4039
- name: Cache asdf
41-
uses: actions/cache@v4
40+
uses: actions/cache@0057852bfaa89a56745cba8c7296529d2fc39830
4241
with:
4342
path: |
4443
~/.asdf
@@ -67,16 +66,18 @@ jobs:
6766
6867
- name: Build Python Lambda Functions
6968
run: |
70-
poetry export --without-hashes --format=requirements.txt --with slackBotFunction > requirements_slackBotFunction
71-
poetry export --without-hashes --format=requirements.txt --with syncKnowledgeBaseFunction > requirements_syncKnowledgeBaseFunction
72-
if [ ! -s requirements_slackBotFunction ]; then \
73-
echo "Error: requirements_slackBotFunction is empty or missing"; \
69+
poetry show --only=slackBotFunction | grep -E "^[a-zA-Z]" | awk '{print $1"=="$2}' > requirements_slackBotFunction
70+
poetry show --only=syncKnowledgeBaseFunction | grep -E "^[a-zA-Z]" | awk '{print $1"=="$2}' > requirements_syncKnowledgeBaseFunction
71+
if [ ! -s requirements_slackBotFunction ] || [ "$(grep -c -v '^[[:space:]]*$' requirements_slackBotFunction)" -eq 0 ]; then \
72+
echo "Error: requirements_slackBotFunction is empty or contains only blank lines"; \
7473
exit 1; \
7574
fi
76-
if [ ! -s requirements_syncKnowledgeBaseFunction ]; then \
77-
echo "Error: requirements_syncKnowledgeBaseFunction is empty or missing"; \
75+
if [ ! -s requirements_syncKnowledgeBaseFunction ] || [ "$(grep -c -v '^[[:space:]]*$' requirements_syncKnowledgeBaseFunction)" -eq 0 ]; then \
76+
echo "Error: requirements_syncKnowledgeBaseFunction is empty or contains only blank lines"; \
7877
exit 1; \
7978
fi
79+
mkdir -p .dependencies/slackBotFunction/python
80+
mkdir -p .dependencies/syncKnowledgeBaseFunction/python
8081
pip3 install -r requirements_slackBotFunction -t .dependencies/slackBotFunction/python
8182
pip3 install -r requirements_syncKnowledgeBaseFunction -t .dependencies/syncKnowledgeBaseFunction/python
8283

.github/workflows/ci.yml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
tag_format: ${{ steps.load-config.outputs.TAG_FORMAT }}
1616
steps:
1717
- name: Checkout code
18-
uses: actions/checkout@v5
18+
uses: actions/checkout@93cb6efe18208431cddfb8368fd83d5badbf9bfd
1919

2020
- name: Get asdf version
2121
id: asdf-version
@@ -28,13 +28,16 @@ jobs:
2828
echo "TAG_FORMAT=$TAG_FORMAT" >> "$GITHUB_OUTPUT"
2929
3030
quality_checks:
31-
uses: NHSDigital/eps-workflow-quality-checks/.github/workflows/[email protected]
31+
uses: NHSDigital/eps-common-workflows/.github/workflows/quality-checks.yml@a7daff06de7b695f601d9b1723ca184daca7d898
32+
needs: [get_asdf_version]
33+
with:
34+
asdfVersion: ${{ needs.get_asdf_version.outputs.asdf_version }}
3235
secrets:
3336
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
3437

3538
tag_release:
3639
needs: [quality_checks, get_asdf_version]
37-
uses: NHSDigital/eps-workflow-semantic-release/.github/workflows/tag-release.yml@f3d071da30cd01dc0e4472ac0e2d7452db78d1c7
40+
uses: NHSDigital/eps-common-workflows/.github/workflows/tag-release.yml@a7daff06de7b695f601d9b1723ca184daca7d898
3841
with:
3942
dry_run: true
4043
asdfVersion: ${{ needs.get_asdf_version.outputs.asdf_version }}

.github/workflows/combine-dependabot-prs.yml

Lines changed: 0 additions & 151 deletions
This file was deleted.

.github/workflows/create_release_notes.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ jobs:
4040
contents: write
4141
steps:
4242
- name: Checkout local github actions
43-
uses: actions/checkout@v5
43+
uses: actions/checkout@93cb6efe18208431cddfb8368fd83d5badbf9bfd
4444
with:
4545
ref: ${{ env.BRANCH_NAME }}
4646
fetch-depth: 0

.github/workflows/delete_old_cloudformation_stacks.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,14 +19,14 @@ jobs:
1919
# Steps represent a sequence of tasks that will be executed as part of the job
2020
steps:
2121
- name: Checkout local github scripts
22-
uses: actions/checkout@v5
22+
uses: actions/checkout@93cb6efe18208431cddfb8368fd83d5badbf9bfd
2323
with:
2424
ref: ${{ env.BRANCH_NAME }}
2525
sparse-checkout: |
2626
.github/scripts
2727
2828
- name: Configure AWS Credentials
29-
uses: aws-actions/configure-aws-credentials@v5
29+
uses: aws-actions/configure-aws-credentials@00943011d9042930efac3dcd3a170e4273319bc8
3030
with:
3131
aws-region: eu-west-2
3232
role-to-assume: ${{ secrets.DEV_CLOUD_FORMATION_DEPLOY_ROLE }}

.github/workflows/dependabot_auto_approve_and_merge.yml

Lines changed: 0 additions & 49 deletions
This file was deleted.

.github/workflows/pr-link.yml

Lines changed: 0 additions & 46 deletions
This file was deleted.

.github/workflows/pr_title_check.yml

Lines changed: 0 additions & 33 deletions
This file was deleted.

0 commit comments

Comments
 (0)