Skip to content

Instantly share code, notes, and snippets.

View cwoodley's full-sized avatar

Cale Woodley cwoodley

View GitHub Profile
@cwoodley
cwoodley / index.js
Last active June 12, 2018 08:32
Array and Object Manipulation
const games = [
{ title: 'halo', year: '2001' },
{ title: 'metroid', year: '1986' },
{ title: 'contra', year: '1987' },
{ title: 'overwatch', year: '2016' },
{ title: 'uncharted', year: '2007' }
]
// how do we list these by year?
@cwoodley
cwoodley / .gitignore
Created June 11, 2014 03:17
Wordpress .gitignore file
sitemap.xml
*.log
sitemap.xml.gz
*.sass-cache
.DS_Store
.Spotlight-V100
.Trashes
.htaccess
/wp-content/uploads/
config.codekit
@cwoodley
cwoodley / css_resources.md
Created April 16, 2014 07:54 — forked from jookyboi/css_resources.md
CSS libraries and guides to bring some order to the chaos.

Libraries

  • 960 Grid System - An effort to streamline web development workflow by providing commonly used dimensions, based on a width of 960 pixels. There are two variants: 12 and 16 columns, which can be used separately or in tandem.
  • Compass - Open source CSS Authoring Framework.
  • Bootstrap - Sleek, intuitive, and powerful mobile first front-end framework for faster and easier web development.
  • Font Awesome - The iconic font designed for Bootstrap.
  • Zurb Foundation - Framework for writing responsive web sites.
  • SASS - CSS extension language which allows variables, mixins and rules nesting.
  • Skeleton - Boilerplate for responsive, mobile-friendly development.

Guides

@cwoodley
cwoodley / gist:10818419
Created April 16, 2014 06:43
Nextgen Gallery ordered list of galleries with thumbnails
<ul>
<?php
global $wpdb, $nggRewrite, $nggdb;
$galleries = $wpdb->get_results("SELECT * FROM ".$wpdb->prefix."ngg_gallery ORDER BY gid ASC", ARRAY_A);
foreach ( $galleries as $gallery ) {
$previewpic = $gallery['previewpic'];
$thumbnail = $nggdb->find_image($previewpic);
@cwoodley
cwoodley / Gruntfile.js
Created November 19, 2013 11:30
Sample Gruntfile for small, static sites.
module.exports = function(grunt) {
grunt.initConfig({
clean: {
build: [
'build'
]
},
copy: {
main: {
files: [{
# @gf3’s Sexy Bash Prompt, inspired by “Extravagant Zsh Prompt”
# Shamelessly copied from https://github.com/gf3/dotfiles
# Screenshot: http://i.imgur.com/s0Blh.png
if [[ $COLORTERM = gnome-* && $TERM = xterm ]] && infocmp gnome-256color >/dev/null 2>&1; then
export TERM=gnome-256color
elif infocmp xterm-256color >/dev/null 2>&1; then
export TERM=xterm-256color
fi
<head>
<script type='text/javascript' src='http://ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js'></script>
<script type='text/javascript' src='http://ajax.googleapis.com/ajax/libs/jqueryui/1.9.2/jquery-ui.min.js'></script>
<style>
#map_viewport {
cursor: move;
height: 795px;
overflow: hidden;
#!/bin/bash
# Run iTerm.app once, quit & run script from Terminal.app
MONOKAI='{
"Ansi 0 Color" = {
"Blue Component" = 0.0;
"Green Component" = 0.0;
"Red Component" = 0.0;
};
# Path to your oh-my-zsh configuration.
export ZSH=$HOME/.oh-my-zsh
# Set to the name theme to load.
# Look in ~/.oh-my-zsh/themes/
export ZSH_THEME="prose"
# Set to this to use case-sensitive completion
# export CASE_SENSITIVE="true"