refactor(nix): rely more on setup hooks in dev shell
Signed-off-by: Seth Flynn <getchoo@tuta.io> (cherry picked from commit de923a07d8a4b7c9f8cd688b9682587c78116e14)
This commit is contained in:
parent
760fbdf54f
commit
ddcd61c808
12
flake.nix
12
flake.nix
@ -121,18 +121,18 @@
|
||||
llvm.clang-tools
|
||||
];
|
||||
|
||||
cmakeFlags = packages'.prismlauncher-unwrapped.cmakeFlags ++ [
|
||||
"-GNinja"
|
||||
"-Bbuild"
|
||||
];
|
||||
cmakeBuildType = "Debug";
|
||||
cmakeFlags = [ "-GNinja" ] ++ packages'.prismlauncher.cmakeFlags;
|
||||
dontFixCmake = true;
|
||||
|
||||
shellHook = ''
|
||||
echo "Sourcing ${qt-wrapper-env}"
|
||||
source ${qt-wrapper-env}
|
||||
|
||||
if [ ! -f compile_commands.json ]; then
|
||||
cmake $cmakeFlags -D CMAKE_BUILD_TYPE=Debug
|
||||
ln -s {build/,}compile_commands.json
|
||||
cmakeConfigurePhase
|
||||
cd ..
|
||||
ln -s "$cmakeBuildDir"/compile_commands.json compile_commands.json
|
||||
fi
|
||||
'';
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user