From f2e5bedea6fb93fbbf68ed8f7153c353cc57a9f0 Mon Sep 17 00:00:00 2001
From: tobi <31960611+tsmethurst@users.noreply.github.com>
Date: Fri, 10 Sep 2021 14:42:14 +0200
Subject: migrate go version to 1.17 (#203)
* migrate go version to 1.17
* update contributing
---
.../go-playground/universal-translator/Makefile | 18 ++++++++++++++++++
.../go-playground/universal-translator/README.md | 6 +++---
.../go-playground/universal-translator/go.mod | 5 -----
.../go-playground/universal-translator/go.sum | 4 ----
.../universal-translator/import_export.go | 2 ++
.../go-playground/universal-translator/translator.go | 12 ++++++------
6 files changed, 29 insertions(+), 18 deletions(-)
create mode 100644 vendor/github.com/go-playground/universal-translator/Makefile
delete mode 100644 vendor/github.com/go-playground/universal-translator/go.mod
delete mode 100644 vendor/github.com/go-playground/universal-translator/go.sum
(limited to 'vendor/github.com/go-playground/universal-translator')
diff --git a/vendor/github.com/go-playground/universal-translator/Makefile b/vendor/github.com/go-playground/universal-translator/Makefile
new file mode 100644
index 000000000..ec3455bd5
--- /dev/null
+++ b/vendor/github.com/go-playground/universal-translator/Makefile
@@ -0,0 +1,18 @@
+GOCMD=GO111MODULE=on go
+
+linters-install:
+ @golangci-lint --version >/dev/null 2>&1 || { \
+ echo "installing linting tools..."; \
+ curl -sfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh| sh -s v1.41.1; \
+ }
+
+lint: linters-install
+ golangci-lint run
+
+test:
+ $(GOCMD) test -cover -race ./...
+
+bench:
+ $(GOCMD) test -bench=. -benchmem ./...
+
+.PHONY: test lint linters-install
\ No newline at end of file
diff --git a/vendor/github.com/go-playground/universal-translator/README.md b/vendor/github.com/go-playground/universal-translator/README.md
index 071f33ab2..46dec6d2b 100644
--- a/vendor/github.com/go-playground/universal-translator/README.md
+++ b/vendor/github.com/go-playground/universal-translator/README.md
@@ -1,5 +1,5 @@
## universal-translator
-

+

[](https://travis-ci.org/go-playground/universal-translator)
[](https://coveralls.io/github/go-playground/universal-translator)
[](https://goreportcard.com/report/github.com/go-playground/universal-translator)
@@ -18,7 +18,7 @@ use in your applications.
Features
--------
-- [x] Rules generated from the [CLDR](http://cldr.unicode.org/index/downloads) data, v30.0.3
+- [x] Rules generated from the [CLDR](http://cldr.unicode.org/index/downloads) data, v36.0.1
- [x] Contains Cardinal, Ordinal and Range Plural Rules
- [x] Contains Month, Weekday and Timezone translations built in
- [x] Contains Date & Time formatting functions
@@ -51,7 +51,7 @@ Please see https://godoc.org/github.com/go-playground/universal-translator for u
File formatting
--------------
-All types, Plain substitution, Cardinal, Ordinal and Range translations can all be contained withing the same file(s);
+All types, Plain substitution, Cardinal, Ordinal and Range translations can all be contained within the same file(s);
they are only separated for easy viewing.
##### Examples:
diff --git a/vendor/github.com/go-playground/universal-translator/go.mod b/vendor/github.com/go-playground/universal-translator/go.mod
deleted file mode 100644
index 8079590fe..000000000
--- a/vendor/github.com/go-playground/universal-translator/go.mod
+++ /dev/null
@@ -1,5 +0,0 @@
-module github.com/go-playground/universal-translator
-
-go 1.13
-
-require github.com/go-playground/locales v0.13.0
diff --git a/vendor/github.com/go-playground/universal-translator/go.sum b/vendor/github.com/go-playground/universal-translator/go.sum
deleted file mode 100644
index cbbf32416..000000000
--- a/vendor/github.com/go-playground/universal-translator/go.sum
+++ /dev/null
@@ -1,4 +0,0 @@
-github.com/go-playground/locales v0.13.0 h1:HyWk6mgj5qFqCT5fjGBuRArbVDfE4hi8+e8ceBS/t7Q=
-github.com/go-playground/locales v0.13.0/go.mod h1:taPMhCMXrRLJO55olJkUXHZBHCxTMfnGwq/HNwmWNS8=
-golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk=
-golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
diff --git a/vendor/github.com/go-playground/universal-translator/import_export.go b/vendor/github.com/go-playground/universal-translator/import_export.go
index 7bd76f26b..1216f1923 100644
--- a/vendor/github.com/go-playground/universal-translator/import_export.go
+++ b/vendor/github.com/go-playground/universal-translator/import_export.go
@@ -257,6 +257,8 @@ func (t *UniversalTranslator) ImportByReader(format ImportExportFormat, reader i
func stringToPR(s string) locales.PluralRule {
switch s {
+ case "Zero":
+ return locales.PluralRuleZero
case "One":
return locales.PluralRuleOne
case "Two":
diff --git a/vendor/github.com/go-playground/universal-translator/translator.go b/vendor/github.com/go-playground/universal-translator/translator.go
index cfafce8a0..24b18db92 100644
--- a/vendor/github.com/go-playground/universal-translator/translator.go
+++ b/vendor/github.com/go-playground/universal-translator/translator.go
@@ -159,13 +159,13 @@ func (t *translator) AddCardinal(key interface{}, text string, rule locales.Plur
}
} else {
- tarr = make([]*transText, 7, 7)
+ tarr = make([]*transText, 7)
t.cardinalTanslations[key] = tarr
}
trans := &transText{
text: text,
- indexes: make([]int, 2, 2),
+ indexes: make([]int, 2),
}
tarr[rule] = trans
@@ -211,13 +211,13 @@ func (t *translator) AddOrdinal(key interface{}, text string, rule locales.Plura
}
} else {
- tarr = make([]*transText, 7, 7)
+ tarr = make([]*transText, 7)
t.ordinalTanslations[key] = tarr
}
trans := &transText{
text: text,
- indexes: make([]int, 2, 2),
+ indexes: make([]int, 2),
}
tarr[rule] = trans
@@ -261,13 +261,13 @@ func (t *translator) AddRange(key interface{}, text string, rule locales.PluralR
}
} else {
- tarr = make([]*transText, 7, 7)
+ tarr = make([]*transText, 7)
t.rangeTanslations[key] = tarr
}
trans := &transText{
text: text,
- indexes: make([]int, 4, 4),
+ indexes: make([]int, 4),
}
tarr[rule] = trans
--
cgit v1.2.3