Skip to content

Commit

Permalink
ci: build image when obs websocket protocol version is bumped instead…
Browse files Browse the repository at this point in the history
… of weekly
  • Loading branch information
andreykaipov committed Jan 26, 2024
1 parent a23faa8 commit 53f17e6
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
1 change: 0 additions & 1 deletion .github/workflows/image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ name: Image

on:
workflow_dispatch:
schedule: [{cron: '25 9 * * 3'}] # 9:25 on Wednesdays
push:
branches: [main]
paths:
Expand Down
8 changes: 8 additions & 0 deletions script/bump-protocol-version.sh
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,13 @@ compare_versions() {
echo "$next" >/tmp/.goobs.protocol.next
}

build_image() {
gh workflow run image.yml
sleep 3
id=$(gh run list --workflow image.yml --event workflow_dispatch --json databaseId --jq 'first|.databaseId')
gh run watch "$id"
}

bump_versions() {
sed -i "s/$current/$next/g" version.go README.md
make generate
Expand All @@ -65,6 +72,7 @@ bump_versions() {
main() {
find_versions
compare_versions
build_image
bump_versions
}

Expand Down

0 comments on commit 53f17e6

Please sign in to comment.