Skip to content

Commit 5b88d1e

Browse files
authored
Fix installLocalCache target file (#5067)
Pull request: #5067
1 parent 329658d commit 5b88d1e

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

dist/package.mill

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ trait DistModule extends Module {
2525

2626
def localBinName: String
2727

28-
def cacheBinarySuffix: String = ""
28+
def cacheBinarySuffix: Task[String] = Task.Anon("")
2929

3030
/**
3131
* Build and install Mill locally.
@@ -43,7 +43,7 @@ trait DistModule extends Module {
4343
def installLocalCache() = Task.Command {
4444
val path = installLocalTask(
4545
Task.Anon(
46-
(os.home / ".cache/mill/download" / (build.millVersion() + cacheBinarySuffix + batExt)).toString()
46+
(os.home / ".cache/mill/download" / (build.millVersion() + cacheBinarySuffix() + batExt)).toString()
4747
)
4848
)()
4949
Task.log.streams.out.println(path.toString())
@@ -261,7 +261,7 @@ object `package` extends MillJavaModule with DistModule {
261261

262262
def localBinName = "mill-native"
263263

264-
def cacheBinarySuffix = "-native"
264+
def cacheBinarySuffix = Task.Anon { s"-native-${artifactOsSuffix()}-${artifactCpuSuffix()}" }
265265

266266
def executableRaw = nativeImage()
267267

0 commit comments

Comments
 (0)