-
Notifications
You must be signed in to change notification settings - Fork 331
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
170 additions
and
172 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,41 +1,41 @@ | ||
name: "Update dependencies" | ||
name: 'Update dependencies' | ||
|
||
on: | ||
schedule: | ||
# runs every six hours | ||
# runs every six hours | ||
- cron: 0 */6 * * * | ||
|
||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
jobs: | ||
dependancron: | ||
runs-on: [ubuntu-latest] | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: "Check dependencies" | ||
id: check | ||
run: | | ||
sudo wget https://dvc.org/deb/dvc.list -O /etc/apt/sources.list.d/dvc.list | ||
sudo apt update && sudo apt -y install dvc | ||
CML_VER=$(docker run dvcorg/cml:latest dvc --version) | ||
DVC_VER=$(dvc --version) | ||
UPDATE=false | ||
MESSAGE="Updating DVC from $CML_VER to $DVC_VER" | ||
if [ $CML_VER != $DVC_VER ]; then | ||
UPDATE=true | ||
echo "$DVC_VER" > .dependancron | ||
fi | ||
- uses: actions/checkout@v2 | ||
|
||
- name: 'Check dependencies' | ||
id: check | ||
run: | | ||
sudo wget https://dvc.org/deb/dvc.list -O /etc/apt/sources.list.d/dvc.list | ||
sudo apt update && sudo apt -y install dvc | ||
CML_VER=$(docker run dvcorg/cml:latest dvc --version) | ||
DVC_VER=$(dvc --version) | ||
UPDATE=false | ||
MESSAGE="Updating DVC from $CML_VER to $DVC_VER" | ||
if [ $CML_VER != $DVC_VER ]; then | ||
UPDATE=true | ||
echo "$DVC_VER" > .dependancron | ||
fi | ||
echo "::set-output name=update::${UPDATE}" | ||
echo "::set-output name=comment::${MESSAGE}" | ||
echo "::set-output name=update::${UPDATE}" | ||
echo "::set-output name=comment::${MESSAGE}" | ||
- name: Create Pull Request | ||
if: steps.check.outputs.update == 'true' | ||
uses: peter-evans/create-pull-request@v3 | ||
with: | ||
title: 'chore: dependancron update dependencies' | ||
body: ${{ steps.check.outputs.comment }} | ||
branch: 'dependancron-update-dependencies' | ||
- name: Create Pull Request | ||
if: steps.check.outputs.update == 'true' | ||
uses: peter-evans/create-pull-request@v3 | ||
with: | ||
title: 'chore: dependancron update dependencies' | ||
body: ${{ steps.check.outputs.comment }} | ||
branch: 'dependancron-update-dependencies' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
33f7f0e
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Test Comment
33f7f0e
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Test Comment