Skip to content

Commit 3bb9bc9

Browse files
authored
2 parents e57cc79 + 0e06457 commit 3bb9bc9

File tree

690 files changed

+857739
-36614
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

690 files changed

+857739
-36614
lines changed

.github/ISSUE_TEMPLATE/bug-report.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ body:
1212
1313
**⚠️ Please read this before filling out the form below:**
1414
If the bug you are reporting is a security-related issue or a security vulnerability,
15-
please report it via [Report a security vulnerability](https://github.com/aws/aws-cdk/security/advisories/new) instead of this template.
15+
please report it via [Report a security vulnerability](https://github.com/aws/aws-cdk/security/policy) instead of this template.
1616
- type: textarea
1717
id: description
1818
attributes:

.github/codeql/codeql-config.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# example: https://github.com/github/codeql-action/blob/main/.github/codeql/codeql-config.yml
2+
name: "CodeQL config"
3+
paths-ignore:
4+
- '**/*.snapshot/**/asset*/index.js'

.github/dependabot.yml

Lines changed: 0 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -11,33 +11,3 @@ updates:
1111
labels:
1212
- "auto-approve"
1313
open-pull-requests-limit: 5
14-
- package-ecosystem: "pip"
15-
directory: "/packages/@aws-cdk/lambda-layer-awscli"
16-
schedule:
17-
interval: "weekly"
18-
labels:
19-
- "auto-approve"
20-
open-pull-requests-limit: 5
21-
22-
# Non-TypeScript init template dependency updates
23-
- package-ecosystem: "pip"
24-
directory: "/packages/aws-cdk/lib/init-templates"
25-
schedule:
26-
interval: "weekly"
27-
labels:
28-
- "auto-approve"
29-
open-pull-requests-limit: 5
30-
- package-ecosystem: "maven"
31-
directory: "/packages/aws-cdk/lib/init-templates"
32-
schedule:
33-
interval: "weekly"
34-
labels:
35-
- "auto-approve"
36-
open-pull-requests-limit: 5
37-
- package-ecosystem: "nuget"
38-
directory: "/packages/aws-cdk/lib/init-templates"
39-
schedule:
40-
interval: "weekly"
41-
labels:
42-
- "auto-approve"
43-
open-pull-requests-limit: 5

.github/workflows/README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,3 +128,8 @@ Owner: CDK Support team
128128

129129
[project-prioritization-needs-attention.yml](project-prioritization-needs-attention.yml): GitHub action that runs every day to update Needs Attention field in the prioritization project board.
130130
Owner: CDK Support team
131+
132+
### PR Prioritization AddedOn update
133+
134+
[project-prioritization-added-on.yml](project-prioritization-added-on.yml): GitHub action that runs every day to update AddedOn field in the prioritization project board.
135+
Owner: CDK Support team

.github/workflows/analytics-metadata-updater.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ on:
77

88
jobs:
99
update-analytics-metadata:
10-
if: github.repository == 'aws/aws-cdk'
10+
if: github.repository == 'aws/aws-cdk' && github.actor == 'aws-cdk-automation'
1111
runs-on: ubuntu-latest
1212
permissions:
1313
contents: write

.github/workflows/codeql.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@ jobs:
4646
with:
4747
languages: ${{ matrix.language }}
4848
build-mode: ${{ matrix.build-mode }}
49+
config-file: ./.github/codeql/codeql-config.yml
4950
# If you wish to specify custom queries, you can do so here or in a config file.
5051
# By default, queries listed here will override any specified in a config file.
5152
# Prefix the list here with "+" to use these queries and those in the config file.
Lines changed: 78 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,78 @@
1+
name: CDK Enums Auto Updater
2+
on:
3+
workflow_dispatch:
4+
5+
jobs:
6+
update-l2-enums:
7+
if: github.repository == 'aws/aws-cdk'
8+
runs-on: ubuntu-latest
9+
permissions:
10+
contents: write
11+
pull-requests: write
12+
steps:
13+
- name: Check Out
14+
uses: actions/checkout@v4
15+
16+
- name: Set up Node
17+
uses: actions/setup-node@v4
18+
with:
19+
node-version: "*"
20+
env:
21+
NODE_OPTIONS: "--max-old-space-size=8196 --experimental-worker ${NODE_OPTIONS:-}"
22+
23+
- name: Install dependencies
24+
run: yarn install --frozen-lockfile && cd tools/@aws-cdk/enum-updater && yarn build
25+
26+
- name: Identify Missing Values and Apply Code Changes
27+
run: |
28+
cd tools/@aws-cdk/enum-updater
29+
./bin/update-missing-enums
30+
31+
- name: Check for changes
32+
id: git-check
33+
run: |
34+
if [[ -n "$(git status --porcelain)" ]]; then
35+
echo "changes=true" >> $GITHUB_OUTPUT
36+
else
37+
echo "changes=false" >> $GITHUB_OUTPUT
38+
fi
39+
40+
- name: Commit & Push changes
41+
if: steps.git-check.outputs.changes == 'true'
42+
run: |
43+
git config --global user.name 'aws-cdk-automation'
44+
git config --global user.email '[email protected]'
45+
46+
# Iterate through each module directory that has changes
47+
for module in $(git diff --name-only | grep -E '^packages/(@aws-cdk|aws-cdk-lib)/.*' | sed -E 's|^packages/(@aws-cdk\|aws-cdk-lib)/([^/]+).*|\2|' | sort -u); do
48+
moduleName=$(basename $module)
49+
50+
# Check for existing PR with the same name
51+
prExists=$(gh pr list --state open --search "feat(${moduleName#aws-}): add new enum values for ${moduleName#aws-}" --json number,title -q '.[].number')
52+
53+
# If a PR exists, close it and continue
54+
if [[ -n "$prExists" ]]; then
55+
echo "PR already exists for module ${moduleName#aws-}, closing the existing PR."
56+
gh pr close "$prExists" --confirm # Close the PR by its number
57+
fi
58+
59+
# Create a new branch for the module
60+
branchName="enum-update/${moduleName#aws-}"
61+
git checkout -b "$branchName"
62+
63+
# Stage, commit, and push changes for the module
64+
git add "packages/$module" # Add only changes for this module
65+
git commit -m "chore(${moduleName#aws-}): add new enum values for ${moduleName#aws-}"
66+
git push origin "$branchName"
67+
68+
# Create a new pull request
69+
gh pr create --title "chore(${moduleName#aws-}): add new enum values for ${moduleName#aws-}" \
70+
--body "This PR updates the enum values for ${moduleName#aws-}." \
71+
--base main \
72+
--head "$branchName"
73+
--label "contribution/core,pr-linter/exempt-integ-test,pr-linter/exempt-readme,pr-linter/exempt-test" \
74+
--reviewer "aws-cdk-team" \
75+
done
76+
77+
env:
78+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/lambda-runtime-tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ on:
66

77
jobs:
88
update-lambda-tests:
9-
if: github.repository == 'aws/aws-cdk'
9+
if: github.repository == 'aws/aws-cdk' && github.actor == 'aws-cdk-automation'
1010
runs-on: ubuntu-latest
1111
permissions:
1212
contents: write
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: PR Prioritization AddedOn update
2+
3+
on:
4+
schedule:
5+
- cron: '0 */6 * * 1-5' # Runs every 6 hours during weekdays
6+
workflow_dispatch: # Manual trigger
7+
8+
jobs:
9+
update_added_on:
10+
if: github.repository == 'aws/aws-cdk'
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v4
14+
15+
- name: Update AddedOn field
16+
uses: actions/github-script@v7
17+
with:
18+
github-token: ${{ secrets.PROJEN_GITHUB_TOKEN }}
19+
script: |
20+
const script = require('./scripts/prioritization/update-added-on.js')
21+
await script({github})

.github/workflows/yarn-upgrade.yml

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -39,10 +39,6 @@ jobs:
3939
- name: Install Tools
4040
run: |-
4141
npm -g install lerna npm-check-updates
42-
- name: Build Integ Runner
43-
run: |
44-
export NODE_OPTIONS="--max-old-space-size=8196 --experimental-worker ${NODE_OPTIONS:-}"
45-
npx lerna run build --scope @aws-cdk/integ-runner
4642
- name: List Mono-Repo Packages
4743
id: list-packages
4844
# These need to be ignored from the `ncu` runs!
@@ -77,9 +73,6 @@ jobs:
7773
- name: Run "yarn upgrade"
7874
run: yarn upgrade
7975

80-
- name: Regenerate Integ Runner attributions
81-
run: cd packages/@aws-cdk/integ-runner && yarn pkglint
82-
8376
# Next, create and upload the changes as a patch file. This will later be downloaded to create a pull request
8477
# Creating a pull request requires write permissions and it's best to keep write privileges isolated.
8578
- name: Create Patch

0 commit comments

Comments
 (0)