mirror of
https://github.com/Smaug123/AdventOfCode2022
synced 2025-12-16 02:15:39 +00:00
Tidy nix things into a separate folder (#50)
This commit is contained in:
@@ -49,7 +49,7 @@
|
||||
runtimeIds = map (system: pkgs.dotnetCorePackages.systemToDotnetRid system) dotnet-sdk.meta.platforms;
|
||||
in
|
||||
pkgs.writeShellScript "fetch-${pname}-deps" (builtins.readFile (pkgs.substituteAll {
|
||||
src = ./fetchDeps.sh;
|
||||
src = ./nix/fetchDeps.sh;
|
||||
pname = pname;
|
||||
binPath = pkgs.lib.makeBinPath [pkgs.coreutils dotnet-sdk (pkgs.nuget-to-nix.override {inherit dotnet-sdk;})];
|
||||
projectFiles = toString (pkgs.lib.toList projectFile);
|
||||
@@ -67,7 +67,7 @@
|
||||
version = version;
|
||||
src = ./.;
|
||||
projectFile = projectFile;
|
||||
nugetDeps = ./deps.nix;
|
||||
nugetDeps = ./nix/deps.nix;
|
||||
doCheck = true;
|
||||
dotnet-sdk = dotnet-sdk;
|
||||
dotnet-runtime = dotnet-runtime;
|
||||
|
||||
18
install.sh
18
install.sh
@@ -1,18 +0,0 @@
|
||||
#!/bin/bash
|
||||
runHook preInstall
|
||||
target="${out:?}/lib/dotnet/@pname@"
|
||||
mkdir -p "$target"
|
||||
cp -rv @outputFiles@ AdventOfCode2022.App/bin/Release/net7.0/publish/* "$target"
|
||||
pushd "$out" || exit 1
|
||||
remove-duplicated-dlls.sh
|
||||
popd || exit 2
|
||||
set -f
|
||||
exe="$target/AdventOfCode2022.App"
|
||||
[ -f "$exe" ] || exit 3
|
||||
mkdir -p "$out"/bin
|
||||
commandName="$(basename -s .exe "$(echo "$exe" | tr "[:upper:]" "[:lower:]")")"
|
||||
makeWrapper \
|
||||
"$exe" \
|
||||
"$out/bin/$commandName"
|
||||
|
||||
runHook postInstall
|
||||
Reference in New Issue
Block a user