View gist:9679452
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$less = file_get_contents(__DIR__ . '/app.less'); | |
preg_match_all('/#([a-fA-F0-9]){3}(([a-fA-F0-9]){3})?\b/', $less, $matches); | |
$colors = array_values($matches[0]); | |
$colors = array_map(function($color){ return strtolower($color); }, $colors); | |
$colors = array_unique($colors); | |
sort($colors); |
View pre-push
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
CMD="make php-cs" | |
# Check if we actually have commits to push | |
commits=`git log @{u}..` | |
if [ -z "$commits" ]; then | |
exit 0 | |
fi |
View composer.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "adrian/installer-test", | |
"license": "proprietary", | |
"type": "project", | |
"autoload": { | |
"psr-0": { | |
"": "src/", | |
"SymfonyStandard": "app/" | |
} | |
}, |
View icons.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<i class="icon icon--play-1"></i> | |
<i class="icon icon--repeat-1"></i> | |
<i class="icon icon--x-1"></i> | |
<i class="icon icon--up-1"></i> | |
<i class="icon icon--right-1"></i> | |
<i class="icon icon--down-1"></i> | |
<i class="icon icon--left-1"></i> | |
<i class="icon icon--up-2"></i> | |
<i class="icon icon--right-2"></i> | |
<i class="icon icon--down-2"></i> |
View jquery.mNI.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Extend jQuery to add a function for implementing "Nice Inputs" | |
jQuery.fn.makeNiceInput = function(){ | |
// Setup the selected elements as nice inputs. | |
jQuery(this).each(function(){ | |
if(jQuery('label[for='+jQuery(this).attr('id')+']').length > 0){ | |
var MNval = jQuery('label[for='+jQuery(this).attr('id')+']').hide().text(); |
View localscroll.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$(document).ready(function(){ | |
// Local Scroll | |
function filterPath(string) { | |
return string.replace(/^\//,'').replace(/(index|default).[a-zA-Z]{3,4}$/,'').replace(/\/$/,''); | |
} | |
$('a[href*=#]').each(function() { | |
if ( | |
filterPath(location.pathname) == filterPath(this.pathname) | |
&& location.hostname == this.hostname | |
&& this.hash.replace(/#/,'') |
View gist:794452
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$(function(){ | |
/// fun times :D | |
}); |
View gist:1445318
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* @Route("/school/search/", name="school_search") | |
* @Template("FlintSAKGFKitchenGardenProfileBundle:Default:school-search.html.twig") | |
* @param \Symfony\Component\HttpFoundation\Request $request | |
* @return array | |
*/ | |
public function searchAction(Request $request) | |
{ |
View gist:2364646
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div class="something"> | |
<div class="third">first child, no left padding.</div> | |
<div class="third">left padding</div> | |
<div class="third something"> | |
left padding | |
<div class="half">first child, no left padding</div> | |
<div class="half">left padding.</div> | |
</div> | |
</div> |
View r-boilerplate.css
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Mobile / General Styles | |
--- | |
Code up general styles and mobile styles, use media queries to adapt to larger displays. | |
Things for this section: Reset, Typography, Baseline grid, etc. Convenience methods for image-replacement, hiding, clearing etc. | |
*/ | |
/* Desktop and iPad/Tablet specific styles. */ |
OlderNewer