Help us understand the problem. What is going on with this article?

laravel初心者メモ

[追記]
- Homestead使用時のお話です。
- 当時なのでLaravelのバージョンが古いです。ご注意ください。

debug環境などを整えるのに毎回調べるのが面倒なのでcomposer.jsonごとメモしてしまいます。

composer create-project laravel/laravel --prefer-dist projectName
cd projectName
composer.json
{
    "name": "laravel/laravel",
    "description": "The Laravel Framework.",
    "keywords": ["framework", "laravel"],
    "license": "MIT",
    "type": "project",
    "require": {
        "php": ">=5.5.9",
        "laravel/framework": "5.2.*"
    },
    "require-dev": {
        "fzaninotto/faker": "~1.4",
        "mockery/mockery": "0.9.*",
        "phpunit/phpunit": "~4.0",
        "symfony/css-selector": "2.8.*|3.0.*",
        "symfony/dom-crawler": "2.8.*|3.0.*",
        "laravel/homestead": "^3.0",
        "barryvdh/laravel-ide-helper": "^2.2",
        "barryvdh/laravel-debugbar": "^2.2"
    },
    "autoload": {
        "classmap": [
            "database"
        ],
        "psr-4": {
            "App\\": "app/"
        }
    },
    "autoload-dev": {
        "classmap": [
            "tests/TestCase.php"
        ]
    },
    "scripts": {
        "post-root-package-install": [
            "php -r \"copy('.env.example', '.env');\""
        ],
        "post-create-project-cmd": [
            "php artisan key:generate"
        ],
        "post-install-cmd": [
            "Illuminate\\Foundation\\ComposerScripts::postInstall",
            "php artisan optimize"
        ],
        "post-update-cmd": [
            "Illuminate\\Foundation\\ComposerScripts::postUpdate",
            "php artisan optimize"
        ]
    },
    "config": {
        "preferred-install": "dist"
    }
}

このあと

composer update

vendor/bin/homestead make

homestead installed!

homestead.ymlを編集します。これは僕だけだと思います。

ip: "192.168.33.33"

...

memory: 1024

そして

config/app.php
'debug' => env('APP_DEBUG', true),

// ....


"providers" =>[
        // ....
\Barryvdh\LaravelIdeHelper\IdeHelperServiceProvider::class,
\Barryvdh\Debugbar\ServiceProvider::class,    
        // ....
],

'aliases' => [
        // ....
'Debugbar' => \Barryvdh\Debugbar\Facade::class,
        // ....

php artisan ide-helper:generate

vagrant up

let's laravel

Why not register and get more from Qiita?
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away
Comments
Sign up for free and join this conversation.
If you already have a Qiita account
Why do not you register as a user and use Qiita more conveniently?
You need to log in to use this function. Qiita can be used more conveniently after logging in.
You seem to be reading articles frequently this month. Qiita can be used more conveniently after logging in.
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away