Skip to content

Commit 257f690

Browse files
authored
Merge pull request #58 from answerdigital/modules-list
Fix logic for listing modules
2 parents 81c040d + e19098a commit 257f690

File tree

2 files changed

+3
-21
lines changed

2 files changed

+3
-21
lines changed

.github/dependabot.yml

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -41,24 +41,6 @@ updates:
4141
update-types:
4242
- "version-update:semver-patch"
4343
- "version-update:semver-minor"
44-
- package-ecosystem: terraform
45-
directory: /modules/aws/state_manager/test
46-
schedule:
47-
interval: daily
48-
ignore:
49-
- dependency-name: "*"
50-
update-types:
51-
- "version-update:semver-patch"
52-
- "version-update:semver-minor"
53-
- package-ecosystem: terraform
54-
directory: /modules/aws/state_manager/test/test-state
55-
schedule:
56-
interval: daily
57-
ignore:
58-
- dependency-name: "*"
59-
update-types:
60-
- "version-update:semver-patch"
61-
- "version-update:semver-minor"
6244
- package-ecosystem: terraform
6345
directory: /modules/aws/vpc
6446
schedule:

.github/workflows/terraform.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ jobs:
2323
- name: Output all modules
2424
id: output-all
2525
run: |
26-
JQ_OUTPUT_ALL=$(find modules/ -mindepth 2 -type d | jq -R -s -c 'split("\n")[:-1]')
26+
JQ_OUTPUT_ALL=$(find modules -mindepth 2 -maxdepth 2 -type d | jq -MRsc 'split("\n")[:-1]')
2727
echo "all_modules=$JQ_OUTPUT_ALL" >> $GITHUB_OUTPUT
2828
- name: Output changed modules
2929
if: ${{ github.event_name == 'pull_request' }}
@@ -32,7 +32,7 @@ jobs:
3232
BASE_SHA: ${{ github.event.pull_request.base.sha }}
3333
run: |
3434
JQ_OUTPUT_CHANGED=$(git diff --name-only $BASE_SHA $GITHUB_SHA modules/*/*/*.tf |
35-
cut -d/ -f1-3 | sort -u | jq -R -s -c 'split("\n")[:-1]')
35+
cut -d/ -f1-3 | sort -u | jq -MRsc 'split("\n")[:-1]')
3636
echo "changed_modules=$JQ_OUTPUT_CHANGED" >> $GITHUB_OUTPUT
3737
3838
terraform-check:
@@ -97,7 +97,7 @@ jobs:
9797
needs:
9898
- determine-modules
9999
- terraform-docs # to avoid race condition with both committing
100-
if: ${{ github.event_name == 'pull_request' }}
100+
if: ${{ always() && github.event_name == 'pull_request' }}
101101
steps:
102102
- name: Checkout
103103
uses: actions/checkout@v3

0 commit comments

Comments
 (0)