Initial project import
This commit is contained in:
commit
23f2d29e32
11957 files changed
+1754577
No files matched your search
@@ -0,0 +1,14 @@
|
||||
import os
|
||||
|
||||
// Example usage of os.ls (in the form of top-level statements)
|
||||
println('readdir example using os.ls')
|
||||
|
||||
entries := os.ls(os.home_dir()) or { [] }
|
||||
|
||||
for entry in entries {
|
||||
if os.is_dir(os.join_path(os.home_dir(), entry)) {
|
||||
println('dir: ${entry}')
|
||||
} else {
|
||||
println('file: ${entry}')
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user