Skip to content

Instantly share code, notes, and snippets.

View quinncnl's full-sized avatar

Quinn quinncnl

  • Eindhoven
  • 08:28 (UTC +01:00)
View GitHub Profile
#!/usr/bin/env python3
import requests
r = requests.get('https://api.darksky.net/forecast/9ba42d2d7e496f2fb181e33940faec61/51.419551,5.446345?units=auto')
cur = r.json()['currently']
tmp = cur['temperature']
wind = float(cur['windSpeed'])
print("OUTSIDE TEMP", tmp, "°C WIND", wind, "KMH")
analytics.google.com
google-analytics.com
googlesyndication.com
adservice.google.nl
adservice.google.com
googletagmanager.com
mmstat.com
addthis.com
ads.linkedin.com
doubleclick.net
25 OCT: no connection at my home
#!/usr/bin/env python3
import matplotlib
import numpy as np
import matplotlib.pyplot as plt
from matplotlib.colors import ListedColormap
from sklearn import tree
from sklearn.tree import DecisionTreeRegressor
(when (>= emacs-major-version 24)
(require 'package)
(add-to-list
'package-archives
'("melpa" . "http://melpa.org/packages/")
t)
(package-initialize))
(require 'org)
@quinncnl
quinncnl / tmux.cheat
Created May 22, 2017 13:00 — forked from afair/tmux.cheat
Tmux Quick Reference & Cheat sheet - 2 column format for less scrolling!
========================================== ==========================================
TMUX COMMAND WINDOW (TAB)
========================================== ==========================================
List tmux ls List ^b w
New -s <session> Create ^b c
Attach att -t <session> Rename ^b , <name>
Rename rename-session -t <old> <new> Last ^b l (lower-L)
Kill kill-session -t <session> Close ^b &
@quinncnl
quinncnl / XmasBreak.md
Last active December 16, 2016 12:46
Gran Canaria & Barcelona 8 Days Holiday

Wed, 21: Maspalomas

  • Arrive at airport: 10:35
  • 50 mins from airport to Maspalomas
  • Rest in Maspalomas beaches

Thu, 22: Hiking Day

  • from Maspalomas to Roque Nublo, Map
  • Morning: Half day round trip Tripadvisor
@quinncnl
quinncnl / Christmas-Trip.md
Last active November 21, 2016 20:41
trip to Copenhagen and Stockholm

Option 1 (6 days northern):

Eindhoven to Copenhagen:

  • Dates: 23 - 26
  • Flights: €40

Copenhagen to Stockholm:

  • Dates: 26 - 29
  • Flights: €60
@quinncnl
quinncnl / MapKit-autonavi.swift
Last active September 22, 2016 04:41
Test if MapKit is using Apple data or AutoNavi data
let geocoder = CLGeocoder()
let appleHQCoord = CLLocation(latitude: 37.331998, longitude: -122.029645)
geocoder.reverseGeocodeLocation(appleHQCoord) { (placemarks, error) in
if (error?.code == 2) {
// using autonavi
}
else {
// using apple map
}
@quinncnl
quinncnl / lldb_cheat_sheet.md
Created August 24, 2016 02:48 — forked from ryanchang/lldb_cheat_sheet.md
LLDB Cheat Sheet

LLDB Cheat Sheet

A complete gdb to lldb command map.

Print out

  • Print object
(lldb) po responseObject
(lldb) po [responseObject objectForKey@"state"]
  • p - Print primitive type