Skip to content

Instantly share code, notes, and snippets.

@atadams
atadams / zip_directory.sh
Created January 23, 2013 14:22
Terminal: Zip Files in Directory Recursively
for i in `find . -name "*.log"`; do zip -j $i.zip $i;done;
@atadams
atadams / delete_recursive.sh
Last active December 11, 2015 13:18
Terminal: Delete Files Recursively
find . -name '*.log' -type f -delete
@atadams
atadams / tidy-html5.sh
Last active December 12, 2015 05:39
Terminal: tidy-html5
tidy --vertical-space n --indent a --wrap 0 --preserve-entities y --tidy-mark n tidytest.html | unexpand -a -t 2 > tidyoutput1.html
@atadams
atadams / gist:5943737
Last active December 19, 2015 10:49
Mura: Active Content
WHERE
(
tcontent.Active = 1
AND tcontent.Approved = 1
AND tcontent.siteid = <cfqueryparam cfsqltype="cf_sql_varchar" value="#arguments.siteID#"/>
)
AND (
tcontent.Display = 2
AND (
@atadams
atadams / CSS-Only:-Hamburger-Menu-Icon.markdown
Created May 29, 2014 13:21
A Pen by Christopher Schulz.

Using Subsystems

Subsystems give you a way of dropping in one FW/1 application into an existing one. Subsystems can be used to create a module that has no dependencies on the parent application or you can use subsystems to group common functionality together.

Enabling Subsystems

If you want to enable subsystems, you must set the following in the parent application’s Application.cfc:

variables.framework.usingSubsystems = true;
// Location to your properties file
var pFile = 'location_to_your_properties_file/filename.properties';
// Init Props
var props = CreateObject("java","java.util.Properties").init();
// Load the file into the props
props.load( CreateObject("java","java.io.FileInputStream").init(pFile) );
// Assume properties file has the following value
// Property1=Foo
// Property2=Bar
@atadams
atadams / _crayon.scss
Last active August 29, 2015 14:25
Crayon (https://github.com/riccardoscalco/crayon) SCSS file with HSL colors sorted by hue, saturation, and lightness.
$black : hsl(0, 0%, 0%);
$eerieblack : hsl(0, 0%, 11%);
$granitegray : hsl(0, 0%, 40%);
$sonicsilver : hsl(0, 0%, 46%);
$quicksilver : hsl(0, 0%, 65%);
$culturedpearl : hsl(0, 0%, 96%);
$coconut : hsl(0, 0%, 100%);
$white : hsl(0, 0%, 100%);
$fuzzywuzzy : hsl(0, 50%, 60%);
$orangered : hsl(0, 100%, 58%);
@atadams
atadams / _color-definitions.scss
Created February 25, 2016 14:54
Google Material Design Color Definitions in HSLA
// Color order: 50, 100, 200, 300, 400, 500, 600, 700, 800, 900, A100, A200,
// A400, A700.
// $palette-red:
$palette-red-50: hsla(351, 100%, 96%, 1);
$palette-red-100: hsla(354, 100%, 90%, 1);
$palette-red-200: hsla(0, 73%, 77%, 1);
$palette-red-300: hsla(0, 69%, 67%, 1);
$palette-red-400: hsla(1, 83%, 63%, 1);
$palette-red-500: hsla(4, 90%, 58%, 1);