Last active
December 5, 2017 19:21
-
-
Save nickdenardis/5670113 to your computer and use it in GitHub Desktop.
Revisions
-
nickdenardis revised this gist
Sep 15, 2013 . 1 changed file with 98 additions and 3 deletions.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -25,6 +25,7 @@ "require": { "laravel/framework": "4.0.*", "way/generators": "dev-master", "zurb/foundation": "dev-master", "zurb/foundation": "dev-master", "conarwelsh/mustache-l4": "dev-master", }, @@ -83,10 +84,104 @@ ### Download Foundation SCSS and install to directory https://github.com/zurb/foundation/tree/scss-standalone ## JSON API sudo chmod -R 755 vendor/way/generators/src/Way/ ## Generate some resources php artisan generate:resource webpage --fields="url:string" ## Add the v1 route //create a group of routes that will belong to APIv1 Route::group(array('prefix' => 'v1'), function() { //... insert API routes here... Route::resource('webpages', 'V1\WebpagesController'); //notice the namespace }); ## Move the controllers to the namespace mkdir app/controllers/V1 mv app/controllers/WebpagesController.php app/controllers/V1/ ## app/controllers/WebpagesController.php <?php //use our new namespace namespace V1; //import classes that are not in this new namespace use BaseController; class WebpagesController extends BaseController { ## Add the respository mkdir app/repositories ## composer.json "autoload": { "classmap": [ "app/commands", "app/controllers", "app/models", "app/database/migrations", "app/database/seeds", "app/tests/TestCase.php", "app/repositories" ] }, ## Seed the database <?php class WebpagesTableSeeder extends Seeder { public function run() { // Uncomment the below to wipe the table clean before populating DB::table('webpages')->truncate(); $webpages = array( array( 'url' => 'http://wayne.edu/', 'created_at' => date('Y-m-d H:i:s'), 'updated_at' => date('Y-m-d H:i:s'), ), array( 'url' => 'http://wayne.edu/about/', 'created_at' => date('Y-m-d H:i:s'), 'updated_at' => date('Y-m-d H:i:s'), ), ); // Uncomment the below to run the seeder DB::table('webpages')->insert($webpages); } } ## dump composer each time you add migration files composer dump-autoload ## Run the migrations and seed php artisan migrate --seed ## To run tests vendor/phpunit/phpunit/phpunit.php ## Remove the default test rm app/tests/ExampleTest.php ## Make tests for the controllers and repositories mkdir app/tests/controllers app/tests/repositories ## Tests should all fail now Note: in TDD, the objective is to do no more work than is required to make your tests pass. So we want to do the absolute bare minimum here. ## Create an app errors file touch app/errors.php ## Move the frontend Foundation assets cp -R vendor/zurb/foundation/scss public/ cp -R vendor/zurb/foundation/js/ public/js/ ## Move the resource templates into the public dir mv app/views/webpages public/views/ ## Deploy with capistrano sudo gem install capistrano -
nickdenardis revised this gist
Sep 15, 2013 . 1 changed file with 187 additions and 214 deletions.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,233 +1,206 @@ ## Resources https://github.com/eightygrit/deploy-laravel/blob/master/deploy-laravel.z.sh https://github.com/onigoetz/deployer https://gist.github.com/purwandi/4110547 https://gist.github.com/chipotle/5506641 ## Add Sublime Text 2 to the CLI sudo ln -s "/Applications/Sublime Text.app/Contents/SharedSupport/bin/subl" /usr/bin/subl ## Use MAMP PHP CLI export PATH=/Applications/MAMP/bin/php/php5.3.6/bin/:$PATH ## Install Composer without cert errors curl -ksS https://getcomposer.org/installer | php sudo mv composer.phar /usr/local/bin/composer ## Create a new project with composer composer create-project laravel/laravel appname ## Add the needed packages package.json { "name": "laravel/laravel", "description": "The Laravel Framework.", "keywords": ["framework", "laravel"], "require": { "laravel/framework": "4.0.*", "way/generators": "dev-master", "zurb/foundation": "dev-master", "conarwelsh/mustache-l4": "dev-master", }, "require-dev":{ "phpunit/phpunit": "3.7.*", "mockery/mockery": "0.7.*" }, "autoload": { "classmap": [ ## Mustache Reference https://github.com/conarwelsh/mustache-l4 ## Update the package installation composer update ## Add the items to the app dependancies app/config/app.php ... 'Way\Generators\GeneratorsServiceProvider', 'Conarwelsh\MustacheL4\MustacheL4ServiceProvider', ... ## Change the bootstrap bootstrap/start.php hostname $env = $app->detectEnvironment(array( 'local' => array('your-machine-name'), )); ## Set the storage to be writable chmod -R 777 app/storage/ ## Edit ths app/config/database.php Use 127.0.0.1 for locahost if possible ### Edit the app/config/view.php (if using mustache for JS too) 'paths' => array(__DIR__.'/../../public/views'), ### Create/Edit the public/package.json (if using mustache for JS too) { "name": "laravel4-and-foundation", "version": "0.0.1", "private": true, "dependencies": { "foundation": "*", "mustache": "*" } } ### Install the new frontend needs (if using mustache for JS too) cd public npm install cd .. ### Create all the frontend asset folders (if using mustache for JS too) mkdir public/views public/views/layouts public/js public/css ### Download Foundation SCSS and install to directory https://github.com/zurb/foundation/tree/scss-standalone ## Create a RESTful resource controller php artisan controller:make PhotoController Route::resource('photo', 'PhotoController'); ## Deploy with capistrano sudo gem install capistrano capify . cap deploy:setup cap deploy:check cap deploy ## Capdeploy file # This makes a few assumptions: # # - You are using a similar .gitignore to Laravel's default, so your # vendor directory and composer(.phar) are not under version control # - Composer is installed as an executable at /usr/local/bin/composer # # If you don't have Composer installed globally, you can modify the # appropriate task (:composer_install). Or make your life simpler and # install Composer globally. # Fill in application-specific configuration options below set :application, "Laravel 4 Testing Roll" set :repository, "git@github.com:nickdenardis/laravel-test.git" set :scm, :git set :scm_username, "nickdenardis" set :user, "user" role :web, "server" role :app, "server" role :db, "server", :primary => true set :deploy_to, "/usr/local/www/sites/base/" set :deploy_via, :remote_cache set :use_sudo, false # I don't need sudo, but you might set :ssh_options, {:forward_agent => true} set :copy_exclude, [".git", ".gitignore", ".tags", ".tags_sorted_by_file"] set :keep_releases, 5 # Laravel deployment namespace :deploy do task :update do transaction do update_code copy_config composer_install link_shared laravel_migrate symlink end end task :finalize_update do transaction do # No need to change ownership #run "chmod -R g+w #{releases_path}/#{release_name}" end end task :symlink do transaction do run "ln -nfs #{current_release} #{deploy_to}/#{current_dir}" end end task :link_shared do transaction do run "ln -nfs #{shared_path}/system #{current_release}/public/system" end end task :laravel_migrate do transaction do run "php #{current_release}/artisan migrate" end end task :laravel_rollback do run "php #{deploy_to}/#{current_dir}/artisan migrate:rollback" end task :restart do transaction do # set writable storage dir run "mydir=\"#{deploy_to}/#{current_dir}/app/storage\";if [ -d $mydir/cache ]; then chmod -R 777 $mydir/cache; rm -f $mydir/cache/*; fi" run "mydir=\"#{deploy_to}/#{current_dir}/app/storage\";if [ -d $mydir/database ]; then chmod -R 777 $mydir/database; fi" run "mydir=\"#{deploy_to}/#{current_dir}/app/storage\";if [ -d $mydir/meta ]; then chmod -R 777 $mydir/meta; fi" run "mydir=\"#{deploy_to}/#{current_dir}/app/storage\";if [ -d $mydir/logs ]; then chmod -R 777 $mydir/logs; fi" run "mydir=\"#{deploy_to}/#{current_dir}/app/storage\";if [ -d $mydir/sessions ]; then chmod -R 777 $mydir/sessions; fi" run "mydir=\"#{deploy_to}/#{current_dir}/app/storage\";if [ -d $mydir/views ]; then chmod -R 777 $mydir/views; rm -f $mydir/views/*; fi" run "mydir=\"#{deploy_to}/#{current_dir}/app/storage\";if [ -d $mydir/work ]; then chmod -R 777 $mydir/work; fi" end end task :composer_install do transaction do run "cd #{current_release};/usr/local/bin/composer install" end end # This task lets you keep server-specific configuration files in "shared/config/". # Any file there will just be copied to your app/config directory. task :copy_config do transaction do #run "cp #{shared_path}/config/* #{current_release}/app/config/" end end end after "deploy:rollback", "deploy:laravel_rollback" https://help.github.com/articles/deploying-with-capistrano https://github.com/capistrano/capistrano/wiki/2.x-from-the-beginning -
nickdenardis revised this gist
Aug 5, 2013 . 1 changed file with 4 additions and 4 deletions.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -75,11 +75,11 @@ Edit ths app/config/database.php ------------- Use 127.0.0.1 for locahost if possible Edit the app/config/view.php (if using mustache for JS too) ------------- 'paths' => array(__DIR__.'/../../public/views'), Create/Edit the public/package.json (if using mustache for JS too) ------------- { "name": "laravel4-and-foundation", @@ -91,15 +91,15 @@ Create/Edit the public/package.json (if using mustache) } } Install the new frontend needs (if using mustache for JS too) ------------- cd public npm install cd .. Create all the frontend asset folders (if using mustache for JS too) ------------- mkdir public/views public/views/layouts public/js public/css -
nickdenardis revised this gist
Aug 5, 2013 . 1 changed file with 4 additions and 1 deletion.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -46,9 +46,12 @@ Add the needed packages package.json "autoload": { "classmap": [ ## Mustache Reference https://github.com/conarwelsh/mustache-l4 Update the package installation ------------- composer update Add the items to the app dependancies app/config/app.php ------------- -
nickdenardis revised this gist
Aug 5, 2013 . 1 changed file with 4 additions and 2 deletions.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -36,11 +36,12 @@ Add the needed packages package.json "require": { "laravel/framework": "4.0.*", "way/generators": "dev-master", "zurb/foundation": "dev-master", "conarwelsh/mustache-l4": "dev-master", }, "require-dev":{ "phpunit/phpunit": "3.7.*", "mockery/mockery": "0.7.*" }, "autoload": { "classmap": [ @@ -53,6 +54,7 @@ Add the items to the app dependancies app/config/app.php ------------- ... 'Way\Generators\GeneratorsServiceProvider', 'Conarwelsh\MustacheL4\MustacheL4ServiceProvider', ... Change the bootstrap bootstrap/start.php -
nickdenardis revised this gist
Aug 5, 2013 . 1 changed file with 107 additions and 0 deletions.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -116,6 +116,113 @@ Deploy from github cap deploy:setup cap deploy:check cap deploy # This makes a few assumptions: # # - You are using a similar .gitignore to Laravel's default, so your # vendor directory and composer(.phar) are not under version control # - Composer is installed as an executable at /usr/local/bin/composer # # If you don't have Composer installed globally, you can modify the # appropriate task (:composer_install). Or make your life simpler and # install Composer globally. # Fill in application-specific configuration options below set :application, "Laravel 4 Testing Roll" set :repository, "git@github.com:nickdenardis/laravel-test.git" set :scm, :git set :scm_username, "nickdenardis" set :user, "user" role :web, "server" role :app, "server" role :db, "server", :primary => true set :deploy_to, "/usr/local/www/sites/base/" set :deploy_via, :remote_cache set :use_sudo, false # I don't need sudo, but you might set :ssh_options, {:forward_agent => true} set :copy_exclude, [".git", ".gitignore", ".tags", ".tags_sorted_by_file"] set :keep_releases, 5 # Laravel deployment namespace :deploy do task :update do transaction do update_code copy_config composer_install link_shared laravel_migrate symlink end end task :finalize_update do transaction do # No need to change ownership #run "chmod -R g+w #{releases_path}/#{release_name}" end end task :symlink do transaction do run "ln -nfs #{current_release} #{deploy_to}/#{current_dir}" end end task :link_shared do transaction do run "ln -nfs #{shared_path}/system #{current_release}/public/system" end end task :laravel_migrate do transaction do run "php #{current_release}/artisan migrate" end end task :laravel_rollback do run "php #{deploy_to}/#{current_dir}/artisan migrate:rollback" end task :restart do transaction do # set writable storage dir run "mydir=\"#{deploy_to}/#{current_dir}/app/storage\";if [ -d $mydir/cache ]; then chmod -R 777 $mydir/cache; rm -f $mydir/cache/*; fi" run "mydir=\"#{deploy_to}/#{current_dir}/app/storage\";if [ -d $mydir/database ]; then chmod -R 777 $mydir/database; fi" run "mydir=\"#{deploy_to}/#{current_dir}/app/storage\";if [ -d $mydir/meta ]; then chmod -R 777 $mydir/meta; fi" run "mydir=\"#{deploy_to}/#{current_dir}/app/storage\";if [ -d $mydir/logs ]; then chmod -R 777 $mydir/logs; fi" run "mydir=\"#{deploy_to}/#{current_dir}/app/storage\";if [ -d $mydir/sessions ]; then chmod -R 777 $mydir/sessions; fi" run "mydir=\"#{deploy_to}/#{current_dir}/app/storage\";if [ -d $mydir/views ]; then chmod -R 777 $mydir/views; rm -f $mydir/views/*; fi" run "mydir=\"#{deploy_to}/#{current_dir}/app/storage\";if [ -d $mydir/work ]; then chmod -R 777 $mydir/work; fi" end end task :composer_install do transaction do run "cd #{current_release};/usr/local/bin/composer install" end end # This task lets you keep server-specific configuration files in "shared/config/". # Any file there will just be copied to your app/config directory. task :copy_config do transaction do #run "cp #{shared_path}/config/* #{current_release}/app/config/" end end end after "deploy:rollback", "deploy:laravel_rollback" https://help.github.com/articles/deploying-with-capistrano https://github.com/capistrano/capistrano/wiki/2.x-from-the-beginning -
nickdenardis revised this gist
Jul 13, 2013 . 1 changed file with 6 additions and 4 deletions.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -70,11 +70,11 @@ Edit ths app/config/database.php ------------- Use 127.0.0.1 for locahost if possible Edit the app/config/view.php (if using mustache) ------------- 'paths' => array(__DIR__.'/../../public/views'), Create/Edit the public/package.json (if using mustache) ------------- { "name": "laravel4-and-foundation", @@ -86,7 +86,7 @@ Edit the public/package.json } } Install the new frontend needs (if using mustache) ------------- cd public @@ -98,7 +98,9 @@ Create all the frontend asset folders ------------- mkdir public/views public/views/layouts public/js public/css Download Foundation SCSS and install to directory ------------- https://github.com/zurb/foundation/tree/scss-standalone Create a RESTful resource controller ------------- -
nickdenardis renamed this gist
Jul 13, 2013 . 1 changed file with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes. -
nickdenardis renamed this gist
Jul 13, 2013 . 1 changed file with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes. -
nickdenardis revised this gist
Jul 13, 2013 . 1 changed file with 2 additions and 6 deletions.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -26,11 +26,6 @@ Create a new project with composer composer create-project laravel/laravel appname Add the needed packages package.json ------------- @@ -40,7 +35,8 @@ Add the needed packages package.json "keywords": ["framework", "laravel"], "require": { "laravel/framework": "4.0.*", "way/generators": "dev-master", "zurb/foundation": "dev-master" }, "require-dev":{ "phpunit/phpunit": "3.7.*", -
nickdenardis revised this gist
Jul 13, 2013 . 1 changed file with 6 additions and 0 deletions.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -98,6 +98,12 @@ Install the new frontend needs cd .. Create all the frontend asset folders ------------- mkdir public/views public/views/layouts public/js public/css Create a RESTful resource controller ------------- php artisan controller:make PhotoController -
nickdenardis revised this gist
Jul 13, 2013 . 1 changed file with 6 additions and 0 deletions.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -53,6 +53,12 @@ Update the package installation ------------- composer install --dev Add the items to the app dependancies app/config/app.php ------------- ... 'Way\Generators\GeneratorsServiceProvider', ... Change the bootstrap bootstrap/start.php ------------- hostname -
nickdenardis revised this gist
Jul 13, 2013 . 1 changed file with 4 additions and 1 deletion.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -83,7 +83,10 @@ Edit the public/package.json "mustache": "*" } } Install the new frontend needs ------------- cd public npm install cd .. -
nickdenardis revised this gist
Jul 13, 2013 . 1 changed file with 4 additions and 0 deletions.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -49,6 +49,10 @@ Add the needed packages package.json "autoload": { "classmap": [ Update the package installation ------------- composer install --dev Change the bootstrap bootstrap/start.php ------------- hostname -
nickdenardis revised this gist
Jul 13, 2013 . 1 changed file with 2 additions and 2 deletions.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -35,7 +35,7 @@ Install Laravel Dependencies (if you didn't install via composer) Add the needed packages package.json ------------- { "name": "laravel/laravel", "description": "The Laravel Framework.", "keywords": ["framework", "laravel"], "require": { @@ -46,7 +46,7 @@ Add the needed packages package.json "phpunit/phpunit": "3.7.*", "mockery/mockery": "0.7.*" }, "autoload": { "classmap": [ Change the bootstrap bootstrap/start.php -
nickdenardis revised this gist
Jul 13, 2013 . 1 changed file with 18 additions and 1 deletion.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -21,7 +21,7 @@ Install Composer without cert errors sudo mv composer.phar /usr/local/bin/composer Create a new project with composer ------------- composer create-project laravel/laravel appname @@ -32,6 +32,23 @@ Install Laravel Dependencies (if you didn't install via composer) php composer.phar install Add the needed packages package.json ------------- { "name": "laravel/laravel", "description": "The Laravel Framework.", "keywords": ["framework", "laravel"], "require": { "laravel/framework": "4.0.*", "way/generators": "dev-master" }, "require-dev":{ "phpunit/phpunit": "3.7.*", "mockery/mockery": "0.7.*" }, "autoload": { "classmap": [ Change the bootstrap bootstrap/start.php ------------- hostname -
nickdenardis revised this gist
Jul 13, 2013 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -32,7 +32,7 @@ Install Laravel Dependencies (if you didn't install via composer) php composer.phar install Change the bootstrap bootstrap/start.php ------------- hostname $env = $app->detectEnvironment(array( -
nickdenardis revised this gist
Jul 13, 2013 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -27,7 +27,7 @@ Download and unzip to dir composer create-project laravel/laravel appname Install Laravel Dependencies (if you didn't install via composer) ------------- php composer.phar install -
nickdenardis revised this gist
Jul 13, 2013 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -8,7 +8,7 @@ Resources Add Sublime Text 2 to the CLI ------------- sudo ln -s "/Applications/Sublime Text.app/Contents/SharedSupport/bin/subl" /usr/bin/subl Use MAMP PHP CLI ------------- -
nickdenardis revised this gist
Jul 13, 2013 . 1 changed file with 0 additions and 8 deletions.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -24,14 +24,6 @@ Install Composer without cert errors Download and unzip to dir ------------- composer create-project laravel/laravel appname -
nickdenardis revised this gist
Jul 13, 2013 . 1 changed file with 33 additions and 5 deletions.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,10 +1,10 @@ Resources ------------- https://github.com/eightygrit/deploy-laravel/blob/master/deploy-laravel.z.sh https://github.com/onigoetz/deployer https://gist.github.com/purwandi/4110547 https://gist.github.com/chipotle/5506641 Add Sublime Text 2 to the CLI ------------- @@ -42,12 +42,40 @@ Install Laravel Dependencies Change the config. /app/config/app.php ------------- hostname $env = $app->detectEnvironment(array( 'local' => array('your-machine-name'), )); Set the storage to be writable ------------- chmod -R 777 app/storage/ Edit ths app/config/database.php ------------- Use 127.0.0.1 for locahost if possible Edit the app/config/view.php ------------- 'paths' => array(__DIR__.'/../../public/views'), Edit the public/package.json ------------- { "name": "laravel4-and-foundation", "version": "0.0.1", "private": true, "dependencies": { "foundation": "*", "mustache": "*" } } cd public npm install cd .. Create a RESTful resource controller ------------- php artisan controller:make PhotoController -
nickdenardis revised this gist
Jun 20, 2013 . 1 changed file with 5 additions and 0 deletions.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -47,6 +47,11 @@ Change the config. /app/config/app.php Set the storage to be writable ------------- chmod -R 777 app/storage/ Create a RESTful resource controller ------------- php artisan controller:make PhotoController Route::resource('photo', 'PhotoController'); Deploy from github -
nickdenardis revised this gist
Jun 20, 2013 . 1 changed file with 4 additions and 0 deletions.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -6,6 +6,10 @@ https://github.com/onigoetz/deployer https://gist.github.com/purwandi/4110547 https://gist.github.com/chipotle/5506641 Add Sublime Text 2 to the CLI ------------- sudo ln -s "/Applications/Sublime Text 2.app/Contents/SharedSupport/bin/subl" /usr/bin/subl Use MAMP PHP CLI ------------- export PATH=/Applications/MAMP/bin/php/php5.3.6/bin/:$PATH -
nickdenardis revised this gist
Jun 20, 2013 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -42,7 +42,7 @@ Change the config. /app/config/app.php Set the storage to be writable ------------- chmod -R 777 app/storage/ Deploy from github -
nickdenardis revised this gist
Jun 20, 2013 . 1 changed file with 5 additions and 0 deletions.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -40,6 +40,11 @@ Change the config. /app/config/app.php ------------- Set the storage to be writable ------------- chmod -R 777 storage/ Deploy from github ------------- -
nickdenardis revised this gist
Jun 20, 2013 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -28,7 +28,7 @@ or or composer create-project laravel/laravel appname Install Laravel Dependencies -
nickdenardis revised this gist
Jun 20, 2013 . 1 changed file with 4 additions and 0 deletions.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -21,9 +21,13 @@ Download and unzip to dir ------------- https://github.com/laravel/laravel/archive/master.zip or git clone git://github.com/laravel/laravel.git ./ or composer create-project laravel/laravel -
nickdenardis revised this gist
Jun 20, 2013 . 1 changed file with 2 additions and 0 deletions.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -23,6 +23,8 @@ Download and unzip to dir https://github.com/laravel/laravel/archive/master.zip or git clone git://github.com/laravel/laravel.git ./ or composer create-project laravel/laravel Install Laravel Dependencies -
nickdenardis revised this gist
Jun 20, 2013 . 1 changed file with 5 additions and 0 deletions.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -6,10 +6,15 @@ https://github.com/onigoetz/deployer https://gist.github.com/purwandi/4110547 https://gist.github.com/chipotle/5506641 Use MAMP PHP CLI ------------- export PATH=/Applications/MAMP/bin/php/php5.3.6/bin/:$PATH Install Composer without cert errors ------------- curl -ksS https://getcomposer.org/installer | php sudo mv composer.phar /usr/local/bin/composer Download and unzip to dir -
nickdenardis revised this gist
May 29, 2013 . 1 changed file with 2 additions and 1 deletion.There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -41,4 +41,5 @@ Deploy from github https://help.github.com/articles/deploying-with-capistrano https://github.com/capistrano/capistrano/wiki/2.x-from-the-beginning http://guides.beanstalkapp.com/deployments/deploy-with-capistrano.html https://github.com/stefanooldeman/capistrano-handbook/wiki/Anatomy-of-a-capistrano-installation http://ryanflorence.com/deploying-with-capistrano-without-rails/
NewerOlder