Skip to content

Commit 56c4633

Browse files
authored
Merge branch 'main' into generator-bot-12065504873/iaasalpha
2 parents 950b884 + 82b9635 commit 56c4633

File tree

31 files changed

+2051
-778
lines changed

31 files changed

+2051
-778
lines changed

.github/workflows/dependency-checker.yaml

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -24,30 +24,30 @@ jobs:
2424
git config --global user.email "noreply@stackit.de"
2525
2626
pip install poetry
27+
28+
pr_name=$(echo "Dependency Updates")
29+
2730
make update-dependencies
28-
for file in $(git diff --name-only | grep poetry.lock); do
29-
# Extract the service for which the dependencies have been updated
30-
dirpath=$(dirname $file)
31-
pr_name=$(echo "Dependency Updater: ${dirpath}")
32-
33-
# Check if a PR already exists for the package
34-
if gh pr list --state open | grep -q "${pr_name}"; then
35-
echo "Pr for $dirpath already exists. Deleting old PR."
36-
pr_number=$(gh pr list --state open --json number --search "$pr_name" -q '.[0].number')
37-
gh pr close "$pr_number" --delete-branch
31+
branch_name="dependency-updater-${{ github.run_id }}"
32+
git checkout -b "$branch_name"
3833
39-
fi
40-
41-
# Create PR
42-
branch_name="dependency-updater-$dirpath-${{ github.run_id }}"
43-
git checkout -b "$branch_name"
44-
git add "$file"
45-
git commit -m "chore: dependency update"
46-
git push --set-upstream origin "$branch_name"
47-
echo $(git status)
48-
gh pr create --title "$pr_name" --body "Automated dependency update" --base "main"
49-
git checkout main
50-
sleep 30 # prevent rate limit.
51-
52-
done
34+
if [ -n "$(git diff --name-only)" ]; then
35+
for file in $(git diff --name-only | grep poetry.lock); do
36+
# Extract the service for which the dependencies have been updated
37+
dirpath=$(dirname $file)
38+
git add "$file"
39+
git commit -m "chore: dependency update for ${dirpath}"
40+
done
41+
42+
# Check if a PR already exists for dependency updates
43+
if gh pr list --state open | grep -q "${pr_name}"; then
44+
echo "Pr for $dirpath already exists. Deleting old PR."
45+
pr_number=$(gh pr list --state open --json number --search "$pr_name" -q '.[0].number')
46+
gh pr close "$pr_number" --delete-branch
47+
fi
5348
49+
git push --set-upstream origin "$branch_name"
50+
gh pr create --title "$pr_name" --body "Automated dependency update" --base "main"
51+
else
52+
echo "No changes detected. Skipping PR creation."
53+
fi

core/poetry.lock

Lines changed: 33 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

examples/observability/create_instances.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
client = DefaultApi(config)
1212

1313
# Get all offerings
14-
response = client.v1_projects_offerings_list(project_id)
14+
response = client.list_plans(project_id)
1515

1616
# Create instance using the first found offer
1717
create_instance_payload = CreateInstancePayload(

0 commit comments

Comments
 (0)