swiftly icon indicating copy to clipboard operation
swiftly copied to clipboard

Replace Foundation file operations with NIOFileSystem

Open adam-fowler opened this issue 1 year ago • 3 comments

adam-fowler avatar Jun 19 '24 08:06 adam-fowler

What are the benefits to swiftly from switching to NIOFilesystem? One reason appears to be that the operations are asynchronous, which could work well with the async codebase here.

cmcgee1024 avatar Jun 28 '24 14:06 cmcgee1024

One reason appears to be that the operations are asynchronous, which could work well with the async codebase here.

That's pretty much it. It is currently the only fully async file system we have in Swift.

adam-fowler avatar Jun 28 '24 14:06 adam-fowler

It looks like NIOFilesystem uses FilePath from System(Package), which is nice in the sense that it preserves the OS native path structure instead of normalizing to a URL, or using a bare string without the path arithmetic operations. We could start with sweeping all of the URL paths, changing them into FilePaths.

cmcgee1024 avatar Sep 12 '24 19:09 cmcgee1024