diff --git a/modules/build/src/main/scala/scala/build/ResourceMapper.scala b/modules/build/src/main/scala/scala/build/NativeResourceMapper.scala similarity index 93% rename from modules/build/src/main/scala/scala/build/ResourceMapper.scala rename to modules/build/src/main/scala/scala/build/NativeResourceMapper.scala index 8848d7178c..666168bac7 100644 --- a/modules/build/src/main/scala/scala/build/ResourceMapper.scala +++ b/modules/build/src/main/scala/scala/build/NativeResourceMapper.scala @@ -3,13 +3,13 @@ package scala.build import scala.collection.Map import scala.jdk.CollectionConverters._ -/* Maps resources from their original path, to destination path, +/* Maps c file resources from their original path to the destination path, * also caching that mapping. * * Remembering the mapping this way allows for the resource to be removed * if the original file is renamed/deleted. */ -object ResourceMapper { +object NativeResourceMapper { private def readMappingIfExists(mappingFile: os.Path): Option[Map[os.Path, os.Path]] = if (os.exists(mappingFile)) { @@ -52,7 +52,7 @@ object ResourceMapper { val removedFiles = oldMapping.values.toSet -- newMapping.values.toSet removedFiles.foreach { outputPath => - // Delete only if in outpath, to not cause any harm + // Delete only if in outpath, to avoid causing any harm if (isInDirectory(build.output, outputPath)) os.remove(outputPath) } diff --git a/modules/cli/src/main/scala/scala/cli/commands/Package.scala b/modules/cli/src/main/scala/scala/cli/commands/Package.scala index c85dea58a3..50482b70f8 100644 --- a/modules/cli/src/main/scala/scala/cli/commands/Package.scala +++ b/modules/cli/src/main/scala/scala/cli/commands/Package.scala @@ -888,7 +888,7 @@ object Package extends ScalaCommand[PackageOptions] { ) if (cacheData.changed) { - ResourceMapper.copyCFilesToScalaNativeDir(build, nativeWorkDir) + NativeResourceMapper.copyCFilesToScalaNativeDir(build, nativeWorkDir) Library.withLibraryJar(build, dest.last.stripSuffix(".jar")) { mainJar => val classpath = build.artifacts.classPath.map(_.toString) :+ mainJar.toString