From d46d8e84634a7a2b15274c023c2134ea49d4d953 Mon Sep 17 00:00:00 2001 From: Elias Kleppinger Date: Thu, 7 Nov 2024 21:43:36 +0100 Subject: [PATCH] Compiler angepasst! --- .gitignore | 2 +- build/.gitkeep | 0 .../Commands/Development/CompilePlatformCommand.php | 9 +++++++-- bin/versa => versa | 2 +- 4 files changed, 9 insertions(+), 4 deletions(-) delete mode 100644 build/.gitkeep rename bin/versa => versa (55%) diff --git a/.gitignore b/.gitignore index 2b85a1c..effdd33 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,4 @@ vendor/ composer.lock .idea/ -*.phar \ No newline at end of file +build/ \ No newline at end of file diff --git a/build/.gitkeep b/build/.gitkeep deleted file mode 100644 index e69de29..0000000 diff --git a/src/Console/Commands/Development/CompilePlatformCommand.php b/src/Console/Commands/Development/CompilePlatformCommand.php index aa6269c..6d7b858 100644 --- a/src/Console/Commands/Development/CompilePlatformCommand.php +++ b/src/Console/Commands/Development/CompilePlatformCommand.php @@ -20,11 +20,16 @@ class CompilePlatformCommand extends Command protected function execute(InputInterface $input, OutputInterface $output): int { // Deine Logik für den Compiler - $output->writeln('Starte den Compiler...'); + $output->writeln("Kompiliere die Platform..."); + + // mkdirs + if (!is_dir(__DIR__ . "/../../../../" . 'build')) { + mkdir(__DIR__ . "/../../../../" .'build'); + } $compiler = new Compiler(__DIR__ . "/../../../../"); - $compiler->addIndexFile("bin/versa"); + $compiler->addIndexFile("versa"); $compiler->addFile("composer.json"); $compiler->addDirectory("src", '!*.php'); $compiler->addDirectory("vendor"); diff --git a/bin/versa b/versa similarity index 55% rename from bin/versa rename to versa index 25931d9..f2b2d8e 100644 --- a/bin/versa +++ b/versa @@ -1,4 +1,4 @@ run(); \ No newline at end of file