Skip to content

Commit

Permalink
trying to allow workflow_call - also set go to 1.21 and pass descript…
Browse files Browse the repository at this point in the history
…ion through env and input
  • Loading branch information
ldemailly committed Mar 20, 2024
1 parent 4e58dbc commit a896b8c
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 5 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/codecov.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
name: "Code Coverage"

on:
workflow_call:
push:
branches: [ main ]
pull_request:
Expand All @@ -13,7 +14,7 @@ jobs:
- uses: actions/checkout@master
- uses: actions/setup-go@v5
with:
go-version: 'stable'
go-version: '1.21'
check-latest: true
- name: Run test coverage
run: go test -race -coverprofile=coverage.out -covermode=atomic ./...
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
name: "CodeQL"

on:
workflow_call:
push:
branches: [ main ]
pull_request:
Expand Down Expand Up @@ -58,7 +59,7 @@ jobs:

# ℹ️ Command-line programs to run using the OS shell.
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
# If the Autobuild fails above, remove it and uncomment the following three lines.
# If the Autobuild fails above, remove it and uncomment the following three lines.
# modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance.
# - run: |
# echo "Run, Build Application using script"
Expand Down
12 changes: 10 additions & 2 deletions .github/workflows/releaser.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
name: Release

on:
workflow_call:
inputs:
description:
description: 'Description of the project for the goreleaser tap'
required: false
type: string
default: ''
push:
tags:
# so a vX.Y.Z-test1 doesn't trigger build
Expand All @@ -23,7 +30,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v5 # pin@v3
with:
go-version: '1.20'
go-version: '1.21'
check-latest: true
- name: Log in to Docker Hub
uses: docker/login-action@e92390c5fb421da1463c202d546fed0ec5c39f20 # pin@v2
Expand All @@ -35,6 +42,7 @@ jobs:
with:
distribution: goreleaser
version: latest
args: release --rm-dist
args: release --rm-dist --config https://raw.githubusercontent.com/fortio/workflows/main/goreleaser.yaml
env:
GITHUB_TOKEN: ${{ secrets.GH_PAT }}
TAP_DESCRIPTION: ${{ inputs.description }}
2 changes: 1 addition & 1 deletion goreleaser.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ brews:

# Template of your app's description.
# Default is empty.
description: "{{ .Description }}"
description: "{{ .Env.TAP_DESCRIPTION }}"

# SPDX identifier of your app's license.
# Default is empty.
Expand Down

0 comments on commit a896b8c

Please sign in to comment.