ci: add golangci-lint config and fix formatting
- Add .golangci.yml with minimal linters (govet, ineffassign) - Run gofmt -s and goimports on all files to fix formatting - Disable fieldalignment and copylocks checks in govet
This commit is contained in:
@@ -387,7 +387,7 @@ func (m *MySQL) buildDSN() string {
|
||||
"/tmp/mysql.sock",
|
||||
"/var/lib/mysql/mysql.sock",
|
||||
}
|
||||
|
||||
|
||||
// Use the first available socket path, fallback to TCP if none found
|
||||
socketFound := false
|
||||
for _, socketPath := range socketPaths {
|
||||
@@ -397,7 +397,7 @@ func (m *MySQL) buildDSN() string {
|
||||
break
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// If no socket found, use TCP localhost
|
||||
if !socketFound {
|
||||
dsn += "tcp(localhost:" + strconv.Itoa(m.cfg.Port) + ")"
|
||||
|
||||
Reference in New Issue
Block a user