This file contains hidden or 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 characters
// in AngularJS (client) | |
myApp.config(['$httpProvider', function($httpProvider) { | |
$httpProvider.defaults.useXDomain = true; | |
delete $httpProvider.defaults.headers.common['X-Requested-With']; | |
}]); | |
// in Express/nodeJS |
This file contains hidden or 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 characters
#!/usr/bin/env bash | |
echo ">>> Starting Install Script" | |
# Update | |
sudo apt-get update | |
# Install MySQL without prompt | |
sudo debconf-set-selections <<< 'mysql-server mysql-server/root_password password root' | |
sudo debconf-set-selections <<< 'mysql-server mysql-server/root_password_again password root' |
This file contains hidden or 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 characters
Introduction | |
------------ | |
Earlier today, I posted a screenshot of my current development environment using Chrome and figured I would put together a little more information about what all is going on here. | |
My Setup (I am a Dark Theme fan) | |
-------------------------------- | |
As a recap, here is the screenshot I posted: |
This file contains hidden or 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 characters
RAWFORKNEW | |
<?php | |
/* --- Laracasts Presenters Lesson Homework --- */ | |
/* | |
In order to provide the ability to call a method on the object we need the __call() method | |
If we convert the existing __get() method to a __call() method then we can no longer call the method as a property | |
ie. $user->gravitar will throw an error that the property does not exist | |
So we need both __call() and __get() | |
For flexibility the __get() method will handle properties but will also convert $user->gravitar to $user->gravitar() | |
If no method exists then __get() will call it as a property |
This file contains hidden or 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 characters
gu () { | |
if [ -z "$1" ]; then msg="code update"; else msg=$1; fi | |
git add . -A && git commit -m "$msg" && git push | |
} |
This file contains hidden or 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 characters
#!/bin/bash | |
# Current Version 0.0.9 | |
# dont forget to create write permissions on this file | |
# 2013-12-20: 0.0.9 | |
# - refactored .bowerrc to store in 'lib' instead of components | |
# 2013-12-16: 0.0.8 | |
# - Updated Gruntfile.js and .jshint gist referece |
This file contains hidden or 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 characters
module.exports = function(grunt){ | |
'use strict'; | |
grunt.initConfig({ | |
pkg: grunt.file.readJSON('package.json'), | |
conf: { | |
js_files: 'public/js/**/*.js', | |
css_files: 'public/css/**/*.css', | |
css_path: 'public/css/', | |
test_files: 'app/tests/*.php', |
This file contains hidden or 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 characters
{ | |
"name": "laravel-rest", | |
"version": "0.0.1", | |
"description": "Sample Laravel Restified Application", | |
"main": "Gruntfile.js", | |
"dependencies": { | |
"grunt": "~0.4.2" | |
}, | |
"devDependencies": { | |
"grunt": "~0.4.2", |
This file contains hidden or 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 characters
Show hidden characters
{ | |
"curly": true, // true: Require {} for every new block or scope | |
"eqeqeq": true, // true: Require triple equals (===) for comparison | |
"immed": true, // true: Require immediate invocations to be wrapped in parens e.g. `(function () { } ());` | |
"latedef": true, // true: Require variables/functions to be defined before being used | |
"newcap": true, // true: Require capitalization of all constructor functions e.g. `new F()` | |
"noarg": true, // true: Prohibit use of `arguments.caller` and `arguments.callee` | |
"sub": true, // true: Tolerate using `[]` notation when it can still be expressed in dot notation | |
"undef": true, // true: Require all non-global variables to be declared (prevents global leaks) | |
"boss": true, // true: Tolerate assignments where comparisons would be expected |
This file contains hidden or 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 characters
<h3> | |
<a href="http://http://getbootstrap.com" target="_blank"><img src="http://codedungeon-public.s3.amazonaws.com/bootstrap-logo.jpg" width="65%" height="65%"></a> | |
<a href="http://www.gruntjs.com" target="_blank"><img src="http://codedungeon-public.s3.amazonaws.com/grunt-logo.png" width="85%" height="85%"></a> | |
<a href="http://www.lesscss.org" target="_blank"><img src="http://codedungeon-public.s3.amazonaws.com/less-logo.png"></a> | |
<a href="http://bower.io" target="_blank"><img src="http://codedungeon-public.s3.amazonaws.com/bower-logo.png" width="55%" height="55%"></a> | |
<a href="https://github.com/sebastianbergmann/phpunit/" target="_blank"><img src="http://codedungeon-public.s3.amazonaws.com/phpunit-logo.jpg"></a> | |
</h3> |