shenshihai 3 년 전
부모
커밋
42945d2640
1개의 변경된 파일4개의 추가작업 그리고 0개의 파일을 삭제
  1. 4 0
      src/Utility.php

+ 4 - 0
src/Utility.php

@@ -199,6 +199,10 @@ function replaceMacro(string $filePath,string $targetPath,array $macros){
 	foreach($macros as $key=>$value){
 		$content = str_replace($key,$value,$content);
 	}
+	$targetDir = dirname($targetPath);
+	if(!is_dir($targetDir)){
+		createDirectory($targetDir);
+	}
 	return file_put_contents($targetPath,$content);
 }