Live location tracking and playback for the game "manhunt"

Better workspace splitting in Nix

bwc9876.dev 1125fe47 388c1505

verified
+13 -25
+7 -12
nix/packages/manhunt-signaling.nix
··· 6 rustPlatform.buildRustPackage { 7 pname = "manhunt-signaling"; 8 version = "0.1.0"; 9 - src = with lib.fileset; 10 - toSource { 11 - root = ../../.; 12 - fileset = unions [ 13 - ../../Cargo.toml 14 - ../../Cargo.lock 15 - ../../backend 16 - ../../manhunt-signaling 17 - ]; 18 - }; 19 cargoLock.lockFile = ../../Cargo.lock; 20 - buildAndTestSubdir = "manhunt-signaling"; 21 22 postCheck = '' 23 - cargo clippy -p manhunt-signaling --no-deps -- -D warnings 24 ''; 25 26 nativeBuildInputs = [clippy];
··· 6 rustPlatform.buildRustPackage { 7 pname = "manhunt-signaling"; 8 version = "0.1.0"; 9 + src = ../../manhunt-signaling; 10 cargoLock.lockFile = ../../Cargo.lock; 11 + 12 + postPatch = '' 13 + cp ${../../Cargo.lock} Cargo.lock 14 + chmod +w Cargo.lock 15 + ''; 16 17 postCheck = '' 18 + cargo clippy --no-deps -- -D warnings 19 ''; 20 21 nativeBuildInputs = [clippy];
+6 -13
nix/packages/manhunt.nix
··· 16 rustPlatform.buildRustPackage { 17 pname = "manhunt"; 18 version = "0.1.0"; 19 - src = with lib.fileset; 20 - toSource { 21 - root = ../../.; 22 - fileset = unions [ 23 - ../../Cargo.toml 24 - ../../Cargo.lock 25 - ../../backend 26 - ../../manhunt-signaling 27 - ]; 28 - }; 29 cargoLock.lockFile = ../../Cargo.lock; 30 - buildAndTestSubdir = "backend"; 31 buildFeatures = [ 32 "tauri/custom-protocol" 33 ]; 34 35 postCheck = '' 36 - cargo clippy -p backend --no-deps -- -D warnings 37 ''; 38 39 nativeBuildInputs = [ ··· 53 ]; 54 55 postPatch = '' 56 - substituteInPlace backend/tauri.conf.json \ 57 --replace '"frontendDist": "../frontend/dist"' '"frontendDist": "${manhunt-frontend}"' 58 ''; 59
··· 16 rustPlatform.buildRustPackage { 17 pname = "manhunt"; 18 version = "0.1.0"; 19 + src = ../../backend; 20 cargoLock.lockFile = ../../Cargo.lock; 21 buildFeatures = [ 22 "tauri/custom-protocol" 23 ]; 24 25 postCheck = '' 26 + cargo clippy --no-deps -- -D warnings 27 ''; 28 29 nativeBuildInputs = [ ··· 43 ]; 44 45 postPatch = '' 46 + cp ${../../Cargo.lock} Cargo.lock 47 + chmod +w Cargo.lock 48 + 49 + substituteInPlace tauri.conf.json \ 50 --replace '"frontendDist": "../frontend/dist"' '"frontendDist": "${manhunt-frontend}"' 51 ''; 52