zl程序教程

您现在的位置是:首页 >  其他

当前栏目

[Golang]解决 os.Mkdir的时候出现 The system cannot find the path specified

2023-02-18 15:36:51 时间

这是因为创建的目录是多级目录

创建多级目录应该使用

os.MkdirAll(fildDir, os.ModePerm)

就可以解决