This is an automated email from the ASF dual-hosted git repository.
gkoszyk pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/iggy.git
The following commit(s) were added to refs/heads/master by this push:
new a318d99be chore(ci): add workflow to update licenses on Dependabot PRs
(#2367)
a318d99be is described below
commit a318d99be1a05edffebcf70d57f4bff7cd2b2232
Author: Hubert Gruszecki <[email protected]>
AuthorDate: Tue Nov 18 11:01:15 2025 +0100
chore(ci): add workflow to update licenses on Dependabot PRs (#2367)
---
.github/workflows/dependabot-licenses.yml | 62 +++++++++++++++++++++++++++++++
1 file changed, 62 insertions(+)
diff --git a/.github/workflows/dependabot-licenses.yml
b/.github/workflows/dependabot-licenses.yml
new file mode 100644
index 000000000..c482a6a98
--- /dev/null
+++ b/.github/workflows/dependabot-licenses.yml
@@ -0,0 +1,62 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Update licenses for Dependabot PRs
+
+on:
+ pull_request_target:
+ paths:
+ - "Cargo.toml"
+ - "Cargo.lock"
+ - "**/Cargo.toml"
+
+permissions:
+ contents: write
+ pull-requests: write
+
+jobs:
+ update-licenses:
+ name: Update DEPENDENCIES.md
+ runs-on: ubuntu-latest
+ if: github.actor == 'dependabot[bot]'
+ steps:
+ - name: Checkout PR branch
+ uses: actions/checkout@v4
+ with:
+ ref: ${{ github.event.pull_request.head.ref }}
+ token: ${{ secrets.GITHUB_TOKEN }}
+
+ - name: Setup Rust
+ uses: dtolnay/rust-action@stable
+
+ - name: Install cargo-license
+ run: cargo install cargo-license
+
+ - name: Update DEPENDENCIES.md
+ run: ./scripts/licenses-list.sh --update
+
+ - name: Commit changes
+ run: |
+ git config user.name "github-actions[bot]"
+ git config user.email "github-actions[bot]@users.noreply.github.com"
+ git add DEPENDENCIES.md
+ if git diff --staged --quiet; then
+ echo "No changes to commit"
+ else
+ git commit -m "chore(deps): update DEPENDENCIES.md"
+ git push
+ fi