mirror of https://github.com/winsw/winsw
feat: Create directory hierarchy if not exists
parent
6cf303c1d3
commit
9a6ce2ce44
|
@ -12,6 +12,7 @@ namespace WinSW.Util
|
||||||
{
|
{
|
||||||
public static void MoveOrReplaceFile(string sourceFileName, string destFileName)
|
public static void MoveOrReplaceFile(string sourceFileName, string destFileName)
|
||||||
{
|
{
|
||||||
|
new FileInfo(destFileName).Directory?.Create();
|
||||||
#if NET
|
#if NET
|
||||||
File.Move(sourceFileName, destFileName, true);
|
File.Move(sourceFileName, destFileName, true);
|
||||||
#else
|
#else
|
||||||
|
|
Loading…
Reference in New Issue