Skip to content

Commit

Permalink
Update publish jar script to latest
Browse files Browse the repository at this point in the history
Signed-off-by: Avimitin <dev@avimit.in>
  • Loading branch information
Avimitin committed Feb 26, 2025
1 parent bb30aa0 commit 70e6c99
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions overlays/mill-flows/publish-mill-jar.nix
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ let
runHook preInstall
mkdir -p $out/.ivy2
mv $NIX_MILL_HOME/.ivy2/local $out/.ivy2/
mv $NIX_MILL_HOME/.ivy2/local $out/
runHook postInstall
'';
Expand All @@ -44,11 +44,11 @@ let
# Fix reproducibility
# https://github.com/chipsalliance/chisel/issues/4666
find $out/.ivy2/local -wholename '*/docs/*.jar' -type f -delete
find $out/local -wholename '*/docs/*.jar' -type f -delete
# Align datetime
export SOURCE_DATE_EPOCH=1669810380
find $out/.ivy2/local -type f -name '*.jar' -exec '${add-determinism}/bin/add-determinism' -j "$NIX_BUILD_CORES" '{}' ';'
find $out/local -type f -name '*.jar' -exec '${add-determinism}/bin/add-determinism' -j "$NIX_BUILD_CORES" '{}' ';'
runHook postFixup
'';
Expand All @@ -63,10 +63,10 @@ let
}
(writeText "mill-setup-hook" ''
setup${name}IvyLocalRepo() {
mkdir -p "$NIX_MILL_HOME/.ivy2/local"
${lndir}/bin/lndir "${self}/.ivy2/local" "$NIX_MILL_HOME/.ivy2/local"
mkdir -p "$NIX_COURSIER_DIR/local"
${lndir}/bin/lndir "${self}/local" "$NIX_COURSIER_DIR/local"
echo "Copy ivy repo to $NIX_MILL_HOME"
echo "Copy ivy repo to $NIX_COURSIER_DIR"
}
postUnpackHooks+=(setup${name}IvyLocalRepo)
Expand Down

0 comments on commit 70e6c99

Please sign in to comment.