Skip to content

Commit

Permalink
chore(sbt): Remove a superfluous absoluteFile conversion
Browse files Browse the repository at this point in the history
The `pomFile` already is absolute.

Signed-off-by: Sebastian Schuberth <[email protected]>
  • Loading branch information
sschuberth committed Feb 27, 2024
1 parent 52effe5 commit 55e08aa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion plugins/package-managers/sbt/src/main/kotlin/Sbt.kt
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ class Sbt(
}

private fun moveGeneratedPom(pomFile: File): Result<File> {
val targetDirParent = pomFile.absoluteFile.parentFile.searchUpwardsForSubdirectory("target")
val targetDirParent = pomFile.parentFile.searchUpwardsForSubdirectory("target")
?: return Result.failure(IllegalArgumentException("No target subdirectory found for '$pomFile'."))
val targetFilename = pomFile.relativeTo(targetDirParent).invariantSeparatorsPath.replace('/', '-')
val targetFile = targetDirParent.resolve(targetFilename)
Expand Down

0 comments on commit 55e08aa

Please sign in to comment.