Skip to content

Commit 82bcce7

Browse files
mxygemmattwynnevearutop
authored
Add WSL friendly check-go-version setup (#443)
* Add WSL friendly check-go-version setup * Add changelog entry and update my username * Add PR link to changelog * Stop it saying 'noting to be done for check-go-version' * Update CHANGELOG.md Co-authored-by: Viacheslav Poturaev <[email protected]> Co-authored-by: Matt Wynne <[email protected]> Co-authored-by: Viacheslav Poturaev <[email protected]>
1 parent df29469 commit 82bcce7

File tree

2 files changed

+16
-8
lines changed

2 files changed

+16
-8
lines changed

CHANGELOG.md

Lines changed: 13 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,12 @@ This document is formatted according to the principles of [Keep A CHANGELOG](htt
88

99
---
1010

11+
## [Unreleased]
12+
13+
### Fixed
14+
15+
- `check-go-version` in Makefile to run on WSL. ([443](https://github.com/cucumber/godog/pull/443) - [mxygem])
16+
1117
## [v0.12.2]
1218

1319
### Fixed
@@ -146,8 +152,8 @@ This document is formatted according to the principles of [Keep A CHANGELOG](htt
146152

147153
### Changed
148154

149-
- Run godog features in CircleCI in strict mode ([jaysonesmith])
150-
- Removed TestMain call in `suite_test.go` for CI. ([jaysonesmith])
155+
- Run godog features in CircleCI in strict mode ([mxygem])
156+
- Removed TestMain call in `suite_test.go` for CI. ([mxygem])
151157
- Migrated to [gherkin-go - v11.0.0](https://github.com/cucumber/gherkin-go/releases/tag/v11.0.0). ([240](https://github.com/cucumber/godog/pull/240) - [lonnblad])
152158

153159
### Deprecated
@@ -158,7 +164,7 @@ This document is formatted according to the principles of [Keep A CHANGELOG](htt
158164

159165
- Fixed the time attributes in the JUnit formatter. ([232](https://github.com/cucumber/godog/pull/232) - [lonnblad])
160166
- Re enable custom formatters. ([238](https://github.com/cucumber/godog/pull/238) - [ericmcbride])
161-
- Added back suite_test.go ([jaysonesmith])
167+
- Added back suite_test.go ([mxygem])
162168
- Normalise module paths for use on Windows ([242](https://github.com/cucumber/godog/pull/242) - [gjtaylor])
163169
- Fixed panic in indenting function `s` ([247](https://github.com/cucumber/godog/pull/247) - [titouanfreville])
164170
- Fixed wrong version in API example ([263](https://github.com/cucumber/godog/pull/263) - [denis-trofimov])
@@ -181,18 +187,18 @@ This document is formatted according to the principles of [Keep A CHANGELOG](htt
181187
### Fixed
182188

183189
- Find/Replaced references to DATA-DOG/godog -> cucumber/godog for docs. ([209](https://github.com/cucumber/godog/pull/209) - [smikulcik])
184-
- Fixed missing links in changelog to be correctly included! ([jaysonesmith])
190+
- Fixed missing links in changelog to be correctly included! ([mxygem])
185191

186192
## [0.8.0]
187193

188194
### Added
189195

190-
- Added initial CircleCI config. ([jaysonesmith])
196+
- Added initial CircleCI config. ([mxygem])
191197
- Added concurrency support for JUnit formatting ([lonnblad])
192198

193199
### Changed
194200

195-
- Changed code references to DATA-DOG/godog to cucumber/godog to help get things building correctly. ([jaysonesmith])
201+
- Changed code references to DATA-DOG/godog to cucumber/godog to help get things building correctly. ([mxygem])
196202

197203
### Deprecated
198204

@@ -214,7 +220,7 @@ This document is formatted according to the principles of [Keep A CHANGELOG](htt
214220
<!-- Contributors -->
215221

216222
[axw]: https://github.com/axw
217-
[jaysonesmith]: https://github.com/jaysonesmith
223+
[mxygem]: https://github.com/mxygem
218224
[lonnblad]: https://github.com/lonnblad
219225
[smikulcik]: https://github.com/smikulcik
220226
[ericmcbride]: https://github.com/ericmcbride

Makefile

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,11 @@
22

33
VERS := $(shell grep 'const Version' -m 1 godog.go | awk -F\" '{print $$2}')
44

5+
FOUND_GO_VERSION := $(shell go version)
56
EXPECTED_GO_VERSION = 1.17
7+
.PHONY: check-go-version
68
check-go-version:
7-
@[[ "$(shell go version)" =~ $(EXPECTED_GO_VERSION) ]] || (echo Wrong go version! Please install $(EXPECTED_GO_VERSION) && exit 1)
9+
@$(if $(findstring ${EXPECTED_GO_VERSION}, ${FOUND_GO_VERSION}),(exit 0),(echo Wrong go version! Please install ${EXPECTED_GO_VERSION}; exit 1))
810

911
test: check-go-version
1012
@echo "running all tests"

0 commit comments

Comments
 (0)