Skip to content

Instantly share code, notes, and snippets.

@jdsimcoe
jdsimcoe / home.xml
Last active August 29, 2015 14:07 — forked from bauhouse/home.xml
<?xml version="1.0" encoding="utf-8" ?>
<data>
<params>
<today>2011-10-27</today>
<current-time>16:00</current-time>
<this-year>2011</this-year>
<this-month>10</this-month>
<this-day>27</this-day>
<timezone>-07:00</timezone>
<website-name>Symphony CMS</website-name>
@jdsimcoe
jdsimcoe / OopsieFocus.applescript
Created September 1, 2014 20:36
Tells OmniFocus to open and activates the Quick Entry if it is not already open. Does nothing if it is open. This script is modified to work with the Standard App Store version of OF2. It assumes that your Quick Entry shortcut is “control + option + command + t” like mine is. Fork and modify at will!
set GTDAppName to "OmniFocus"
global GTDAppName
set GTDAppToUse to FindRunningGTDApp()
if (GTDAppToUse is null) then
set GTDAppToUse to "OmniFocus"
end if
-- Is OmniFocus running?
on AppIsRunning(GTDAppName)
tell application "System Events"
/*!
* Grunt
* $ npm install grunt-contrib-uglify grunt-autoprefixer grunt-contrib-cssmin grunt-contrib-imagemin grunt-contrib-sass grunt-contrib-watch grunt-contrib-concat grunt-contrib-clean grunt-contrib-jshint grunt-notify --save-dev
*/
module.exports = function(grunt) {
grunt.initConfig({
// Sass

Templating in EE vs. Craft

Lots of people have asked, so here are a few common tasks you might do in your templates, as they would be written in ExpressionEngine vs. Craft.

Table of Contents

  1. Comments
  2. Conditionals
  3. Loops
<?php
/*
|--------------------------------------------------------------------------
| Application Routes
|--------------------------------------------------------------------------
|
| Here is where you can register all of the routes for an application.
| It's a breeze. Simply tell Laravel the URIs it should respond to
| and give it the Closure to execute when that URI is requested.
export PATH="/usr/local/mysql/bin:$PATH"
[[ -s "/Users/Steven/.rvm/scripts/rvm" ]] && source "/Users/Steven/.rvm/scripts/rvm" # Load RVM into a shell session *as a function*
[[ -s "$HOME/.rvm/scripts/rvm" ]] && . "$HOME/.rvm/scripts/rvm"
parse_git_branch() {
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/(\1)/'
}
<VirtualHost *:80>
ServerName pow
ServerAlias *.dev
ServerAlias *.xip.io
ProxyPass / http://localhost:20559/
ProxyPassReverse / http://localhost:20559/
ProxyPreserveHost On
</VirtualHost>
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>site_mozo</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>com.demandware.studio.core.beehiveElementBuilder</name>
<arguments>

Susy Tutorial

For this tutorial I'm assuming you are already comfortable with CSS, Sass (I'll use the SCSS syntax) and Compass. Please get set up with each one of those before attempting to use Susy. Sass and Compass both have their own setup instructions and tutorials that you can use.

There is also reference documentation in the works.

What Susy Does

CSS Systems

@jdsimcoe
jdsimcoe / gist:9138238
Created February 21, 2014 16:56
HTML div class element
<xsl:attribute name="class">
<xsl:choose>
<xsl:when test="count(/data/locations-all/entry) = 4 and position() = 4">
<xsl:text>col-md-4 col-md-offset-4</xsl:text>
</xsl:when>
<xsl:when test="count(/data/locations-all/entry) = 5 and position() = 4">
<xsl:text>col-md-4 col-md-offset-2</xsl:text>
</xsl:when>
<xsl:otherwise>
<xsl:text>col-md-4</xsl:text>