Skip to content

Commit

Permalink
Ensure to also reset any Git untracked files
Browse files Browse the repository at this point in the history
  • Loading branch information
Jeehut committed Apr 19, 2019
1 parent f607f57 commit 94323c1
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ extension DependencyInstaller {
if try FileManager.default.isDirectory(atPath: frameworkCheckoutPath) {
try bash("git -C '\(frameworkCheckoutPath)' reset HEAD --hard --quiet 2> /dev/null")
try bash("git -C '\(frameworkCheckoutPath)' clean -fd --quiet 2> /dev/null")
try bash("git -C '\(frameworkCheckoutPath)' clean -fdX --quiet 2> /dev/null")
}
}
}
Expand Down
1 change: 1 addition & 0 deletions Sources/AccioKit/Services/CarthageBuilderService.swift
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ final class CarthageBuilderService {
try bash("rm -rf '\(framework.projectDirectory)/Carthage/Build'")
try bash("git -C '\(framework.projectDirectory)' reset HEAD --hard --quiet 2> /dev/null")
try bash("git -C '\(framework.projectDirectory)' clean -fd --quiet 2> /dev/null")
try bash("git -C '\(framework.projectDirectory)' clean -fdX --quiet 2> /dev/null")

guard FileManager.default.fileExists(atPath: frameworkProduct.frameworkDirPath) && FileManager.default.fileExists(atPath: frameworkProduct.symbolsFilePath) else {
print("Failed to build products to \(platformBuildDir)/\(framework.libraryName).framework(.dSYM).", level: .error)
Expand Down

0 comments on commit 94323c1

Please sign in to comment.