@@ -36,12 +36,12 @@ jobs:
36
36
id : setup-python
37
37
uses : actions/setup-python@v4
38
38
with :
39
- python-version : ' ${{ env.PYTHON_VERSION }}'
39
+ python-version : ' ${{ inputs.python_version }}'
40
40
41
41
- name : Install and configure Poetry
42
42
uses : snok/install-poetry@v1
43
43
with :
44
- version : ${{ env.POETRY_VERSION }}
44
+ version : ${{ inputs.poetry_version }}
45
45
virtualenvs-in-project : true
46
46
47
47
- name : Restore cached key
54
54
- name : Install jq
55
55
run : sudo apt-get update && sudo apt-get install -y jq
56
56
57
- - name : Check if AWS CodeArtifact is queryable and count repositories
58
- env :
59
- AWS_REGION : ${{ secrets.AWS_REGION }}
60
- run : |
61
- repo_count=$(aws codeartifact list-repositories --region $AWS_REGION --output json | jq '.repositories | length' 2>/dev/null) || { echo "Failed to query AWS CodeArtifact or an error occurred."; exit 0; }
62
- echo "Number of repositories in AWS CodeArtifact: $repo_count"
63
-
64
57
- name : Set env variables
65
58
env :
66
59
AWS_REGION : ${{ secrets.AWS_REGION }}
73
66
echo $VERSION > version.txt
74
67
echo "CURRENT_VERSION=$(cat version.txt)" >> $GITHUB_ENV
75
68
76
- - name : Check AWS CodeArtifact repository existence
77
- if : ${{ github.ref_name == 'master' }}
78
- env :
79
- AWS_REGION : ${{ secrets.AWS_REGION }}
80
- run : |
81
- if ! aws codeartifact list-repositories --region $AWS_REGION | grep -q "data-platform-data-diff"; then
82
- echo "AWS CodeArtifact repository 'data-platform-data-diff' does not exist."
83
- exit 0
84
- fi
85
-
86
69
- name : Check if version needs to be published
87
70
if : ${{ github.ref_name == 'master' }}
88
71
env :
0 commit comments