File tree 1 file changed +9
-19
lines changed
1 file changed +9
-19
lines changed Original file line number Diff line number Diff line change 3
3
lib ? pkgs . lib ,
4
4
} :
5
5
let
6
- # This project's `.gitignore` implemented for cleanSource.
7
- filterGitignore =
8
- orig_path : type :
9
- let
10
- baseName = baseNameOf ( toString orig_path ) ;
11
- in
12
- ! ( baseName == "target" && type == "directory" )
13
- || lib . hasSuffix ".rs.bk" baseName
14
- || baseName == ".nixos-test-history"
15
- || ( baseName == ".direnv" && type == "directory" ) ;
16
-
17
- cleanSourceWithGitignore =
18
- src :
19
- lib . cleanSourceWith {
20
- src = lib . cleanSource src ;
21
- filter = filterGitignore ;
22
- } ;
23
-
24
6
cargoManifest = ( pkgs . lib . importTOML ./Cargo.toml ) . package ;
25
7
in
26
8
{
36
18
rustPlatform . buildRustPackage {
37
19
pname = "system-manager" ;
38
20
version = cargoManifest . version ;
39
- src = cleanSourceWithGitignore ./. ;
21
+ src = lib . fileset . toSource {
22
+ root = ./. ;
23
+ fileset = lib . fileset . unions [
24
+ ./Cargo.toml
25
+ ./Cargo.lock
26
+ ./src
27
+ ] ;
28
+ } ;
29
+
40
30
cargoLock . lockFile = ./Cargo.lock ;
41
31
buildInputs = [ dbus ] ;
42
32
nativeBuildInputs = [
You can’t perform that action at this time.
0 commit comments