I've been trying to use Symbolic Links in my swift app with no luck. Is there anything I might be missing or is this even possible to begin with?
Here is my sample code and I have been using FileKit plugin to create my symlink. I also tried it without a plugin but no luck.
I tried this first:
import FileKit
do {
try Path(Bundle.main.bundlePath + "/wwww/assets").symlinkFile(to: "/assets")
debugPrint("Success")
} catch {
debugPrint("Failed")
}
I always get the Failed
message.
I also made sure that the bundle paths are valid with this test:
debugPrint(Path(Bundle.main.bundlePath + "/wwww/assets").exists) //true
Can you guys give me any pointers?