Skip to content
This repository has been archived by the owner on Oct 24, 2023. It is now read-only.

Commit

Permalink
ci: standardize go mod vendor (#4539)
Browse files Browse the repository at this point in the history
  • Loading branch information
jackfrancis authored Jun 29, 2021
1 parent dc1ca24 commit 94d847e
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 9 deletions.
Original file line number Diff line number Diff line change
@@ -1,27 +1,27 @@
name: Update Tools
name: Update Go Mod Vendor
on:
schedule:
- cron: '0 9 * * *' # Every day at 9:00 a.m.
workflow_dispatch:
jobs:
generate-azure-consts:
udpate-go-mod-vendor:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: install go
uses: actions/setup-go@v2
with:
go-version: '^1.16'
- name: update hack/tools
run: make tools-reload
- name: run go mod vendor
run: make vendor
- name: validate no changes
run: git diff-index --quiet HEAD --
run: git diff-index --quiet HEAD -- || echo "MAKE_PR=true" >> $GITHUB_ENV
- name: create pull request
if: ${{ failure() }}
if: ${{ env.MAKE_PR == 'true' }}
uses: peter-evans/create-pull-request@v3
with:
commit-message: 'chore: Update hack/tools dependencies'
title: 'chore: Update hack/tools dependencies'
body: Automated update of hack/tools dependencies
commit-message: 'chore: Update go mod vendor directories'
title: 'chore: Update go mod vendor directories'
body: Automated update of go mod vendor directories
branch: apply-hack-tools-updates
base: master
1 change: 1 addition & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,7 @@ tidy:
.PHONY: vendor
vendor: tidy
$(GO) mod vendor
make -C ./test/e2e vendor

build-binary: generate
go build $(GOFLAGS) -v -ldflags "$(LDFLAGS)" -o $(BINARY_DEST_DIR)/aks-engine .
Expand Down
4 changes: 4 additions & 0 deletions test/e2e/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,7 @@ clean:
.PHONY: tidy
tidy:
$(GO) mod tidy

.PHONY: vendor
vendor:
$(GO) mod vendor

0 comments on commit 94d847e

Please sign in to comment.