1
0
mirror of https://github.com/restoreddev/phpapprentice.git synced 2025-08-05 22:37:45 +02:00

Moved output folder to .build

This commit is contained in:
Andrew Davis
2018-09-02 13:12:25 -05:00
parent 676e090b41
commit 87868b147a
5 changed files with 4 additions and 6 deletions

1
.gitignore vendored
View File

@@ -4,3 +4,4 @@
/node_modules /node_modules
/docs /docs
/.build

View File

@@ -6,7 +6,7 @@ return [
'icon_dir' => __DIR__ . '/assets/icons', 'icon_dir' => __DIR__ . '/assets/icons',
'code_dir' => __DIR__ . '/code', 'code_dir' => __DIR__ . '/code',
'templates_dir' => __DIR__ . '/assets/templates', 'templates_dir' => __DIR__ . '/assets/templates',
'output_dir' => __DIR__ . '/docs', 'output_dir' => __DIR__ . '/.build',
'pages' => [ 'pages' => [
Page::create('index', 'index.phtml'), Page::create('index', 'index.phtml'),
Page::create('credits', 'credits.phtml'), Page::create('credits', 'credits.phtml'),

View File

@@ -2,9 +2,6 @@
"name": "phpapprentice", "name": "phpapprentice",
"version": "1.0.0", "version": "1.0.0",
"description": "A website for learning PHP", "description": "A website for learning PHP",
"directories": {
"doc": "docs"
},
"scripts": { "scripts": {
"test": "echo \"Error: no test specified\" && exit 1", "test": "echo \"Error: no test specified\" && exit 1",
"build": "./node_modules/.bin/encore dev", "build": "./node_modules/.bin/encore dev",

View File

@@ -18,6 +18,6 @@ class ServerCommand extends Command
protected function execute(InputInterface $input, OutputInterface $output) protected function execute(InputInterface $input, OutputInterface $output)
{ {
$output->writeln('Starting development server on localhost:8080'); $output->writeln('Starting development server on localhost:8080');
system('php -S localhost:8080 -t docs src/util/router.php'); system('php -S localhost:8080 -t ' . config('output_dir') . ' src/util/router.php');
} }
} }

View File

@@ -1,7 +1,7 @@
var Encore = require('@symfony/webpack-encore'); var Encore = require('@symfony/webpack-encore');
Encore Encore
.setOutputPath('docs') .setOutputPath('.build')
.setPublicPath('/') .setPublicPath('/')
.addEntry('js/site', './assets/js/site.js') .addEntry('js/site', './assets/js/site.js')
.addStyleEntry('css/site', './assets/css/site.css') .addStyleEntry('css/site', './assets/css/site.css')