Skip to content

Firefly III: a personal finances manager

First step towards Laravel 5.5

James Coled1e60cd546dd
diff --git a/.gitattributes b/.gitattributes
old mode 100755
new mode 100644
index a8763f8ef5..967315dd3d
--- a/.gitattributes
+++ b/.gitattributes
@@ -1,3 +1,5 @@
* text=auto
*.css linguist-vendored
*.scss linguist-vendored
+*.js linguist-vendored
+CHANGELOG.md export-ignore
diff --git a/.gitignore b/.gitignore
old mode 100755
new mode 100644
index d7d1a372b1..b6a4b86d78
--- a/.gitignore
+++ b/.gitignore
@@ -1,11 +1,12 @@
/node_modules
+/public/hot
/public/storage
+/storage/*.key
+/vendor
+/.idea
+/.vagrant
Homestead.json
Homestead.yaml
+npm-debug.log
+yarn-error.log
.env
-public/google*.html
-report.html
-
-### Composer ###
-composer.phar
-/vendor/
diff --git a/app/Console/Kernel.php b/app/Console/Kernel.php
index bd85ef2c8e..0a1723a383 100644
--- a/app/Console/Kernel.php
+++ b/app/Console/Kernel.php
@@ -1,79 +1,42 @@
<?php
-/**
- * Kernel.php
- * Copyright (C) 2016 [email protected]
- *
- * This software may be modified and distributed under the terms of the
- * Creative Commons Attribution-ShareAlike 4.0 International License.
- *
- * See the LICENSE file for details.
- */
-
-declare(strict_types=1);
namespace FireflyIII\Console;
-use FireflyIII\Console\Commands\CreateImport;
-use FireflyIII\Console\Commands\DecryptAttachment;
-use FireflyIII\Console\Commands\EncryptFile;
-use FireflyIII\Console\Commands\Import;
-use FireflyIII\Console\Commands\ScanAttachments;
-use FireflyIII\Console\Commands\UpgradeDatabase;
-use FireflyIII\Console\Commands\UpgradeFireflyInstructions;
-use FireflyIII\Console\Commands\UseEncryption;
-use FireflyIII\Console\Commands\VerifyDatabase;
+use Illuminate\Console\Scheduling\Schedule;
use Illuminate\Foundation\Console\Kernel as ConsoleKernel;
-/**
- * Class Kernel
- *
- * @package FireflyIII\Console
- */
class Kernel extends ConsoleKernel
{
/**
- * The bootstrap classes for the application.
- *
- * Next upgrade verify these are the same.
+ * The Artisan commands provided by your application.
*
* @var array
*/
- protected $bootstrappers
- = [
- 'Illuminate\Foundation\Bootstrap\LoadEnvironmentVariables',
- 'Illuminate\Foundation\Bootstrap\LoadConfiguration',
- 'Illuminate\Foundation\Bootstrap\HandleExceptions',
- 'Illuminate\Foundation\Bootstrap\RegisterFacades',
- 'Illuminate\Foundation\Bootstrap\SetRequestForConsole',
- 'Illuminate\Foundation\Bootstrap\RegisterProviders',
- 'Illuminate\Foundation\Bootstrap\BootProviders',
- ];
+ protected $commands = [
+ //
+ ];
/**
- * The Artisan commands provided by your application.
+ * Define the application's command schedule.
*
- * @var array
+ * @param \Illuminate\Console\Scheduling\Schedule $schedule
+ * @return void
*/
- protected $commands
- = [
- UpgradeFireflyInstructions::class,
- VerifyDatabase::class,
- Import::class,
- CreateImport::class,
- EncryptFile::class,
- ScanAttachments::class,
- UpgradeDatabase::class,
- UseEncryption::class,
- DecryptAttachment::class,
- ];
+ protected function schedule(Schedule $schedule)
+ {
+ // $schedule->command('inspire')
+ // ->hourly();
+ }
/**
- * Register the Closure based commands for the application.
+ * Register the commands for the application.
*
* @return void
*/
protected function commands()
{
+ $this->load(__DIR__.'/Commands');
+
require base_path('routes/console.php');
}
}
diff --git a/artisan b/artisan
index df630d0d6d..5c23e2e24f 100755
--- a/artisan
+++ b/artisan
@@ -1,6 +1,8 @@
#!/usr/bin/env php
<?php
+define('LARAVEL_START', microtime(true));
+
/*
|--------------------------------------------------------------------------
| Register The Auto Loader
@@ -13,7 +15,7 @@
|
*/
-require __DIR__.'/bootstrap/autoload.php';
+require __DIR__.'/vendor/autoload.php';
$app = require_once __DIR__.'/bootstrap/app.php';
@@ -40,7 +42,7 @@ $status = $kernel->handle(
| Shutdown The Application
|--------------------------------------------------------------------------
|
-| Once Artisan has finished running. We will fire off the shutdown events
+| Once Artisan has finished running, we will fire off the shutdown events
| so that any final work may be done by the application before we shut
| down the process. This is the last thing to happen to the request.
|
diff --git a/gulpfile.js b/gulpfile.js
deleted file mode 100755
index 5f7804554a..0000000000
--- a/gulpfile.js
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * gulpfile.js
- * Copyright (c) 2017 [email protected]
- * This software may be modified and distributed under the terms of the
- * Creative Commons Attribution-ShareAlike 4.0 International License.
- *
- * See the LICENSE file for details.
- */
-
-const elixir = require('laravel-elixir');
-
-require('laravel-elixir-vue');
-
-/*
- |--------------------------------------------------------------------------
- | Elixir Asset Management
- |--------------------------------------------------------------------------
- |
- | Elixir provides a clean, fluent API for defining some basic Gulp tasks
- | for your Laravel application. By default, we are compiling the Sass
- | file for our application, as well as publishing vendor resources.
- |
- */
-
-elixir(mix => {
- mix.sass('app.scss')
- .webpack('app.js');
-});
diff --git a/package.json b/package.json
old mode 100755
new mode 100644
index d490671cdc..dedcbef712
--- a/package.json
+++ b/package.json
@@ -1,18 +1,21 @@
{
- "private": true,
- "scripts": {
- "prod": "gulp --production",
- "dev": "gulp watch"
- },
- "devDependencies": {
- "bootstrap-sass": "^3.3.7",
- "gulp": "^3.9.1",
- "jquery": "^3.1.0",
- "laravel-elixir": "^6.0.0-9",
- "laravel-elixir-vue": "^0.1.4",
- "laravel-elixir-webpack-official": "^1.0.2",
- "lodash": "^4.14.0",
- "vue": "^1.0.26",
- "vue-resource": "^0.9.3"
- }
+ "private": true,
+ "scripts": {
+ "dev": "npm run development",
+ "development": "cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js",
+ "watch": "cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --watch --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js",
+ "watch-poll": "npm run watch -- --watch-poll",
+ "hot": "cross-env NODE_ENV=development node_modules/webpack-dev-server/bin/webpack-dev-server.js --inline --hot --config=node_modules/laravel-mix/setup/webpack.config.js",
+ "prod": "npm run production",
+ "production": "cross-env NODE_ENV=production node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js"
+ },
+ "devDependencies": {
+ "axios": "^0.16.2",
+ "bootstrap-sass": "^3.3.7",
+ "cross-env": "^5.0.1",
+ "jquery": "^3.1.1",
+ "laravel-mix": "^1.0",
+ "lodash": "^4.17.4",
+ "vue": "^2.1.10"
+ }
}
diff --git a/phpunit.coverage.specific.xml b/phpunit.coverage.specific.xml
deleted file mode 100755
index 0a42b9d726..0000000000
--- a/phpunit.coverage.specific.xml
+++ /dev/null
@@ -1,51 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- ~ phpunit.coverage.specific.xml
- ~ Copyright (c) 2017 [email protected]
- ~ This software may be modified and distributed under the terms of the Creative Commons Attribution-ShareAlike 4.0 International License.
- ~
- ~ See the LICENSE file for details.
- -->
-
-<phpunit backupGlobals="false"
- backupStaticAttributes="false"
- bootstrap="bootstrap/autoload.php"
- colors="true"
- convertErrorsToExceptions="true"
- convertNoticesToExceptions="true"
- convertWarningsToExceptions="true"
- processIsolation="false"
- beStrictAboutOutputDuringTests="true"
- stopOnFailure="true">
- <testsuites>
- <testsuite name="Feature Tests">
- <directory suffix="Test.php">./tests/Feature</directory>
- </testsuite>
-
- <testsuite name="Unit Tests">
- <directory suffix="Test.php">./tests/Unit</directory>
- </testsuite>
- </testsuites>
-
-
-
-
-
- <filter>
- <whitelist addUncoveredFilesFromWhitelist="true">
- <directory suffix=".php">./app</directory>
- </whitelist>
- <blacklist>
- <directory>vendor/</directory>
- </blacklist>
- </filter>
- <logging>
- <log type="coverage-clover" target="./storage/build/clover-specific.xml" charset="UTF-8"/>
- </logging>
- <php>
- <env name="APP_ENV" value="testing"/>
- <env name="CACHE_DRIVER" value="array"/>
- <env name="SESSION_DRIVER" value="array"/>
- <env name="QUEUE_DRIVER" value="sync"/>
- </php>
-</phpunit>
diff --git a/phpunit.coverage.xml b/phpunit.coverage.xml
deleted file mode 100755
index b0b352d90a..0000000000
--- a/phpunit.coverage.xml
+++ /dev/null
@@ -1,52 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- ~ phpunit.coverage.xml
- ~ Copyright (c) 2017 [email protected]
- ~ This software may be modified and distributed under the terms of the
- ~ Creative Commons Attribution-ShareAlike 4.0 International License.
- ~
- ~ See the LICENSE file for details.
- -->
-
-<phpunit backupGlobals="false"
- backupStaticAttributes="false"
- bootstrap="bootstrap/autoload.php"
- colors="true"
- convertErrorsToExceptions="true"
- convertNoticesToExceptions="true"
- convertWarningsToExceptions="true"
- processIsolation="false"
- beStrictAboutOutputDuringTests="true"
- stopOnFailure="true">
- <testsuites>
- <testsuite name="Feature Tests">
- <directory suffix="Test.php">./tests/Feature</directory>
- </testsuite>
-
- <testsuite name="Unit Tests">
- <directory suffix="Test.php">./tests/Unit</directory>
- </testsuite>
- </testsuites>
-
-
-
-
-
- <filter>
- <whitelist addUncoveredFilesFromWhitelist="true">
- <directory suffix=".php">./app</directory>
- </whitelist>
- <blacklist>
- <directory>vendor/</directory>
- </blacklist>
- </filter>
- <logging>
- <log type="coverage-clover" target="./storage/build/clover-all.xml" charset="UTF-8"/>
- </logging>
- <php>
- <env name="APP_ENV" value="testing"/>
- <env name="CACHE_DRIVER" value="array"/>
- <env name="SESSION_DRIVER" value="array"/>
- <env name="QUEUE_DRIVER" value="sync"/>
- </php>
-</phpunit>
diff --git a/phpunit.xml b/phpunit.xml
old mode 100755
new mode 100644
index 73d2797478..bb9c4a7e1e
--- a/phpunit.xml
+++ b/phpunit.xml
@@ -1,39 +1,26 @@
<?xml version="1.0" encoding="UTF-8"?>
-<!--
- ~ phpunit.xml
- ~ Copyright (c) 2017 [email protected]
- ~ This software may be modified and distributed under the terms of the
- ~ Creative Commons Attribution-ShareAlike 4.0 International License.
- ~
- ~ See the LICENSE file for details.
- -->
-
<phpunit backupGlobals="false"
backupStaticAttributes="false"
- bootstrap="bootstrap/autoload.php"
+ bootstrap="vendor/autoload.php"
colors="true"
convertErrorsToExceptions="true"
convertNoticesToExceptions="true"
convertWarningsToExceptions="true"
processIsolation="false"
- beStrictAboutOutputDuringTests="true"
- stopOnFailure="true">
+ stopOnFailure="false">
<testsuites>
- <testsuite name="Feature Tests">
+ <testsuite name="Feature">
<directory suffix="Test.php">./tests/Feature</directory>
</testsuite>
- <testsuite name="Unit Tests">
+ <testsuite name="Unit">
<directory suffix="Test.php">./tests/Unit</directory>
</testsuite>
</testsuites>
<filter>
- <whitelist addUncoveredFilesFromWhitelist="true">
+ <whitelist processUncoveredFilesFromWhitelist="true">
<directory suffix=".php">./app</directory>
</whitelist>
- <blacklist>
- <directory>vendor/</directory>
- </blacklist>
</filter>
<php>
<env name="APP_ENV" value="testing"/>
diff --git a/server.php b/server.php
old mode 100755
new mode 100644
index b2bd3167e6..5fb6379e71
--- a/server.php
+++ b/server.php
@@ -1,13 +1,4 @@
<?php
-/**
- * server.php
- * Copyright (C) 2016 [email protected]
- *
- * This software may be modified and distributed under the terms
- * of the MIT license. See the LICENSE file for details.
- */
-
-declare(strict_types = 1);
/**
* Laravel - A PHP Framework For Web Artisans
diff --git a/webpack.mix.js b/webpack.mix.js
new file mode 100644
index 0000000000..72fdbb16d6
--- /dev/null
+++ b/webpack.mix.js
@@ -0,0 +1,15 @@
+let mix = require('laravel-mix');
+
+/*
+ |--------------------------------------------------------------------------
+ | Mix Asset Management
+ |--------------------------------------------------------------------------
+ |
+ | Mix provides a clean, fluent API for defining some Webpack build steps
+ | for your Laravel application. By default, we are compiling the Sass
+ | file for the application as well as bundling up all the JS files.
+ |
+ */
+
+mix.js('resources/assets/js/app.js', 'public/js')
+ .sass('resources/assets/sass/app.scss', 'public/css');