File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -57,7 +57,7 @@ public function fetchStarterKit($starterkit = "") {
5757
5858 // set default attributes
5959 $ sourceDir = Config::getOption ("sourceDir " );
60- $ tempDir = sys_get_temp_dir ();
60+ $ tempDir = sys_get_temp_dir (). DIRECTORY_SEPARATOR . " pl-sk " ;
6161 $ tempDirSK = $ tempDir .DIRECTORY_SEPARATOR ."pl-sk-archive " ;
6262 $ tempDirDist = $ tempDirSK .DIRECTORY_SEPARATOR ."dist " ;
6363 $ tempComposerFile = $ tempDirSK .DIRECTORY_SEPARATOR ."composer.json " ;
@@ -75,6 +75,14 @@ public function fetchStarterKit($starterkit = "") {
7575 $ error = error_get_last ();
7676 Console::writeError ("the starterkit wasn't downloaded because: \n\n " .$ error ["message " ]);
7777 }
78+
79+ // Create temp directory if doesn't exist
80+ $ fs = new Filesystem ();
81+ try {
82+ $ fs ->mkdir ($ tempDir , 0775 );
83+ } catch (IOExceptionInterface $ e ) {
84+ Console::writeError ("Error creating temporary directory at " . $ e ->getPath ());
85+ }
7886
7987 // write the package to the temp directory
8088 $ tempFile = tempnam ($ tempDir , "pl-sk-archive.tar.gz " );
You can’t perform that action at this time.
0 commit comments