Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion src/FlakeTemplate.hs
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,6 @@ flakeTemplate = [r|{
devShells.default = import ./shell.nix { $shell_args;separator=' '$ };
}
);
}|]
}

|]
1 change: 1 addition & 0 deletions src/ShellifyTemplate.hs
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,5 @@ $if(shell_hook)$
'';
$endif$
}

|]
6 changes: 1 addition & 5 deletions test/TestHelpers.hs
Original file line number Diff line number Diff line change
Expand Up @@ -136,11 +136,7 @@ theOptions = options "nix-shellify" . words
instance Show Options

readNixTemplate :: FilePath -> IO Text
readNixTemplate fileName =
stripTrailingNewline <$> readFile ("test/outputs/" <> fileName)
where stripTrailingNewline f = bool id stripLastChar (lastCharIsNewline f) f
lastCharIsNewline = (== '\n') . last
stripLastChar = reverse . tail . reverse
readNixTemplate fileName = readFile ("test/outputs/" <> fileName)

flakeFile = (<> "-flake.nix")
shellFile = (<> "-shell.nix")
Expand Down