Skip to content

Instantly share code, notes, and snippets.

Peter Jaap Blaakmeer peterjaap

Block or report user

Report or block peterjaap

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
gititGoro /
Last active Oct 13, 2019
Environmental setup for Ethereum Dev as of 14 June 2017

Setting up a private ethereum blockchain for development and pointing your wallet at it

Ethereum tutorials all advise downloading the Mist wallet and beginning dev. The only problem is that the testnet and real blockchain are huge and take hours to download. What follows is a recipe for quickly setting up a small blockchain and pre-mining it with some test ethereum

The following is done in Linux but will work in MacOS and should have equivalent command line options in Windows. Where I don't give detailed instructions, it's because a quick google search will fill in the blanks.

Install geth

install Mist

erikhansen / 1_product_queries.sql
Last active Oct 29, 2019
Magento 2 - Remove duplicate store view-specific product and category data
View 1_product_queries.sql
* IMPORTANT: The queries below are written for Magento Enterprise. If you're going to run them on Magento Community, you need
* to replace all instances of ".row_id" with ".entity_id". See this for context:
* When importing products in Magento 2, if you specify store view codes in the store_view_code column, product data will be set at
* both the global scope as well as the specific store view scope. This is not ideal because now you have duplicate
* data at two different scopes that shouldn't actually be duplicated. The scripts below clean up this data by finding
* data set at specific store view scopes and if it's an exact match to the data set at the global store view, then it
* deletes the data set at the specific store view scope.
erfanimani / prepare-magento-deployment
Last active Jun 5, 2016
Prepare Magento deployment hook for (Install Composer Dependencies - After)
View prepare-magento-deployment
cd {{project}}
mkdir -p storage/media
mkdir -p storage/var
chmod -fR g+w storage || true
cp -rTv {{release}}/docroot/media/ storage/media/
cp -rTv {{release}}/docroot/var/ storage/var/
rm -r {{release}}/docroot/media
IvanChepurnyi / Table.php
Last active Jan 20, 2017
Optimized options load
View Table.php
* Optimized version of attribute source options model
* That allows to preload options once and reuse them instead of doing calls to db all the time
class EcomDev_Optimization_Model_Resource_Attribute_Source_Table
extends Mage_Eav_Model_Entity_Attribute_Source_Table
edannenberg / magento_url_rewrite.patch
Last active Oct 10, 2019
Fixes the catalog url rewrite indexer in Magento 1.7.x-1.9.x See for details.Update: DexterDee in the ticket above noted that the previous patch had some side effects. This updated patch still feels like duct tape but at least it seems to be free of the mentioned side effects. It also fix…
View magento_url_rewrite.patch
diff -rupN mage_org/app/code/core/Mage/Catalog/Model/Url.php src_shop/app/code/core/Mage/Catalog/Model/Url.php
--- mage_org/app/code/core/Mage/Catalog/Model/Url.php 2013-11-19 00:48:25.679009391 +0100
+++ src_shop/app/code/core/Mage/Catalog/Model/Url.php 2013-11-19 00:49:24.188005601 +0100
@@ -643,13 +643,24 @@ class Mage_Catalog_Model_Url
$this->_rewrite = $rewrite;
return $requestPath;
+ // avoid unnecessary creation of new url_keys for duplicate url keys
+ $noSuffixPath = substr($requestPath, 0, -(strlen($suffix)));
shennyg /
Created Jun 26, 2011 — forked from JackDanger/
remove large binary files from git history
set -o errexit
# Author: David Underhill
# Script to permanently delete files/folders from your git repository. To use
# it, cd to your repository's root and then run the script with a list of paths
# you want to delete, e.g., git-delete-history path1 path2
# retrieved from:
You can’t perform that action at this time.