refactor: improve ssh based repo handling #2
Trunk Check
Checked 72 modified files
1 non-blocking issue
39 existing issues (use --show-existing to see them)
✔ No new issues
Details
To reproduce and test locally, run:
trunk check
For help resolving these issues, see our docs on running on PRs or debugging Trunk Check
Annotations
Check notice on line 260 in cmd/new.go
github-actions / Trunk Check
trunk(ignore-does-nothing)
[new] trunk-ignore(golangci-lint/funlen) is not suppressing a lint issue
Check warning on line 24 in cmd/init.go
github-actions / Trunk Check
golangci-lint(revive)
[existing] unused-parameter: parameter 'cmd' seems to be unused, consider removing or renaming it as _
Check warning on line 67 in cmd/init.go
github-actions / Trunk Check
golangci-lint(revive)
[existing] unused-parameter: parameter 'toComplete' seems to be unused, consider removing or renaming it as _
Check failure on line 62 in cmd/init.go
github-actions / Trunk Check
golangci-lint(varnamelen)
[existing] variable name 'qs' is too short for the scope of its usage
Check failure on line 14 in cmd/init.go
github-actions / Trunk Check
golangci-lint(gochecknoglobals)
[existing] initCmd is a global variable
Check failure on line 85 in cmd/init.go
github-actions / Trunk Check
golangci-lint(gosec)
[existing] G204: Subprocess launched with a potential tainted input or cmd arguments
Check warning on line 82 in cmd/init.go
github-actions / Trunk Check
golangci-lint(revive)
[existing] deep-exit: calls to os.Exit only in main() or init() functions
Check failure on line 30 in cmd/init.go
github-actions / Trunk Check
golangci-lint(gochecknoinits)
[existing] don't use `init` function
Check warning on line 160 in cmd/new.go
github-actions / Trunk Check
golangci-lint(revive)
[existing] add-constant: avoid magic numbers like '6', create a named constant for it
Check warning on line 617 in cmd/new.go
github-actions / Trunk Check
golangci-lint(revive)
[existing] add-constant: string literal "error opening repository: %v" appears, at least, 3 times, create a named constant for it
Check warning on line 611 in cmd/new.go
github-actions / Trunk Check
golangci-lint(revive)
[existing] cognitive-complexity: function DynamicScopeSuggestion has cognitive complexity 13 (> max enabled 7)
Check warning on line 353 in cmd/new.go
github-actions / Trunk Check
golangci-lint(revive)
[existing] add-constant: avoid magic numbers like '0', create a named constant for it
Check failure on line 322 in cmd/new.go
github-actions / Trunk Check
golangci-lint(gocritic)
[existing] ifElseChain: rewrite if-else to switch statement
Check failure on line 112 in cmd/new.go
github-actions / Trunk Check
golangci-lint(unused)
[existing] var `commit` is unused
Check failure on line 310 in cmd/new.go
github-actions / Trunk Check
golangci-lint(nestif)
[existing] `if detectMaster && detectMain` has complex nested blocks (complexity: 5)
Check failure on line 142 in cmd/new.go
github-actions / Trunk Check
golangci-lint(varnamelen)
[existing] variable name 'nf' is too short for the scope of its usage
Check warning on line 315 in cmd/new.go
github-actions / Trunk Check
golangci-lint(revive)
[existing] unused-parameter: parameter 'toComplete' seems to be unused, consider removing or renaming it as _
Check failure on line 538 in cmd/new.go
github-actions / Trunk Check
golangci-lint(staticcheck)
[existing] SA1019: pterm.NewLettersFromString is deprecated: use putils.LettersFromString instead.
Check warning on line 404 in cmd/new.go
github-actions / Trunk Check
golangci-lint(revive)
[existing] cognitive-complexity: function createPR has cognitive complexity 18 (> max enabled 7)
Check warning on line 89 in cmd/new.go
github-actions / Trunk Check
golangci-lint(revive)
[existing] add-constant: string literal " " appears, at least, 3 times, create a named constant for it
Check failure on line 596 in cmd/new.go
github-actions / Trunk Check
golangci-lint(prealloc)
[existing] Consider pre-allocating `scopes`
Check failure on line 645 in cmd/new.go
github-actions / Trunk Check
golangci-lint(prealloc)
[existing] Consider pre-allocating `scopes`
Check warning on line 651 in cmd/new.go
github-actions / Trunk Check
golangci-lint(revive)
[existing] add-constant: avoid magic numbers like '1', create a named constant for it
Check warning on line 261 in cmd/new.go
github-actions / Trunk Check
golangci-lint(revive)
[existing] cognitive-complexity: function getUpstreamBranch has cognitive complexity 15 (> max enabled 7)
Check warning on line 558 in cmd/new.go
github-actions / Trunk Check
golangci-lint(revive)
[existing] cognitive-complexity: function GetScopesInLastMonths has cognitive complexity 11 (> max enabled 7)