快捷鍵(Key Binding)
設定檔位置
Sublime Text 2.0.2 x64\Data\Packages\User\Default (Windows).sublime-keymap
Sublime Text 2.0.2 x64\Data\Packages\User\Default (OSX).sublime-keymap
Sublime Text 2.0.2 x64\Data\Packages\User\Default (Linux).sublime-keymap
Sublime Text 2.0.2 x64\Data\Packages\User\Default (Windows).sublime-keymap
Sublime Text 2.0.2 x64\Data\Packages\User\Default (OSX).sublime-keymap
Sublime Text 2.0.2 x64\Data\Packages\User\Default (Linux).sublime-keymap
Tab
及空白
切換php artisan
後,可以看到migrate指令$ php artisan
migrate
migrate:install Create the migration repository
migrate:make Create a new migration file
migrate:refresh Reset and re-run all migrations
migrate:reset Rollback all database migrations
migrate:rollback Rollback the last database migration
指令 | 說明 |
---|---|
migration | 執行尚未執行的migration |
migrate:install | 在資料庫建立migration管理資料表 |
migrate:make | 建立新的migration檔案 |
migrate:refresh | 重設資料庫所有的migration,並重新執行所有的migration |
migrate:reset | 重設資料庫所有的migration |
migrate:rollback | 復原最後一筆migration紀錄 |
app/config/app.php
檔案中你會找到一組key的位置,這個key是一組32個字元的key,我們可以自己輸入想要的key,或者使用Laravel 4提供的Artisan命令列去自動亂數產生一組keyphp artisan
可以看到所有artisan支援的指令,你可以找到key:generate
可以產生一組亂數的key。$ php artisan
Laravel Framework version 4.0.0
Usage:
[options] command [arguments]
Options:
--help -h Display this help message.
--quiet -q Do not output any message.
--verbose -v|vv|vvv Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug
--version -V Display this application version.
--ansi Force ANSI output.
--no-ansi Disable ANSI output.
--no-interaction -n Do not ask any interactive question.
--env The environment the command should run under.
Available commands:
clear-compiled Remove the compiled class file
down Put the application into maintenance mode
dump-autoload Regenerate framework autoload files
help Displays help for a command
list Lists commands
migrate Run the database migrations
optimize Optimize the framework for better performance
routes List all registered routes
serve Serve the application on the PHP development server
tinker Interact with your application
up Bring the application out of maintenance mode
workbench Create a new package workbench
asset
asset:publish Publish a package's assets to the public directory
auth
auth:reminders Create a migration for the password reminders table
cache
cache:clear Flush the application cache
command
command:make Create a new Artisan command
config
config:publish Publish a package's configuration to the application
controller
controller:make Create a new resourceful controller
db
db:seed Seed the database with records
key
key:generate Set the application key
migrate
migrate:install Create the migration repository
migrate:make Create a new migration file
migrate:refresh Reset and re-run all migrations
migrate:reset Rollback all database migrations
migrate:rollback Rollback the last database migration
queue
queue:listen Listen to a given queue
queue:subscribe Subscribe a URL to an Iron.io push queue
queue:work Process the next job on a queue
session
session:table Create a migration for the session database table
php artisan key:generate
Application key [2wgjsIpDDIJvc4AgMV6VV1QybWznB6nY] set successfully.
app/config/app.php
檔案中,找到key資料的位置,確認key是否以正確的產生即可。