forked from evryfs/github-actions-runner
-
Notifications
You must be signed in to change notification settings - Fork 0
36 lines (31 loc) · 1.04 KB
/
updater.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
name: Check Virtualenv
on:
schedule:
- cron: "0 0 * * *"
workflow_dispatch:
jobs:
check-for-updates:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Check for updates
id: update
run: |
version=$(curl --silent https://api.github.com/repos/actions/virtual-environments/releases | \
jq -r 'map(select(.tag_name|startswith("ubuntu20"))|.tag_name)[0]')
echo ::set-output name=version::$version
if [[ "${version}a" = ubuntu20/*a ]];then
sed -i -r "s|^(ARG VIRTUAL_ENVIRONMENT_VERSION)\s*=.*|\1=$version|" Dockerfile
fi
- name: Create PR
uses: peter-evans/create-pull-request@v3
with:
branch: "virtualenv/bump-${{ steps.update.outputs.version }}"
title: "Bump virtualenv to ${{ steps.update.outputs.version }}"
commit-message: "Bump virtualenv to ${{ steps.update.outputs.version }}"
labels: |
dependencies
team-reviewers: |
owners
maintainers
draft: False