Skip to content

[lint-monster] LintMonster: includes parameter-count cleanup #54127

Description

@github-actions

Summary

Daily make golint-custom surfaced a parameter-count finding in pkg/cli.

Current findings: 1

Affected path:

  • pkg/cli/includes.go:602fetchAndSaveRemoteIncludesWithOptions has 9 parameters (limit: 8)

Representative diagnostic:

  • pkg/cli/includes.go:602:6: fetchAndSaveRemoteIncludesWithOptions has 9 parameters (limit: 8); consider using an options struct

Expected outcome

Refactor the call boundary to reduce parameter count, preferably by introducing a narrow options/config struct or by consolidating logically related arguments, while preserving behavior.

Remediation checklist

  • Keep remediation scoped to the parameter-count finding in pkg/cli/includes.go only.
  • Prefer a minimal options struct or equivalent argument consolidation.
  • Preserve current behavior and existing tests.
  • Validate with make golint-custom after changes.
  • Avoid bundling unrelated cleanup.

Copilot instructions

  1. Work only on fetchAndSaveRemoteIncludesWithOptions and its direct call sites.
  2. Replace the 9-parameter signature with a smaller, clearer argument surface.
  3. Prefer minimal, local edits over broader redesign.
  4. Do not take on any largefunc or mutable-state findings in this issue.
  5. Validate with make golint-custom before finishing.

Generated by 🧌 LintMonster · gpt54 · 33.2 AIC · ⌖ 6.66 AIC · ⊞ 6K ·

  • expires on Aug 26, 2026, 6:53 PM UTC-08:00

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions