This file contains hidden or 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 | |
| namespace App\Jobs\Debounce; | |
| use Illuminate\Support\Facades\Redis; | |
| use App\Jobs\Debounce\EnsureToRunLastJob; | |
| use Illuminate\Support\Str; | |
| class DebounceService | |
| { |
This file contains hidden or 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
| // Adapted from the awesome zurb foundation | |
| // https://github.com/zurb/foundation/blob/v5.2.0/scss/foundation/components/_block-grid.scss | |
| // | |
| // Block Grid Mixins | |
| // | |
| // We use this to control the maximum number of block grid elements per row | |
| $block-grid-elements: 12 !default; |
This file contains hidden or 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
| Grab the 'PHP Remote Debugging Client' (the pre-complied xdebug binary for OSX) from here: | |
| http://code.activestate.com/komodo/remotedebugging/ | |
| Unzip it, find the folder that corresponds to the version of PHP you want to install it for and copy the xdebug.so file from there into your php extensions folder in the relevant PHP version directory. E.g. for PHP 5.4: | |
| /Applications/AMPSS/php-5.4/lib/extensions/ext/ | |
| Now open PHP.ini in a text editor: | |
| /Applications/AMPSS/php-5.4/etc/php.ini |
This file contains hidden or 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
| ffprobe -v quiet -print_format json -show_format -show_streams "lolwut.mp4" > "lolwut.mp4.json" |
This file contains hidden or 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 global $woocommerce; ?> | |
| <a class="cart-contents" href="<?php echo $woocommerce->cart->get_cart_url(); ?>" title="<?php _e('View your shopping cart', 'woothemes'); ?>"><?php echo sprintf(_n('%d item', '%d items', $woocommerce->cart->cart_contents_count, 'woothemes'), $woocommerce->cart->cart_contents_count);?> - <?php echo $woocommerce->cart->get_cart_total(); ?></a> | |
| // Ensure cart contents update when products are added to the cart via AJAX (place the following in functions.php) | |
| add_filter('add_to_cart_fragments', 'woocommerce_header_add_to_cart_fragment'); | |
| function woocommerce_header_add_to_cart_fragment( $fragments ) { | |
| global $woocommerce; | |
| ob_start(); |
This file contains hidden or 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
| # | |
| # Cookbook Name:: whenever | |
| # Recipe:: default | |
| # | |
| ey_cloud_report "whenever" do | |
| message "starting whenever recipe" | |
| end | |
| # Set your application name here |
This file contains hidden or 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've wrapped Makoto Matsumoto and Takuji Nishimura's code in a namespace | |
| so it's better encapsulated. Now you can have multiple random number generators | |
| and they won't stomp all over eachother's state. | |
| If you want to use this as a substitute for Math.random(), use the random() | |
| method like so: | |
| var m = new MersenneTwister(); |