Skip to content

Instantly share code, notes, and snippets.

Patrick van der Leer patvdleer

Block or report user

Report or block patvdleer

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
View micropython_ESP32.sh
#!/bin/bash
sudo apt install libffi-dev pkg-config build-essential git
SUBDIR=esp
cd ~
mkdir -p $SUBDIR
cd $SUBDIR
@patvdleer
patvdleer / mqtt.py
Created Aug 3, 2017
Paho MQTT client wrapper
View mqtt.py
import random
import string
import threading
import paho.mqtt.client as paho
from . import logger
class Client(paho.Client):
@patvdleer
patvdleer / packtsub.py
Last active Jun 17, 2019
packtpub daily claimer/downloader
View packtsub.py
import os
import re
import shutil
import sys
import requests
try:
import argparse
except ImportError:
sys.stderr.write("The Python module argparse is required")
@patvdleer
patvdleer / cms_fix.php
Created Feb 21, 2017
Magento clean cms blocks
View cms_fix.php
<?php
require_once 'abstract.php';
class X043_Shell_CMSFixer extends Mage_Shell_Abstract {
public function getCollection() {
return Mage::getModel('cms/block')->getCollection();
}
You can’t perform that action at this time.