Re: why mkdir can't create tree of dirs?

2016-02-10 Thread Suliman via Digitalmars-d-learn
On Tuesday, 9 February 2016 at 23:23:10 UTC, Jonathan M Davis 
wrote:
On Tuesday, February 09, 2016 20:20:59 Suliman via 
Digitalmars-d-learn wrote:

It's look like that I can only create one nesting level sub
folder, for example there is exists dir: D:\foo
I can't create dir D:\foo\bar\baz I can only create D:\foo\bar

D:\foo\bar

Is it's rational limit or it is bug? Here is error when I 
tried to folder in folder thet do not exists.


It's not very handy to write all levels by hands...

td.windows.syserror.WindowsException@C:\D\dmd2\windows\bin\..\..\src\phobos\stdfile.d(2048):
 F:\foo\imgs_projected\jma_vis\1602\123: ╨б╨╕╤Б╤В╨╡╨╝╨╡ ╨╜╨╡ ╤Г╨┤╨╨╡╤В╤Б╤П 
╨╜╨░╨╣╤В╨╕ ╤Г╨║╨░╨╖╨░╨╜╨╜╤Л╨╣ ╨┐╤Г╤В╤М. (error 3)


You can use std.file.mkdirRecurse instead of std.file.mkdir. 
std.file.mkdirRecurse is similar to mkdir -p like 
std.file.mkdir is similar to mkdir.


- Jonathan M Davis


What profit to split it's in two functions? Why mkdir can't work 
in recursive mode?


why mkdir can't create tree of dirs?

2016-02-09 Thread Suliman via Digitalmars-d-learn
It's look like that I can only create one nesting level sub 
folder, for example there is exists dir: D:\foo

I can't create dir D:\foo\bar\baz I can only create D:\foo\bar

D:\foo\bar

Is it's rational limit or it is bug? Here is error when I tried 
to folder in folder thet do not exists.


It's not very handy to write all levels by hands...

td.windows.syserror.WindowsException@C:\D\dmd2\windows\bin\..\..\src\phobos\stdfile.d(2048):
 F:\foo\imgs_projected\jma_vis\1602\123: ╨б╨╕╤Б╤В╨╡╨╝╨╡ ╨╜╨╡ ╤Г╨┤╨╨╡╤В╤Б╤П 
╨╜╨░╨╣╤В╨╕ ╤Г╨║╨░╨╖╨░╨╜╨╜╤Л╨╣ ╨┐╤Г╤В╤М. (error 3)


Re: why mkdir can't create tree of dirs?

2016-02-09 Thread anonymous via Digitalmars-d-learn

On Tuesday, 9 February 2016 at 20:20:59 UTC, Suliman wrote:
It's look like that I can only create one nesting level sub 
folder, for example there is exists dir: D:\foo

I can't create dir D:\foo\bar\baz I can only create D:\foo\bar


http://dlang.org/phobos/std_file.html#.mkdirRecurse


td.windows.syserror.WindowsException@C:\D\dmd2\windows\bin\..\..\src\phobos\stdfile.d(2048):
 F:\foo\imgs_projected\jma_vis\1602\123: ╨б╨╕╤Б╤В╨╡╨╝╨╡ ╨╜╨╡ ╤Г╨┤╨╨╡╤В╤Б╤П 
╨╜╨░╨╣╤В╨╕ ╤Г╨║╨░╨╖╨░╨╜╨╜╤Л╨╣ ╨┐╤Г╤В╤М. (error 3)


What's up with that garbled text?


Re: why mkdir can't create tree of dirs?

2016-02-09 Thread Wyatt via Digitalmars-d-learn

On Tuesday, 9 February 2016 at 20:20:59 UTC, Suliman wrote:
It's look like that I can only create one nesting level sub 
folder, for example there is exists dir: D:\foo

I can't create dir D:\foo\bar\baz I can only create D:\foo\bar


http://dlang.org/phobos/std_file.html#.mkdirRecurse

-Wyatt