nim-lang / Nim

Nim is a statically typed compiled systems programming language. It combines successful concepts from mature languages like Python, Ada and Modula. Its design focuses on efficiency, expressiveness, and elegance (in that order of priority).
https://nim-lang.org
Other
16.55k stars 1.47k forks source link

Feature request: copy dir function in nimscript #7393

Closed mratsim closed 6 years ago

mratsim commented 6 years ago

I don't see a cpDir function in Nimscript in both the docs and source code.

Trying to use os didn't work:

from os import copyDir

copyDir("./foo/", "./bar/")
# Error: cannot 'importc' variable at compile time
cooldome commented 6 years ago

here is an example how it can be implemented: https://github.com/nim-lang/Nim/pull/7284

genotrance commented 6 years ago

I'm planning on adding the following procs to nimscript with the equivalent proc name from the os module.