It works:
xcrun swift-format /Users/cavivie/Workspace/DemoSwift/Hello.swift
It does not work, and casuse an infinite loop:
xcrun swift-format /Users/cavivie/Workspace/DemoSwift//Hello.swift
xcrun swift-format /Users/cavivie/Workspace/DemoSwift/scripts/..//Hello.swift
// why candidate path output:
/Users/cavivie/Workspace/DemoSwift//Hello.swift
// I think it should be converted to:
/Users/cavivie/Workspace/DemoSwift/Hello.swift
/Users/cavivie/Workspace/DemoSwift/Hello.swift and /Users/cavivie/Workspace/DemoSwift/scripts/../Hello.swift files should be considered as one file.
Bug Line