Fix: directory not found issue
This commit is contained in:
parent
3b618215eb
commit
e8c7fe0c9c
1 changed files with 3 additions and 0 deletions
|
@ -12,6 +12,9 @@
|
|||
<Task>
|
||||
<Using Namespace="System.IO" />
|
||||
<Code Type="Fragment" Language="cs">
|
||||
var dir = Path.GetDirectoryName(Path);
|
||||
if(!string.IsNullOrEmpty(dir))
|
||||
Directory.CreateDirectory(dir);
|
||||
File.WriteAllText(Path, Content);
|
||||
</Code>
|
||||
</Task>
|
||||
|
|
Loading…
Add table
Reference in a new issue