Skip to content

Commit

Permalink
Merge pull request #289 from cretueusebiu/next
Browse files Browse the repository at this point in the history
Next
  • Loading branch information
cretueusebiu authored Oct 31, 2020
2 parents cc917bf + 3f8990f commit f6d3243
Show file tree
Hide file tree
Showing 82 changed files with 8,080 additions and 5,352 deletions.
24 changes: 16 additions & 8 deletions .env.dusk.testing → .env.dusk
Original file line number Diff line number Diff line change
@@ -1,17 +1,14 @@
APP_NAME="Laravel Vue Spa"
APP_ENV=testing
APP_KEY=base64:Yl0dsUdMVC0HDDOKlYyafw4dciCQqMJK+rlG6CqBELQ=
APP_KEY=base64:ZDLf88XPAUgLJv7l6c8IxGpKXxZGobomG994vKY03qk=
APP_DEBUG=true
APP_LOG_LEVEL=debug
APP_URL=http://127.0.0.1:8000

LOG_CHANNEL=stack
LOG_LEVEL=debug

DB_CONNECTION=mysql
DB_HOST=127.0.0.1
DB_PORT=3306
DB_DATABASE=laravel_vue_spa
DB_USERNAME=root
DB_PASSWORD=
DB_CONNECTION=dusk

BROADCAST_DRIVER=log
CACHE_DRIVER=file
Expand All @@ -29,10 +26,21 @@ MAIL_PORT=2525
MAIL_USERNAME=null
MAIL_PASSWORD=null
MAIL_ENCRYPTION=null
MAIL_FROM_ADDRESS=null
MAIL_FROM_NAME="${APP_NAME}"

AWS_ACCESS_KEY_ID=
AWS_SECRET_ACCESS_KEY=
AWS_DEFAULT_REGION=us-east-1
AWS_BUCKET=

PUSHER_APP_ID=
PUSHER_APP_KEY=
PUSHER_APP_SECRET=
PUSHER_APP_CLUSTER=mt1

JWT_SECRET=9K6whOetAFaokQgSIdbMQZuJuDV5uS2Y
MIX_PUSHER_APP_KEY="${PUSHER_APP_KEY}"
MIX_PUSHER_APP_CLUSTER="${PUSHER_APP_CLUSTER}"

JWT_TTL=1440
JWT_SECRET=eJkecpCqbVBJn7Wvnt5GXTjIRoYh1OjwvDQywVobjwKbmGmwt4UUqPo3y6IlnqAG
38 changes: 0 additions & 38 deletions .env.dusk.local

This file was deleted.

9 changes: 6 additions & 3 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,14 @@ APP_LOG_LEVEL=debug
APP_URL=http://localhost

LOG_CHANNEL=stack
LOG_LEVEL=debug

DB_CONNECTION=mysql
DB_HOST=127.0.0.1
DB_PORT=3306
DB_DATABASE=homestead
DB_USERNAME=homestead
DB_PASSWORD=secret
DB_DATABASE=laravel
DB_USERNAME=root
DB_PASSWORD=

BROADCAST_DRIVER=log
CACHE_DRIVER=file
Expand All @@ -30,6 +31,8 @@ MAIL_PORT=2525
MAIL_USERNAME=null
MAIL_PASSWORD=null
MAIL_ENCRYPTION=null
MAIL_FROM_ADDRESS=null
MAIL_FROM_NAME="${APP_NAME}"

AWS_ACCESS_KEY_ID=
AWS_SECRET_ACCESS_KEY=
Expand Down
15 changes: 0 additions & 15 deletions .eslintrc

This file was deleted.

16 changes: 16 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
module.exports = {
root: true,
parser: 'vue-eslint-parser',
parserOptions: {
parser: '@babel/eslint-parser',
ecmaVersion: 2018,
sourceType: 'module'
},
extends: [
'plugin:vue/recommended',
'standard'
],
rules: {
'vue/max-attributes-per-line': 'off'
}
}
82 changes: 82 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
name: tests

on:
push:
pull_request:

jobs:
tests:

runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v2

- name: Get Composer cache directory
id: composer-cache
run: |
echo "::set-output name=dir::$(composer config cache-files-dir)"
- uses: actions/cache@v2
with:
path: ${{ steps.composer-cache.outputs.dir }}
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
restore-keys: |
${{ runner.os }}-composer-
- uses: actions/cache@v2
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- name: Prepare the environment
run: cp .env.example .env

- name: Install composer dependencies
run: composer install -q --no-ansi --no-interaction --no-progress --no-suggest --prefer-dist --optimize-autoloader

- name: Directory permissions
run: chmod -R 777 storage bootstrap/cache

- name: Run tests (Unit and Feature)
run: vendor/bin/phpunit

- name: Install npm dependencies
run: npm install --no-audit --no-progress --silent

- name: Build client
run: npm run production

- name: Upgrade Chrome driver
run: php artisan dusk:chrome-driver `/opt/google/chrome/chrome --version | cut -d " " -f3 | cut -d "." -f1`

- name: Start Chrome driver
run: ./vendor/laravel/dusk/bin/chromedriver-linux &

- name: Create database
run: touch database/dusk.sqlite

- name: Run Laravel server
run: php artisan serve &

- name: Run Dusk tests
env:
APP_URL: "http://127.0.0.1:8000"
run: php artisan dusk

- name: Upload screenshots
if: failure()
uses: actions/upload-artifact@v2
with:
name: screenshots
path: tests/Browser/screenshots

- name: Upload console logs
if: failure()
uses: actions/upload-artifact@v2
with:
name: console
path: tests/Browser/console
10 changes: 5 additions & 5 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
/node_modules
/.idea
/public/hot
/public/storage
/storage/*.key
/vendor
/public/dist
/public/build
/public/mix-manifest.json
.env
.env.backup
.env.dusk.local
.phpunit.result.cache
Homestead.json
Homestead.yaml
npm-debug.log
yarn-error.log
phpunit.dusk.xml
*.code-workspace
/public/dist
/public/build
/public/mix-manifest.json
13 changes: 13 additions & 0 deletions .styleci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
php:
preset: laravel
disabled:
- no_unused_imports
finder:
not-name:
- index.php
- server.php
js:
finder:
not-name:
- webpack.mix.js
css: true
45 changes: 0 additions & 45 deletions .travis.yml

This file was deleted.

9 changes: 9 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,14 @@
# Changelog

## 5.0.0 - 2020-10-31

- Upgrade to Laravel 8
- Update dependencies
- Fixed locale cookie fallback [#221](https://github.com/cretueusebiu/laravel-vue-spa/pull/221)
- Added scroll delay [#220](https://github.com/cretueusebiu/laravel-vue-spa/pull/220)
- Added redirect to intended url [#208](https://github.com/cretueusebiu/laravel-vue-spa/pull/208)
- Added middleware parameter [#124](https://github.com/cretueusebiu/laravel-vue-spa/pull/124)

## 4.7.0 - 2020-04-09

- Added `routes/spa.php` and `spa` middleware for serving the frontend [#249](https://github.com/cretueusebiu/laravel-vue-spa/pull/249)
Expand Down
18 changes: 14 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Laravel-Vue SPA

<a href="https://travis-ci.org/cretueusebiu/laravel-vue-spa"><img src="https://travis-ci.org/cretueusebiu/laravel-vue-spa.svg?branch=master" alt="Build Status"></a>
<a href="https://github.com/cretueusebiu/laravel-vue-spa/actions"><img src="https://github.com/cretueusebiu/laravel-vue-spa/workflows/tests/badge.svg" alt="Build Status"></a>
<a href="https://packagist.org/packages/cretueusebiu/laravel-vue-spa"><img src="https://poser.pugx.org/cretueusebiu/laravel-vue-spa/d/total.svg" alt="Total Downloads"></a>
<a href="https://packagist.org/packages/cretueusebiu/laravel-vue-spa"><img src="https://poser.pugx.org/cretueusebiu/laravel-vue-spa/v/stable.svg" alt="Latest Stable Version"></a>

Expand All @@ -12,7 +12,7 @@

## Features

- Laravel 7
- Laravel 8
- Vue + VueRouter + Vuex + VueI18n + ESlint
- Pages with dynamic import and custom layouts
- Login, register, email verification and password reset
Expand All @@ -33,10 +33,10 @@
#### Development

```bash
# build and watch
# Build and watch
npm run watch

# serve with hot reloading
# Serve with hot reloading (not working)
npm run hot
```

Expand All @@ -60,6 +60,16 @@ For other providers you may need to set the appropriate keys in `config/services

To enable email verification make sure that your `App\User` model implements the `Illuminate\Contracts\Auth\MustVerifyEmail` contract.

## Testing

```bash
# Run unit and feature tests
vendor/bin/phpunit

# Run Dusk browser tests
php artisan dusk
```

## Changelog

Please see [CHANGELOG](CHANGELOG.md) for more information what has changed recently.
3 changes: 1 addition & 2 deletions app/Console/Kernel.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,7 @@ class Kernel extends ConsoleKernel
*/
protected function schedule(Schedule $schedule)
{
// $schedule->command('inspire')
// ->hourly();
// $schedule->command('inspire')->hourly();
}

/**
Expand Down
Loading

0 comments on commit f6d3243

Please sign in to comment.