Skip to content

Instantly share code, notes, and snippets.

View ericlbarnes's full-sized avatar
🎵
git push it, git push it real good

Eric Barnes ericlbarnes

🎵
git push it, git push it real good
View GitHub Profile
<?
//
// AUTO KEYWORD-BASED FOLLOWER CURATION BOT (by @levelsio)
//
// File: twitterFollowerCuratorBot.php
//
// Created: May 2021
// License: MIT
//
@JeffreyWay
JeffreyWay / bootstrap.sh
Created October 23, 2013 19:28
Beginning bootstrap.sh file for https://laracasts.com/lessons/vagrant-simplified lesson.
#!/usr/bin/env bash
sudo apt-get update
sudo apt-get install -y python-software-properties
sudo add-apt-repository -y ppa:ondrej/php5
sudo apt-get update
#!/usr/bin/env bash
# Configurable variables
database='vagrant'
username='vagrant'
password='vagrant'
echo ''
echo ' ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~'
echo ' Bootstrapping Ubuntu Precise 32bit for Laravel 4'
@dhrrgn
dhrrgn / parse.php
Created June 19, 2013 15:32
Parsing basic Jekyll format in PHP
<?php
// Note, you need symfony/yaml to parse the Front Matter
if ( ! Input::hasFile('file'))
{
// Do some fail here
return;
}
$contents = trim(File::get(Input::file('file')->getRealPath()));
@dhrrgn
dhrrgn / database.php
Created June 18, 2013 14:09
The database config file for Wardrobe on AppFog
<?php
$services_json = json_decode(getenv("VCAP_SERVICES"), true);
$mysql_config = $services_json["mysql-5.1"][0]["credentials"];
return array(
/*
|--------------------------------------------------------------------------
| PDO Fetch Style
|--------------------------------------------------------------------------
|
@JeffreyWay
JeffreyWay / laravel4.md
Created November 19, 2012 16:37
Laravel 4 Thoughts/Questions/Etc.

Laravel 4 Thoughts/Questions/Etc.

This is just a random list of notes, as I dig into Laravel 4. If you have any feedback/solutions, please leave a comment. I'll be compiling everything for an article on Nettuts+, when the framework is officially in Beta. This will be updated over the course of the week.

  • Running composer dump-autoload after every new controller is a pain. Can this not be automated through artisan controller:make ControllerName?

  • Seems that some of the View HTML helpers are missing. No HTML::script().

  • Route::resource('tasks', 'TasksController') doesn't seem to create named routes. This is a big deal, if not. What's the solution?

@erikreagan
erikreagan / mac-apps.md
Created August 4, 2012 19:18
Mac developer must-haves

Mac web developer apps

This gist's comment stream is a collection of webdev apps for OS X. Feel free to add links to apps you like, just make sure you add some context to what it does — either from the creator's website or your own thoughts.

— Erik

@alexkingorg
alexkingorg / wp-stats.php
Created January 3, 2012 04:28
WordPress per-year blog stats
<?php
header('Content-type: text/plain');
global $wpdb;
?>
<table class="numbers">
<thead>
<tr>
<th>&nbsp;</th>
@ritcheyer
ritcheyer / SublimeText2IconFix.sh
Created November 7, 2011 18:42
Fix Sublime Text 2 icon after update
sudo curl -L -o icon.zip http://eandjdesign.com/icons/SublimeText2/icon.zip && unzip icon.zip && mv Sublime\ Text\ 2.icns /Applications/Sublime\ Text\ 2.app/Contents/Resources/
@jimeh
jimeh / jquery.myplugin.coffee
Created April 7, 2011 23:44
Example jQuery plugin written in CoffeeScript, and the resulting compiled JavaScript file.
$.fn.extend
myplugin: (options) ->
self = $.fn.myplugin
opts = $.extend {}, self.default_options, options
$(this).each (i, el) ->
self.init el, opts
self.log el if opts.log
$.extend $.fn.myplugin,
default_options: