Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/main/scala/com/typesafe/sbt/SbtStartScript.scala
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ object SbtStartScript extends Plugin {
// Generate shell script that calculates path to project directory from its own path.
private def scriptRootDetect(baseDirectory: File, scriptFile: File, otherFile: Option[File]): String = {
val baseDir = baseDirectory.getCanonicalPath
val scriptDir = scriptFile.getParentFile.getCanonicalPath
val scriptDir = scriptFile.getParentFile.getPath
val pathFromScriptDirToBaseDir = if (scriptDir startsWith (baseDir + File.separator)) {
val relativePath = scriptDir drop (baseDir.length + 1)
var parts = relativePath split Pattern.quote(File.separator)
Expand Down