Skip to content

Avoid the indented-string warning in the Radar swap layout #695

Description

@TyceHerrman

Nova emits a
broken-string-indentation warning at
flake.nix:740

The Radar replacement string starts with sidebar = ''{. Because the opening
brace is on the first line, it participates in indentation calculation and
prevents the intended stripping of indentation. This is nonfatal, but it adds
warnings to downstream package and Home Manager evaluations.

Reproduction

run:

nix-instantiate --parse flake.nix > /dev/null

Lix reports that text on the first line of the multiline string disables
indentation stripping and points to the opening brace.

Proposed fix

Start the content on the next line and indent the block consistently:

sidebar = ''
  {
    plugin location="radar"
  }
'';

Keep the existing pkgs.replaceVars call and Radar layout structure. Update
the repository's LOC scorecard for the two additional source lines.

Validation and acceptance

A local patch against 352f1f77d97a82cd4e0769b90a02d0b26a571fc5 passed Nix
parsing. Evaluating the corrected string produced no warning, and substituting
it into layout.swap.kdl preserved the existing non-whitespace token sequence.
This verifies parsing and the intended whitespace-only change; it is not a
full package build or interactive layout test.

Acceptance: package evaluation no longer emits this indentation warning, and
the existing layout check still accepts both open and collapsed Radar layouts.

The previously merged #624 addressed
a different indented string in the old Home Manager module.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions