Skip to content

Commit

Permalink
Merge branch 'master' into add-option-filename-prefix-suffix
Browse files Browse the repository at this point in the history
  • Loading branch information
LandonTClipp committed Feb 9, 2023
2 parents c98782f + f6ff7ae commit 347308c
Show file tree
Hide file tree
Showing 89 changed files with 2,701 additions and 1,462 deletions.
25 changes: 24 additions & 1 deletion .github/ISSUE_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,36 @@
PLEASE READ
-------------

DO NOT submit tickets without _first_ using the latest version of Golang, clearing your local golang package cache, and re-building mockery using the _latest_ Golang version and the _latest_ version of mockery. Please provide evidence this has been done in your issue. Failure to provide this evidence will likely result in your issue being closed.

Description
-------------

[Description of the bug or feature]

Version
Mockery Version
--------

[version of mockery being used]

Golang Version
--------------

[version of golang being used]

```
NOTE: Please upgrade to the latest golang version before submitting tickets!
```

Installation Method
-------------------

- [ ] Binary Distribution
- [ ] Docker
- [ ] brew
- [ ] go install
- [ ] Other: [specify]

Steps to Reproduce
------------------

Expand Down
2 changes: 2 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ Version of Golang used when building/testing:
- [ ] 1.16
- [ ] 1.17
- [ ] 1.18
- [ ] 1.19
- [ ] 1.20

How Has This Been Tested?
---------------------------
Expand Down
11 changes: 10 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ on:
jobs:
release:
runs-on: ubuntu-latest
env:
DOCKER_CLI_EXPERIMENTAL: "enabled"

steps:
- uses: actions/checkout@v2
with:
Expand All @@ -16,7 +19,13 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.18
go-version: '1.20'

- name: Set up QEMU
uses: docker/setup-qemu-action@v2

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2

- name: Login to DockerHub
uses: docker/login-action@v1
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/testing.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
strategy:
matrix:
os: [ macos-latest, ubuntu-latest]
go_vers: [1.16, 1.17, 1.18]
go_vers: ['1.20']
steps:
- uses: actions/checkout@v2
with:
Expand Down
39 changes: 33 additions & 6 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,20 +34,47 @@ snapshot:
changelog:
sort: asc
dockers:
- goos: linux
- image_templates: ["vektra/mockery:{{ .Tag }}-amd64"]
goarch: amd64
image_templates:
- 'vektra/mockery:{{ .Tag }}'
- 'vektra/mockery:v{{ .Major }}'
- 'vektra/mockery:v{{ .Major }}.{{ .Minor }}'
- 'vektra/mockery:latest'
dockerfile: Dockerfile
use: buildx
build_flag_templates:
- "--pull"
- "--label=org.opencontainers.image.created={{.Date}}"
- "--label=org.opencontainers.image.name={{.ProjectName}}"
- "--label=org.opencontainers.image.revision={{.FullCommit}}"
- "--label=org.opencontainers.image.version={{.Version}}"
- "--label=org.opencontainers.image.source={{.GitURL}}"
- "--platform=linux/amd64"
- image_templates: ["vektra/mockery:{{ .Tag }}-arm64"]
goarch: arm64
dockerfile: Dockerfile
use: buildx
build_flag_templates:
- "--pull"
- "--label=org.opencontainers.image.created={{.Date}}"
- "--label=org.opencontainers.image.name={{.ProjectName}}"
- "--label=org.opencontainers.image.revision={{.FullCommit}}"
- "--label=org.opencontainers.image.version={{.Version}}"
- "--label=org.opencontainers.image.source={{.GitURL}}"
- "--platform=linux/arm64"
docker_manifests:
- name_template: vektra/mockery:{{ .Tag }}
image_templates:
- vektra/mockery:{{ .Tag }}-amd64
- vektra/mockery:{{ .Tag }}-arm64
- name_template: vektra/mockery:v{{ .Major }}
image_templates:
- vektra/mockery:{{ .Tag }}-amd64
- vektra/mockery:{{ .Tag }}-arm64
- name_template: vektra/mockery:v{{ .Major }}.{{ .Minor }}
image_templates:
- vektra/mockery:{{ .Tag }}-amd64
- vektra/mockery:{{ .Tag }}-arm64
- name_template: vektra/mockery:latest
image_templates:
- vektra/mockery:{{ .Tag }}-amd64
- vektra/mockery:{{ .Tag }}-arm64
brews:
- homepage: https://github.com/vektra/mockery
description: "A mock code autogenerator for Go"
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM golang:1.18-alpine as builder
FROM golang:1.20-alpine as builder

COPY mockery /usr/local/bin

Expand Down
2 changes: 2 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ test: mocks
mocks: $(shell find . -type f -name '*.go' -not -name '*_test.go')
go run . --dir pkg/fixtures --output mocks/pkg/fixtures
go run . --all=false --print --dir pkg/fixtures --name RequesterVariadic --structname RequesterVariadicOneArgument --unroll-variadic=False > mocks/pkg/fixtures/RequesterVariadicOneArgument.go
go run . --all=false --print --dir pkg/fixtures --name Expecter --with-expecter > mocks/pkg/fixtures/Expecter.go
go run . --all=false --print --dir pkg/fixtures --name RequesterReturnElided --with-expecter > mocks/pkg/fixtures/RequesterReturnElided.go
@touch mocks

.PHONY: install
Expand Down

0 comments on commit 347308c

Please sign in to comment.