Skip to content

Instantly share code, notes, and snippets.

View rupl's full-sized avatar
💭
¯\_(ツ)_/¯

Chris Ruppel rupl

💭
¯\_(ツ)_/¯
View GitHub Profile
@rupl
rupl / wat.html
Created August 5, 2011 17:43 — forked from pifantastic/wat.html
<ul>
<li>1.0
<li>2.0
<ul>
<li>2.1
<li>2.2
^ this would render incorrectly
VS.
@rupl
rupl / settings.php
Created August 19, 2011 21:56
Allows regular drush commands without -l arg when using super awesome dynamic vhost
/**
* Allow developers to override settings.
*/
define('SWEET_ASS_STAGE_SETTINGS_REGEX', '/^(dca11\.webchefs\.org|dca11\.dev1\.fourkitchens\.com)(:\d+)*$/');
define('SWEET_ASS_USER_SETTINGS_REGEX', '/^(.*)\.(.*)\.(webchefs\.org|dev1\.fourkitchens\.com)(:\d+)*$/');
if (preg_match(SWEET_ASS_USER_SETTINGS_REGEX, $_SERVER['HTTP_HOST'], $matches)) {
// Load general dev settings.
if (file_exists('sites/default/settings.dev.php')) {
include_once 'sites/default/settings.dev.php';
@rupl
rupl / gist:2048533
Created March 16, 2012 04:39
Conditional classes (but not specifying UA)
<!--[if (lte IE 8)&(!IEMobile)]><html class="no-mq"><![endif]-->
<!--[if (gte IE 9)|(IEMobile)]><!--><html><!--<![endif]-->
@rupl
rupl / gist:2121547
Created March 19, 2012 17:56
RWD Denver Training mobile-first rough example
html, body {
padding: 0;
}
html {
-webkit-box-shadow: inset 0px 0px 55px 0px rgba(0, 0, 0, 0.2);
-moz-box-shadow: inset 0px 0px 55px 0px rgba(0, 0, 0, 0.2);
box-shadow: inset 0px 0px 55px 0px rgba(0, 0, 0, 0.2);
}
@rupl
rupl / gist:2172739
Created March 23, 2012 16:55
Starter .gitconfig
[color]
ui = auto
[color "branch"]
current = yellow reverse
local = yellow
remote = green
[color "diff"]
meta = yellow bold
frag = magenta bold
old = red bold
diff --git a/drush/respondjs.drush.inc b/drush/respondjs.drush.inc
index 0226974..1f1b8da 100644
--- a/drush/respondjs.drush.inc
+++ b/drush/respondjs.drush.inc
@@ -6,6 +6,11 @@
*/
/**
+ * The URI to the respond.js library.
+ */
@rupl
rupl / gist:2507359
Created April 27, 2012 08:16 — forked from webchick/gist:2503918
Only bluecheese errors.
Warning: Illegal offset type in unset in drupal_get_messages() (line 1791 of /var/www/git-dev.drupal.org/htdocs/includes/bootstrap.inc).
Warning: Illegal offset type in isset or empty in drupal_get_messages() (line 1793 of /var/www/git-dev.drupal.org/htdocs/includes/bootstrap.inc).
Notice: Undefined variable: search_box in include() (line 21 of /var/www/git-dev.drupal.org/htdocs/sites/all/themes/bluecheese/tpl/page.tpl.php).
// SASS
.header-main ul.inline li {
& a:hover {
background-color: $dkblue;
}
&.active-trail a {
background-color: $dkblue;
}
}
// Same as rgba(), in fact, browsers re-map hsla() to rgba() internally,
// except IE9 who retains it as hsla
Modernizr.addTest('hsla', function() {
setCss('background-color:hsla(120,40%,100%,.5)');
return contains(mStyle.backgroundColor, 'rgba') || contains(mStyle.backgroundColor, 'hsla');
});
//
// All lines starting with "//" will not show up in the style.css
// However, the following lines inside "/* ... */" WILL show up.
//
// The visible comment below is there to warn any developer who
// opens a .css file that they need to edit the .scss versions ONLY.
// But you already know that because you're reading this :)
//
/*