I hereby claim:
- I am sjelfull on github.
- I am fredcarlsen (https://keybase.io/fredcarlsen) on keybase.
- I have a public key ASCXgDizO7fSlSLYrno4ro3h_lPxQJmDv390-gE6TE7qmwo
To claim this, I am signing this object:
#!/bin/bash | |
LOCAL_PARALLEL_JOBS=$1 | |
PARALLEL_JOBS=${LOCAL_PARALLEL_JOBS:-4} | |
# parallel creates a subshell, which will use the default $SHELL | |
# This makes sure php runs paralell with the correct shell | |
export SHELL=/bin/bash | |
index() { | |
echo Indexing $1 |
<?php | |
public function createProduct ($locale = null) | |
{ | |
if ( !$this->productTypes ) { | |
$this->productTypes = craft()->commerce_productTypes->getAllProductTypes(); | |
} | |
if ( !$locale ) { | |
$locale = craft()->i18n->getPrimarySiteLocaleId(); |
{# | |
// lazyLoaded Image/bgImages, optimized with Imager and Focuspoint | |
--------------------------------------------------------------------------- | |
https://nystudio107.com/blog/creating-optimized-images-in-craft-cms | |
https://github.com/aelvan/Imager-Craft | |
https://github.com/smcyr/Craft-FocusPoint | |
for the bgImage intrinsic ratio classname creation check: | |
https://github.com/inuitcss/inuitcss/blob/develop/objects/_objects.ratio.scss |
<?php | |
require __DIR__ . '/vendor/autoload.php'; | |
use Sly\PushOver\Model\Push; | |
use Sly\PushOver\PushManager; | |
if (!isset($_GET['key']) || $_GET['key'] !== 'KEY') { | |
die('No key'); | |
} | |
$monitorFriendlyName = $_GET['monitorFriendlyName']; |
<?php | |
public function actionCreateTestOrder () | |
{ | |
// Configuration | |
$customerId = 1; | |
$productId = 8; | |
$productQuantity = 5; | |
$orderStatusId = 1; | |
$paymentMethodId = 1; | |
$shippingMethodHandle = 'bring'; |
I hereby claim:
To claim this, I am signing this object:
<?php | |
public function actionCreateTestOrder () | |
{ | |
// Configuration | |
// Id of customer for this order | |
$customerId = 1; | |
$productId = 8; | |
$orderStatusId = 1; | |
$paymentMethodId = 1; |
<script type="text/javascript"> | |
(function () { | |
"use strict"; | |
// once cached, the css file is stored on the client forever unless | |
// the URL below is changed. Any change will invalidate the cache | |
var css_href = './index_files/web-fonts.css'; | |
// a simple event handler wrapper | |
function on(el, ev, callback) { | |
if (el.addEventListener) { | |
el.addEventListener(ev, callback, false); |
#!/bin/bash | |
# Execute via: ./set-project-perms.sh PROJECT_NAME | |
# The paradigm is the entire project dir is owned by $CHOWN_USER with the group set to $CHOWN_GROUP | |
# $CHOWN_USER is an admin or user account that is used to edit files/templates, etc. | |
# $CHOWN_GROUP is the group of the webserver (e.g.: 'apache', 'nginx', 'httpd', etc.) | |
# The project dir permissions are set to 755 (-rwxr-xr-x) for directories and to 644 (-rw-r--r--) for files | |
# The permissions to $DIRS[] that need to be writeable are set to 775 (-rwxrwxr-x) for directories and | |
# 664 (-rw-rw-r--) for files. Add any assets directories, etc. as necessary. | |
# Change $BASE_DIR to the absolute path where your websites are stored (leaving it appended with '/$1') |
L1 cache reference ......................... 0.5 ns
Branch mispredict ............................ 5 ns
L2 cache reference ........................... 7 ns
Mutex lock/unlock ........................... 25 ns
Main memory reference ...................... 100 ns
Compress 1K bytes with Zippy ............. 3,000 ns = 3 µs
Send 2K bytes over 1 Gbps network ....... 20,000 ns = 20 µs
SSD random read ........................ 150,000 ns = 150 µs
Read 1 MB sequentially from memory ..... 250,000 ns = 250 µs