Open n8henrie opened 1 year ago
I have a "line too long" error thrown by pkgs.writers.writePythonApplication that I'm working around by changing
pkgs.writers.writePythonApplication
''"${thisLongNixPath}"'' into
''"${thisLongNixPath}"''
''( "${thisLongNixPath}" )';'
as the newline break should put the long string under the line length limit.
Unfortunately, alejandra keeps adding a bunch of whitespace before the ( and the "${:
(
"${
$ diff flake.nix <(alejandra -q <flake.nix ) 35,37c35,37 < ''( < "${chromium}/Chromium.app/Contents/MacOS/Chromium" < ) --- > '' ( > "${chromium}/Chromium.app/Contents/MacOS/Chromium" > )
I think that's because this is surrounded in a square bracket, and it seems to want to align the inner parentheses to the outer square bracket, but this kind of alignment within a string perhaps shouldn't happen:
Pre:
replacements = [ "--replace" ''"./Chromium.app/Contents/MacOS/Chromium"'' ''( "${chromium}/Chromium.app/Contents/MacOS/Chromium" ) '' ];
Post:
replacements = [ "--replace" ''"./Chromium.app/Contents/MacOS/Chromium"'' '' ( "${chromium}/Chromium.app/Contents/MacOS/Chromium" ) '' ];
I have a "line too long" error thrown by
pkgs.writers.writePythonApplication
that I'm working around by changing''"${thisLongNixPath}"''
intoas the newline break should put the long string under the line length limit.
Unfortunately, alejandra keeps adding a bunch of whitespace before the
(
and the"${
:I think that's because this is surrounded in a square bracket, and it seems to want to align the inner parentheses to the outer square bracket, but this kind of alignment within a string perhaps shouldn't happen:
Pre:
Post: