Created
January 31, 2023 21:29
-
-
Save aliabbas90/7d98fc3759b162d4f4af6c5b1630a7a5 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let fm = FileManager.default | |
let path = Bundle.main.resourcePath! | |
do { | |
let items = try fm.contentsOfDirectory(atPath: path) | |
for item in items { | |
print("Found \(item)") | |
} | |
} catch { | |
// failed to read directory – bad permissions, perhaps? | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment