mirror of
https://github.com/wader/fq.git
synced 2024-12-23 13:22:58 +03:00
Update github-go-version from 1.17.7, 1.17.7, 1.17.7 to 1.18.0
Replace strings.Title and and fix deprecation warning
This commit is contained in:
parent
57377e8fc6
commit
e5f61e22e9
4
.github/workflows/ci.yml
vendored
4
.github/workflows/ci.yml
vendored
@ -15,7 +15,7 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- uses: actions/setup-go@v3
|
- uses: actions/setup-go@v3
|
||||||
with:
|
with:
|
||||||
go-version: 1.17.7
|
go-version: 1.18.0
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
- uses: golangci/golangci-lint-action@v3
|
- uses: golangci/golangci-lint-action@v3
|
||||||
with:
|
with:
|
||||||
@ -47,7 +47,7 @@ jobs:
|
|||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
- uses: actions/setup-go@v3
|
- uses: actions/setup-go@v3
|
||||||
with:
|
with:
|
||||||
go-version: 1.17.7
|
go-version: 1.18.0
|
||||||
- name: Test
|
- name: Test
|
||||||
env:
|
env:
|
||||||
GOARCH: ${{ matrix.goarch }}
|
GOARCH: ${{ matrix.goarch }}
|
||||||
|
2
.github/workflows/release.yml
vendored
2
.github/workflows/release.yml
vendored
@ -15,7 +15,7 @@ jobs:
|
|||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
- uses: actions/setup-go@v3
|
- uses: actions/setup-go@v3
|
||||||
with:
|
with:
|
||||||
go-version: 1.17.7
|
go-version: 1.18.0
|
||||||
- uses: goreleaser/goreleaser-action@v2
|
- uses: goreleaser/goreleaser-action@v2
|
||||||
with:
|
with:
|
||||||
distribution: goreleaser
|
distribution: goreleaser
|
||||||
|
@ -69,6 +69,13 @@ func findDefintion(docs []Documentation) (string, bool) {
|
|||||||
return "", false
|
return "", false
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func title(s string) string {
|
||||||
|
if len(s) <= 1 {
|
||||||
|
return s
|
||||||
|
}
|
||||||
|
return strings.ToUpper(s[0:1]) + s[1:]
|
||||||
|
}
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
xmlPath := os.Args[1]
|
xmlPath := os.Args[1]
|
||||||
r, err := os.Open(xmlPath)
|
r, err := os.Open(xmlPath)
|
||||||
@ -135,7 +142,7 @@ func main() {
|
|||||||
if defOk {
|
if defOk {
|
||||||
fmt.Printf("\t\tDefinition: %q,\n", def)
|
fmt.Printf("\t\tDefinition: %q,\n", def)
|
||||||
}
|
}
|
||||||
fmt.Printf("\t\tType: ebml.%s%s,\n", strings.Title(typ), extra)
|
fmt.Printf("\t\tType: ebml.%s%s,\n", title(typ), extra)
|
||||||
if len(c.Enums) > 0 {
|
if len(c.Enums) > 0 {
|
||||||
switch c.Type {
|
switch c.Type {
|
||||||
case "integer":
|
case "integer":
|
||||||
|
Loading…
Reference in New Issue
Block a user