Skip to content

Commit 0ea6368

Browse files
committed
Use Path.Combine to escape spaces in UserProfile
#1829
1 parent 1e89b91 commit 0ea6368

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

build/scripts/Paths.fsx

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -205,19 +205,18 @@ module Tooling =
205205
member this.OperatingSystem = parts.[4]
206206
member this.Alias = parts.[5]
207207

208-
member this.Location =
209-
sprintf "%s/.dnx/runtimes/dnx-%s-%s-%s.%s"
210-
userProfileDir
211-
this.Runtime
208+
member this.Location = Path.Combine(userProfileDir,
209+
sprintf ".dnx/runtimes/dnx-%s-%s-%s.%s"
210+
this.Runtime
212211
this.OperatingSystem
213212
this.Architecture
214-
this.Version
213+
this.Version)
215214

216215
member this.Process proc =
217216
sprintf "%s/bin/%s" this.Location proc
218217

219218
type DnvmTooling() =
220-
let dnvmUserLocation = sprintf "%s/.dnx/bin/dnvm.cmd" userProfileDir
219+
let dnvmUserLocation = Path.Combine(userProfileDir, ".dnx/bin/dnvm.cmd")
221220
let dnvmProgramFilesLocation = "C:/Program Files/Microsoft DNX/Dnvm/dnvm.cmd"
222221
let dnvm =
223222
match fileExists dnvmUserLocation with

0 commit comments

Comments
 (0)