Skip to content

Commit dd5e4db

Browse files
author
Vic Shóstak
committed
Update project files to v4
1 parent 5bfc88b commit dd5e4db

File tree

29 files changed

+254
-204
lines changed

29 files changed

+254
-204
lines changed

.dockerignore

Lines changed: 0 additions & 19 deletions
This file was deleted.

.editorconfig

Lines changed: 0 additions & 17 deletions
This file was deleted.

.gitattributes

Lines changed: 0 additions & 2 deletions
This file was deleted.

Makefile

Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
.PHONY: clean lint security critic test install build release build-and-push-images delete-tag update-pkg-cache
22

33
clean:
4-
rm -rf ./tmp coverage.out
4+
rm -rf ./tmp ./tests
55

66
lint:
77
$(GOPATH)/bin/golangci-lint run ./...
@@ -13,8 +13,10 @@ critic:
1313
$(GOPATH)/bin/gocritic check -enableAll ./...
1414

1515
test: clean lint security critic
16-
go test -coverprofile=coverage.out ./...
17-
go tool cover -func=coverage.out
16+
mkdir ./tests
17+
go test -coverprofile=./tests/coverage.out ./...
18+
go tool cover -func=./tests/coverage.out
19+
rm -rf ./tests
1820

1921
install: test
2022
CGO_ENABLED=0 go build -ldflags="-s -w" -o $(GOPATH)/bin/cgapp ./cmd/cgapp/main.go
@@ -27,16 +29,16 @@ release: test
2729
$(GOPATH)/bin/goreleaser --snapshot --skip-publish --rm-dist
2830

2931
build-and-push-images: test
30-
podman build -t docker.io/koddr/cgapp:latest .
31-
podman push docker.io/koddr/cgapp:latest
32-
podman build -t docker.io/koddr/cgapp:$(VERSION) .
33-
podman push docker.io/koddr/cgapp:$(VERSION)
34-
podman image rm docker.io/koddr/cgapp:$(VERSION)
32+
docker build -t docker.io/koddr/cgapp:latest .
33+
docker push docker.io/koddr/cgapp:latest
34+
docker build -t docker.io/koddr/cgapp:$(VERSION) .
35+
docker push docker.io/koddr/cgapp:$(VERSION)
36+
docker image rm docker.io/koddr/cgapp:$(VERSION)
3537

3638
update-pkg-cache:
37-
curl -i https://proxy.golang.org/github.com/create-go-app/cli/v3/@v/v$(VERSION).info
39+
curl -i https://proxy.golang.org/github.com/create-go-app/cli/v4/@v/v$(VERSION).info
3840

3941
delete-tag:
4042
git tag --delete v$(VERSION)
41-
podman image rm docker.io/koddr/cgapp:latest
42-
podman image rm docker.io/koddr/cgapp:$(VERSION)
43+
docker image rm docker.io/koddr/cgapp:latest
44+
docker image rm docker.io/koddr/cgapp:$(VERSION)

README.md

Lines changed: 179 additions & 54 deletions
Large diffs are not rendered by default.

cmd/cgapp/main.go

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,18 +5,18 @@ Create a new production-ready project with backend (Golang),
55
frontend (JavaScript, TypeScript) and deploy automation
66
(Ansible, Docker) by running one CLI command.
77
8-
-> Focus on writing code and thinking of business logic!
9-
<- The Create Go App CLI will take care of the rest.
8+
Focus on writing your code and thinking of the business logic!
9+
The Create Go App CLI will take care of the rest.
1010
11-
A helpful documentation and next steps -> https://create-go.app/
11+
A helpful documentation and next steps -> https://github.com/create-go-app/cli
1212
13-
Copyright 2022 Vic Shóstak and Create Go App Contributors
13+
# Copyright 2023 Vic Shóstak and Create Go App Contributors
1414
1515
Licensed under the Apache License, Version 2.0 (the "License");
1616
you may not use this file except in compliance with the License.
1717
You may obtain a copy of the License at
1818
19-
http://www.apache.org/licenses/LICENSE-2.0
19+
http://www.apache.org/licenses/LICENSE-2.0
2020
2121
Unless required by applicable law or agreed to in writing, software
2222
distributed under the License is distributed on an "AS IS" BASIS,
@@ -26,7 +26,7 @@ limitations under the License.
2626
*/
2727
package main
2828

29-
import "github.com/create-go-app/cli/v3/cmd"
29+
import "github.com/create-go-app/cli/v4/cmd"
3030

3131
func main() {
3232
cmd.Execute()

cmd/create.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2022 Vic Shóstak and Create Go App Contributors. All rights reserved.
1+
// Copyright 2023 Vic Shóstak and Create Go App Contributors. All rights reserved.
22
// Use of this source code is governed by Apache 2.0 license
33
// that can be found in the LICENSE file.
44

@@ -12,8 +12,8 @@ import (
1212
"github.com/AlecAivazis/survey/v2"
1313
"github.com/spf13/cobra"
1414

15-
"github.com/create-go-app/cli/v3/pkg/cgapp"
16-
"github.com/create-go-app/cli/v3/pkg/registry"
15+
"github.com/create-go-app/cli/v4/pkg/cgapp"
16+
"github.com/create-go-app/cli/v4/pkg/registry"
1717
)
1818

1919
func init() {

cmd/deploy.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2022 Vic Shóstak and Create Go App Contributors. All rights reserved.
1+
// Copyright 2023 Vic Shóstak and Create Go App Contributors. All rights reserved.
22
// Use of this source code is governed by Apache 2.0 license
33
// that can be found in the LICENSE file.
44

@@ -10,8 +10,8 @@ import (
1010

1111
"github.com/spf13/cobra"
1212

13-
"github.com/create-go-app/cli/v3/pkg/cgapp"
14-
"github.com/create-go-app/cli/v3/pkg/registry"
13+
"github.com/create-go-app/cli/v4/pkg/cgapp"
14+
"github.com/create-go-app/cli/v4/pkg/registry"
1515
)
1616

1717
func init() {

cmd/root.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2022 Vic Shóstak and Create Go App Contributors. All rights reserved.
1+
// Copyright 2023 Vic Shóstak and Create Go App Contributors. All rights reserved.
22
// Use of this source code is governed by Apache 2.0 license
33
// that can be found in the LICENSE file.
44

@@ -8,8 +8,8 @@ import (
88
"github.com/AlecAivazis/survey/v2"
99
"github.com/spf13/cobra"
1010

11-
"github.com/create-go-app/cli/v3/pkg/cgapp"
12-
"github.com/create-go-app/cli/v3/pkg/registry"
11+
"github.com/create-go-app/cli/v4/pkg/cgapp"
12+
"github.com/create-go-app/cli/v4/pkg/registry"
1313
)
1414

1515
var (

go.mod

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
module github.com/create-go-app/cli/v3
1+
module github.com/create-go-app/cli/v4
22

3-
go 1.17
3+
go 1.20
44

55
require (
6-
github.com/AlecAivazis/survey/v2 v2.3.4
6+
github.com/AlecAivazis/survey/v2 v2.3.7
77
github.com/go-git/go-git/v5 v5.7.0
88
github.com/mattn/go-colorable v0.1.13
9-
github.com/spf13/cobra v1.4.0
9+
github.com/spf13/cobra v1.7.0
1010
)
1111

1212
require (
@@ -19,7 +19,7 @@ require (
1919
github.com/go-git/go-billy/v5 v5.4.1 // indirect
2020
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
2121
github.com/imdario/mergo v0.3.15 // indirect
22-
github.com/inconshreveable/mousetrap v1.0.0 // indirect
22+
github.com/inconshreveable/mousetrap v1.1.0 // indirect
2323
github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99 // indirect
2424
github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51 // indirect
2525
github.com/kevinburke/ssh_config v1.2.0 // indirect
@@ -29,6 +29,7 @@ require (
2929
github.com/sergi/go-diff v1.2.0 // indirect
3030
github.com/skeema/knownhosts v1.1.1 // indirect
3131
github.com/spf13/pflag v1.0.5 // indirect
32+
github.com/stretchr/testify v1.7.0 // indirect
3233
github.com/xanzy/ssh-agent v0.3.3 // indirect
3334
golang.org/x/crypto v0.9.0 // indirect
3435
golang.org/x/net v0.10.0 // indirect

0 commit comments

Comments
 (0)