Skip to content

Instantly share code, notes, and snippets.

View bebo-dot-dev's full-sized avatar

Joe bebo-dot-dev

View GitHub Profile
@bebo-dot-dev
bebo-dot-dev / node-RED.darksky.inlined.weather.flow.json
Created February 12, 2017 16:13
A node-RED flow that uses the Dark Sky API - inlines the skycons JS script to prevent jquery cache busting behaviour
[
{
"id": "c1f1fc46.4bb3b",
"type": "tab",
"label": "Weather"
},
{
"id": "76c2790c.78f858",
"type": "inject",
"z": "c1f1fc46.4bb3b",
@bebo-dot-dev
bebo-dot-dev / node-RED.NEW_STYLE.darksky.weather.flow.json
Last active January 20, 2019 19:49
A node-RED flow that uses the Dark Sky API - injects the skycons script tag element to prevent jquery cache busting behaviour
[
{
"id": "c1f1fc46.4bb3b",
"type": "tab",
"label": "Weather"
},
{
"id": "76c2790c.78f858",
"type": "inject",
"z": "c1f1fc46.4bb3b",
@bebo-dot-dev
bebo-dot-dev / node-RED.darksky.weather.flow.json
Created February 9, 2017 18:53
A node-RED flow that uses the Dark Sky API based on notes in this post: http://tech.scargill.net/node-red-weather/
[
{
"id": "a39dbd83.b5365",
"type": "tab",
"label": "Weather"
},
{
"id": "2c44271c.a08d58",
"type": "inject",
"z": "a39dbd83.b5365",
import java.util.regex.Matcher;
import java.util.regex.Pattern;
public class JavaRegexTest {
public static void main(String []args)
{
String textToSearch = "-DARDUINO_BOARD=\"ESP8266_ESP01\" -DDEFINE_NO_2=\"ESP8266_ESP01\" -DALREADY_ESCAPED=\\\"VALUE\\\" -DDEFINE_WITH_WHITESPACE=\"ESP8266 ESP01\"";
Pattern regex = Pattern.compile("-D\\S+=\"\\S+\""); //value contains any char but whitespace