Skip to content

Commit

Permalink
All in one
Browse files Browse the repository at this point in the history
  • Loading branch information
vivian-rook committed May 28, 2024
1 parent d6e2731 commit 6277409
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 50 deletions.
47 changes: 0 additions & 47 deletions .github/workflows/update-chart-version.yaml

This file was deleted.

15 changes: 12 additions & 3 deletions .github/workflows/update-container-tags.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---

name: update container tags
name: update container tags and Chart.yaml

'on':
pull_request_target:
Expand Down Expand Up @@ -29,17 +29,26 @@ jobs:
run: |
git remote update
- name: update values.yaml
- name: update values.yaml and Chart.yaml
run: |
for i in renderer nbserve paws-hub jobber singleuser minesweeper ; do
if [[ $(git diff remotes/toolforgepaws/main -- images/${i}/) ]]; then
sed -i "s/tag: .* # ${i} tag managed by github actions$/tag: pr-${{ github.event.number }} # ${i} tag managed by github actions/" paws/values.yaml
UPDATECHART=1
fi
done
if [[ $(git diff remotes/toolforgepaws/main -- paws/values.yaml) ]]; then
UPDATECHART=1
fi
if [[ ${UPDATECHART} -eq 1 ]]; then
VERSION=$(grep ^version paws/Chart.yaml | perl -ne '$_ =~ /^version: (\d+.\d+.)(\d+)/; $version = $2 + 1; print "$1$version"')
sed -i "s/^version: .*/version: ${VERSION} # patch number managed by github actions/" paws/Chart.yaml
fi
- uses: EndBug/add-and-commit@v7
with:
add: 'paws/values.yaml'
add: '["paws/values.yaml", "paws/Chart.yaml"]'
author_name: Github Action
author_email: [email protected]
branch: ${{ github.head_ref }}
Expand Down

0 comments on commit 6277409

Please sign in to comment.