Skip to content

Commit

Permalink
Make sure VM directory exists before moving (#111)
Browse files Browse the repository at this point in the history
  • Loading branch information
fkorotkov authored Jun 3, 2022
1 parent 63329ef commit c14b46a
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions Sources/tart/VMStorageLocal.swift
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ class VMStorageLocal {
}

func move(_ name: String, from: VMDirectory) throws {
_ = try FileManager.default.createDirectory(at: baseURL, withIntermediateDirectories: true)
_ = try FileManager.default.replaceItemAt(vmURL(name), withItemAt: from.baseURL)
}

Expand Down

0 comments on commit c14b46a

Please sign in to comment.