Skip to content

Commit ea24d97

Browse files
mesh-2092: add make update to workflow
1 parent c0028c9 commit ea24d97

1 file changed

Lines changed: 35 additions & 0 deletions

File tree

.github/workflows/dependabot-auto-merge.yaml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,43 @@ on:
1010
- labeled
1111

1212
jobs:
13+
export-requirements:
14+
# if: github.actor == 'dependabot[bot]'
15+
runs-on: ubuntu-latest
16+
permissions:
17+
contents: write
18+
19+
steps:
20+
- name: Checkout repository
21+
uses: actions/checkout@v4
22+
with:
23+
ref: ${{ github.head_ref }}
24+
token: ${{ secrets.GITHUB_TOKEN }}
25+
26+
- name: Set up Python
27+
uses: actions/setup-python@v5
28+
with:
29+
python-version: '3.11'
30+
31+
- name: Install Poetry
32+
run: |
33+
curl -sSL https://install.python-poetry.org | python3 -
34+
echo "$HOME/.local/bin" >> $GITHUB_PATH
35+
36+
- name: Export requirements
37+
run: make export-requirements
38+
39+
- name: Commit and push changes
40+
run: |
41+
git config --global user.name 'github-actions[bot]'
42+
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
43+
git add requirements.txt
44+
git diff --staged --quiet || git commit -m "mesh-2092: update requirements.txt"
45+
git push
46+
1347
enable-automerge:
1448
# Only run on Dependabot PRs
49+
needs: export-requirements
1550
if: github.actor == 'dependabot[bot]'
1651
runs-on: ubuntu-latest
1752
permissions:

0 commit comments

Comments
 (0)