-
Notifications
You must be signed in to change notification settings - Fork 73
Open
Description
Hey there, hope you're doing well! I can't seem to get gofumpt working as the base formatter when using golines (both gofmt and golines work perfectly).
I've used the number 0644 as a test for gofumpt which would be reformatted to 0o644.
~\source\go\test via 🐹 v1.20.2
🕙 [ 11:13:41 AM ] ❯ type .\main.go
package main
import "fmt"
func main() {
fmt.Println("This is an extremely long line", "with multiple strings", "which I'm hoping will be", "split up by golines")
x := 0644
fmt.Println(x)
}
~\source\go\test via 🐹 v1.20.2
🕙 [ 11:13:54 AM ] ❯ gofumpt.exe .\main.go
package main
import "fmt"
func main() {
fmt.Println("This is an extremely long line", "with multiple strings", "which I'm hoping will be", "split up by golines")
x := 0o644
fmt.Println(x)
}
~\source\go\test via 🐹 v1.20.2
🕙 [ 11:13:58 AM ] ❯ golines.exe .\main.go
package main
import "fmt"
func main() {
fmt.Println(
"This is an extremely long line",
"with multiple strings",
"which I'm hoping will be",
"split up by golines",
)
x := 0644
fmt.Println(x)
}
~\source\go\test via 🐹 v1.20.2
🕙 [ 11:14:02 AM ] ❯ golines.exe --base-formatter=gofumpt main.go
package main
import "fmt"
func main() {
fmt.Println(
"This is an extremely long line",
"with multiple strings",
"which I'm hoping will be",
"split up by golines",
)
x := 0644
fmt.Println(x)
}
Versions may be found below:
~\source\go\test via 🐹 v1.20.2
🕙 [ 11:15:41 AM ] ❯ gofumpt.exe --version
v0.4.0 (go1.20.2)
~\source\go\test via 🐹 v1.20.2
🕙 [ 11:15:43 AM ] ❯ golines.exe --version
golines v0.11.0
~\source\go\test via 🐹 v1.20.2
🕙 [ 11:15:45 AM ] ❯ go version
go version go1.20.2 windows/amd64
Thanks heaps
Fotis
telemachus and yzhou216
Metadata
Metadata
Assignees
Labels
No labels