Skip to content

Instantly share code, notes, and snippets.

DEBUG="usemin:usemin,fileprocessor,revvedfinder" grunt yourTaskname
@foiseworth
foiseworth / .htaccess
Created December 30, 2012 08:53
Conditional rewrite for Laravel that allows for site at root level or localhost subfolder (if using wamp etc).
# Apache configuration file
# http://httpd.apache.org/docs/2.2/mod/quickreference.html
# Note: ".htaccess" files are an overhead for each request. This logic should
# be placed in your Apache config whenever possible.
# http://httpd.apache.org/docs/2.2/howto/htaccess.html
# Turning on the rewrite engine is necessary for the following rules and
# features. "+FollowSymLinks" must be enabled for this to work symbolically.
@foiseworth
foiseworth / gist:3897990
Created October 16, 2012 08:16 — forked from lucasfais/gist:1207002
Sublime Text 2 - Useful Shortcuts

Sublime Text 2 – Useful Shortcuts (Mac OS X)

General

⌘T go to file
⌘⌃P go to project
⌘R go to methods
⌃G go to line
⌘KB toggle side bar
⌘⇧P command prompt
@foiseworth
foiseworth / site.php
Created October 14, 2012 16:16
Concrete5 site config file for working locally and remotely using same file
<?php
$host = $_SERVER['HTTP_HOST'];
if ($host === 'localhost')
{
define('DB_SERVER', 'LOCAL-SERVER');
define('DB_USERNAME', 'LOCAL-USERNAME');
define('DB_PASSWORD', 'LOCAL-PASSWORD');
define('DB_DATABASE', 'LOCAL-DATABASE');
@foiseworth
foiseworth / .gitignore
Created October 14, 2012 15:38
.gitignore starter for Concrete5 / Sublime / Sass & Compass / htaccess
## Concrete5
files/cache/*
files/tmp/*
## Sublime files
*.sublime-project
*.sublime-workspace
sftp-config.json
## Sass / Compass
@foiseworth
foiseworth / gist:3888913
Created October 14, 2012 15:27
Webfaction post receive hook to deploy website
GIT_WORK_TREE=/home/ACCOUNT_NAME/webapps/APP_NAME git checkout -f
GIT_WORK_TREE=/home/ACCOUNT_NAME/webapps/APP_NAME git reset --hard