chore: format this project using this project :)
parent
d5d0bfc7ea
commit
07458099e9
4
Makefile
4
Makefile
|
@ -23,8 +23,10 @@ lint:
|
||||||
golangci-lint run ./...
|
golangci-lint run ./...
|
||||||
|
|
||||||
format:
|
format:
|
||||||
|
go install github.com/haunt98/gofimports/cmd/gofimports@latest
|
||||||
go install mvdan.cc/gofumpt@latest
|
go install mvdan.cc/gofumpt@latest
|
||||||
gofumpt -l -w -extra .
|
gofimports -w -company github.com/make-go-great .
|
||||||
|
gofumpt -w -extra .
|
||||||
|
|
||||||
build:
|
build:
|
||||||
go build ./cmd/gofimports
|
go build ./cmd/gofimports
|
||||||
|
|
15
README.md
15
README.md
|
@ -28,6 +28,21 @@ go install github.com/haunt98/gofimports/cmd/gofimports@latest
|
||||||
gofimports -l -company github.com/make-go-great -w -d ./internal
|
gofimports -l -company github.com/make-go-great -w -d ./internal
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Example result:
|
||||||
|
|
||||||
|
```go
|
||||||
|
import (
|
||||||
|
"fmt"
|
||||||
|
|
||||||
|
"github.com/urfave/cli/v2"
|
||||||
|
"github.com/pkg/diff"
|
||||||
|
|
||||||
|
"github.com/make-go-great/color-go"
|
||||||
|
|
||||||
|
"github.com/haunt98/gofimports/internal/imports"
|
||||||
|
)
|
||||||
|
```
|
||||||
|
|
||||||
## Roadmap
|
## Roadmap
|
||||||
|
|
||||||
- [ ] Diff with color
|
- [ ] Diff with color
|
||||||
|
|
|
@ -3,8 +3,9 @@ package cli
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/haunt98/gofimports/internal/imports"
|
|
||||||
"github.com/urfave/cli/v2"
|
"github.com/urfave/cli/v2"
|
||||||
|
|
||||||
|
"github.com/haunt98/gofimports/internal/imports"
|
||||||
)
|
)
|
||||||
|
|
||||||
type action struct {
|
type action struct {
|
||||||
|
|
|
@ -3,8 +3,9 @@ package cli
|
||||||
import (
|
import (
|
||||||
"os"
|
"os"
|
||||||
|
|
||||||
"github.com/make-go-great/color-go"
|
|
||||||
"github.com/urfave/cli/v2"
|
"github.com/urfave/cli/v2"
|
||||||
|
|
||||||
|
"github.com/make-go-great/color-go"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|
Loading…
Reference in New Issue