Skip to content

Commit

Permalink
Add go-version as a param (#57)
Browse files Browse the repository at this point in the history
Signed-off-by: Haytham Abuelfutuh <[email protected]>
  • Loading branch information
EngHabu authored Mar 31, 2022
1 parent 8bfb52d commit a4ea95f
Show file tree
Hide file tree
Showing 6 changed files with 34 additions and 7 deletions.
6 changes: 5 additions & 1 deletion flytetools/.github/workflows/flyte_automation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ on:
description: "Flyte Go component"
required: true
type: string
go-version:
default: "1.18"
required: false
type: string
secrets:
FLYTE_BOT_PAT:
required: true
Expand All @@ -21,7 +25,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.18
go-version: ${{ inputs.go-version }}
- name: Update release
run: |
if [[ ${{ inputs.component }} == "boilerplate" ]]
Expand Down
7 changes: 6 additions & 1 deletion flytetools/.github/workflows/go_generate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@ name: Go Generate

on:
workflow_call:
inputs:
go-version:
default: "1.18"
required: false
type: string
jobs:
generate:
runs-on: ubuntu-latest
Expand All @@ -10,6 +15,6 @@ jobs:
- uses: actions/checkout@v1
- uses: actions/setup-go@v2
with:
go-version: "1.18"
go-version: ${{ inputs.go-version }}
- name: Go generate and diff
run: DELTA_CHECK=true make generate
7 changes: 6 additions & 1 deletion flytetools/.github/workflows/goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@ name: Go Releaser

on:
workflow_call:
inputs:
go-version:
default: "1.18"
required: false
type: string
secrets:
FLYTE_BOT_PAT:
required: true
Expand All @@ -16,7 +21,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.18
go-version: ${{ inputs.go-version }}
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v2
with:
Expand Down
6 changes: 5 additions & 1 deletion flytetools/.github/workflows/integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ on:
description: "Cache key for docker image"
required: true
type: string
go-version:
default: "1.18"
required: false
type: string
jobs:
integration:
name: Integration tests
Expand All @@ -28,7 +32,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.18
go-version: ${{ inputs.go-version }}
- name: Integration
run: |
# attempt to clean up some unneeded data: https://github.com/actions/virtual-environments/issues/2840#issuecomment-790492173
Expand Down
8 changes: 6 additions & 2 deletions flytetools/.github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,11 @@ name: Lint

on:
workflow_call:

inputs:
go-version:
default: "1.18"
required: false
type: string
jobs:
lint:
name: Run Lint
Expand All @@ -13,6 +17,6 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.18
go-version: ${{ inputs.go-version }}
- name: Lint
run: make install && make lint
7 changes: 6 additions & 1 deletion flytetools/.github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@ name: Unit Test

on:
workflow_call:
inputs:
go-version:
default: "1.18"
required: false
type: string
secrets:
FLYTE_BOT_PAT:
required: true
Expand All @@ -15,7 +20,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.18
go-version: ${{ inputs.go-version }}
- name: Unit Tests
env:
GITHUB_TOKEN: ${{ secrets.FLYTE_BOT_PAT }}
Expand Down

0 comments on commit a4ea95f

Please sign in to comment.