Skip to content

Commit 96634dc

Browse files
committed
chore: reformats Nix code using nixfmt
1 parent 29138eb commit 96634dc

3 files changed

Lines changed: 296 additions & 223 deletions

File tree

build.nix

Lines changed: 35 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
{ pkgs
2-
, lib
3-
, src
4-
, python
5-
, uv2nix
6-
, pyproject-nix
7-
, pyproject-build-systems
8-
, nix-utils
9-
,
1+
{
2+
pkgs,
3+
lib,
4+
src,
5+
python,
6+
uv2nix,
7+
pyproject-nix,
8+
pyproject-build-systems,
9+
nix-utils,
1010
}:
1111

1212
let
@@ -50,11 +50,17 @@ let
5050
});
5151

5252
plumbum = prev.plumbum.overrideAttrs (old: {
53-
buildInputs = old.buildInputs or [ ] ++ [ final.hatch-vcs final.hatchling ];
53+
buildInputs = old.buildInputs or [ ] ++ [
54+
final.hatch-vcs
55+
final.hatchling
56+
];
5457
});
5558

5659
pydocstyle = prev.pydocstyle.overrideAttrs (old: {
57-
buildInputs = old.buildInputs or [ ] ++ [ final.poetry-core final.setuptools ];
60+
buildInputs = old.buildInputs or [ ] ++ [
61+
final.poetry-core
62+
final.setuptools
63+
];
5864
});
5965

6066
iniconfig = prev.iniconfig.overrideAttrs (old: {
@@ -131,9 +137,7 @@ let
131137
# This behaviour is documented in PEP-660
132138
#
133139
# With Nix the dependency needs to be explicitly declared.
134-
nativeBuildInputs =
135-
old.nativeBuildInputs
136-
++ final.resolveBuildSystem { editables = [ ]; };
140+
nativeBuildInputs = old.nativeBuildInputs ++ final.resolveBuildSystem { editables = [ ]; };
137141
});
138142
})
139143
]
@@ -144,21 +148,31 @@ let
144148
# Enable all optional dependencies for development.
145149
virtualenv = editablePythonSet.mkVirtualEnv "fastapi-mvc-dev-env" workspace.deps.all;
146150

147-
sdist = (pythonSet.fastapi-mvc.override {
148-
pyprojectHook = pythonSet.pyprojectDistHook;
149-
}).overrideAttrs (_: {
150-
env.uvBuildType = "sdist";
151-
});
151+
sdist =
152+
(pythonSet.fastapi-mvc.override {
153+
pyprojectHook = pythonSet.pyprojectDistHook;
154+
}).overrideAttrs
155+
(_: {
156+
env.uvBuildType = "sdist";
157+
});
152158
wheel = pythonSet.fastapi-mvc.override {
153159
pyprojectHook = pythonSet.pyprojectDistHook;
154160
};
155161

156-
util = pyproject-nix.build.util { runCommand = pkgs.runCommand; python3 = pythonSet.python; };
162+
util = pyproject-nix.build.util {
163+
runCommand = pkgs.runCommand;
164+
python3 = pythonSet.python;
165+
};
157166
application = util.mkApplication {
158167
venv = pythonSet.mkVirtualEnv "application-env" workspace.deps.default;
159168
package = pythonSet.fastapi-mvc;
160169
};
161170
in
162171
{
163-
inherit sdist wheel virtualenv application;
172+
inherit
173+
sdist
174+
wheel
175+
virtualenv
176+
application
177+
;
164178
}

0 commit comments

Comments
 (0)