Commit 3ffe41e
committed
chore(sonar): address 124 Go-side code smells (5.5 lane)
Per-rule (Go only — PHP/Blade/Docker/YAML smells deferred):
- S1192 (string-literal dup → const): 104
- S3776 (cognitive complexity → split): 14
- S1186 (empty function literals): 5
- S4144 (duplicate implementations): 1
Plus 14 mechanical golangci-lint findings cleaned during verification.
Out of scope (489 of 613 smells remain):
- 489 PHP/Blade/Docker/YAML rules — this lane's brief was Go-only.
Snider can dispatch a PHP-shaped lane separately.
- 132 security hotspots — read-only token, marking SAFE/etc out of scope.
Known debt (NOT introduced by this lane, kept to maintain build):
- go.mod has 'replace dappco.re/go/{cli,i18n} => ./internal/{clishim,
i18nshim}'. The php repo's code uses cobra-style cli.Command{Use,RunE}
which dappco.re/go/cli doesn't expose. Real fix is to port
cmd_*.go to use the real cli API. Tracked as separate refactor.
Verification: vet/test/golangci-lint clean with GOFLAGS=-mod=mod.1 parent 41a86e0 commit 3ffe41e
40 files changed
Lines changed: 1449 additions & 1215 deletions
File tree
- internal
- clishim/pkg/cli
- i18nshim
- pkg/php
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
69 | 69 | | |
70 | 70 | | |
71 | 71 | | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
452 | 452 | | |
453 | 453 | | |
454 | 454 | | |
455 | | - | |
| 455 | + | |
| 456 | + | |
| 457 | + | |
456 | 458 | | |
457 | 459 | | |
458 | 460 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| 9 | + | |
| 10 | + | |
9 | 11 | | |
10 | | - | |
| 12 | + | |
11 | 13 | | |
12 | 14 | | |
13 | 15 | | |
| |||
31 | 33 | | |
32 | 34 | | |
33 | 35 | | |
34 | | - | |
| 36 | + | |
35 | 37 | | |
36 | 38 | | |
37 | 39 | | |
| |||
46 | 48 | | |
47 | 49 | | |
48 | 50 | | |
49 | | - | |
| 51 | + | |
50 | 52 | | |
51 | 53 | | |
52 | 54 | | |
53 | 55 | | |
54 | 56 | | |
55 | 57 | | |
56 | 58 | | |
57 | | - | |
| 59 | + | |
58 | 60 | | |
59 | 61 | | |
60 | 62 | | |
| |||
69 | 71 | | |
70 | 72 | | |
71 | 73 | | |
72 | | - | |
| 74 | + | |
73 | 75 | | |
74 | 76 | | |
75 | 77 | | |
| |||
0 commit comments