Skip to content

Instantly share code, notes, and snippets.

@benstr
benstr / readme.md
Created January 31, 2014 22:11
Gist Markdown Cheatsheet

#Heading 1 ##Heading 2 ###Heading 3 ####Heading 4 #####Heading 5 ######Heading 6


Paragraph

@benstr
benstr / genericEmailDomains.js
Created February 28, 2019 18:51
List of generic free email providers
var domains = [
/* Default domains included */
"aol.com", "att.net", "comcast.net", "facebook.com", "gmail.com", "gmx.com", "googlemail.com",
"google.com", "hotmail.com", "hotmail.co.uk", "mac.com", "me.com", "mail.com", "msn.com",
"live.com", "sbcglobal.net", "verizon.net", "yahoo.com", "yahoo.co.uk",
/* Other global domains */
"email.com", "fastmail.fm", "games.com" /* AOL */, "gmx.net", "hush.com", "hushmail.com", "icloud.com",
"iname.com", "inbox.com", "lavabit.com", "love.com" /* AOL */, "outlook.com", "pobox.com", "protonmail.com",
"rocketmail.com" /* Yahoo */, "safe-mail.net", "wow.com" /* AOL */, "ygm.com" /* AOL */,
@benstr
benstr / mkrnb_holo_jumper.ino
Created January 29, 2019 05:08
NB MKR1500 example [ugly]
/*
Hologram Demo - GSM Network Jumping
This example shows how to switch between carriers using a Hologram SIM.
Circuit:
* MKR NB 1500 board
* Antenna
* Hologram SIM card
Created 12 Dec 2018
by Benstr
*/
@benstr
benstr / Meteor_uihooks.md
Last active January 25, 2022 09:02
_uihooks Examples

Add preliminary API for registering hooks to run when Blaze intends to insert, move, or remove DOM elements. For example, you can use these hooks to animate nodes as they are inserted, moved, or removed. To use them, you can set the _uihooks property on a container DOM element. _uihooks is an object that can have any subset of the following three properties:

  • insertElement: function (node, next): called when Blaze intends to insert the DOM element node before the element next
  • moveElement: function (node, next): called when Blaze intends to move the DOM element node before the element next
  • removeElement: function (node): called when Blaze intends to remove the DOM element node

Note that when you set one of these functions on a container element, Blaze will not do the actual operation; it's your responsibility to actually insert, move, or remove the node (by calling $(node).remove(), for example).

https://github.com/meteor/meteor/blob/30fb11f1fa0227f1c0ec3eb30b7864ea3b2d210e/History.md

@benstr
benstr / mergeJSON.js
Created November 4, 2014 06:54
Node script to deep merge JSON files
var merge = require('deepmerge');
var fs = require('fs');
var a = require('./json/a-start.json');
var b = require('./json/collections.json');
var c = require('./json/z-sample-fields.json');
var merge1 = merge(a, b);
var merge2 = merge(merge1, c);
@benstr
benstr / meteor-full-stack-learn.md
Last active October 1, 2021 11:52
Meteor Full Stack How To Learn

#How do I become a web app developer - Meteor style

What does an aspiring web developer need to know to develop a Meteor app? Below is a list of languages, frameworks, libraries, packages & more ;) .

The lists that follow are purposely ordered, unless noted. This article does not explain why you need to learn each item (that is up to you to figure out). Instead this article's purpose is to provide a quick roadmap or "thousand mile" view of the technologies a Meteor Dev works with daily.

When you are in the weeds of learning new things it feels good knowing you have a map to reference and measure your progress against.

nemo's escape

@benstr
benstr / b64-cellular.py
Created January 9, 2018 16:53
Example using base64 encoding to send a image over cellular on a Raspberry Pi with Hologram.io
from Hologram.HologramCloud import HologramCloud
import logging
import base64
#uncomment if you want to see debugging messages.
#not suggested for larger images
#logging.basicConfig(level=logging.DEBUG, format="%(levelname)s: %(message)s")
hologram = HologramCloud(dict(), authentication_type='totp', network='cellular')
@benstr
benstr / seeed-v2-hologram-sketch.cpp
Created October 5, 2017 09:16
Sketch for using raw AT commands on a Seed Studio GPRS Shield with a Hologram.io SIM
/*
Note: this code is a demo for how to use a gprs shield to send
an http request to a test website (using the Hologram APN).
To communicate with the Arduino via terminal, set
the outgoing baud rate to 19200, and set line endings to
carriage return.
Then, in order to initiate the demo http request, enter
'h' into the terminal at the top of the serial monitor.
@benstr
benstr / package-symlink-instructions.md
Created November 3, 2014 22:09
How to modify an Atmosphere package with forking and symlink
@benstr
benstr / Tower_Jumping_Log.js
Last active December 12, 2018 11:55
Log showing controlled carrier jumping (AT&T-3G>>TMO-3G>>TMO-2G>>TMO-3G) with Hologram.io SIM
{
success: true,
limit: 100,
size: 5,
continues: false,
lastid: 430796983,
data: [
{
linkid: 387074,
record_id: 430817875,