This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- show running queries (9.2) | |
SELECT pid, age(clock_timestamp(), query_start), usename, query | |
FROM pg_stat_activity | |
WHERE query != '<IDLE>' AND query NOT ILIKE '%pg_stat_activity%' | |
ORDER BY query_start desc; | |
-- REINDEX Status | |
SELECT | |
now()::TIME(0), | |
a.query, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const moment = require('moment'); | |
const turf = require('@turf/turf'); | |
const UUID = require("pure-uuid"); | |
const K_ANON_VAL = 4; | |
const FUZZED_TIME_BUCKET = 15; | |
const FUZZED_LOCATION_PRECISION = 3; | |
const RANDOM_LATITUDE_RADIUS = 0.004; | |
const RANDOM_LONGITUDE_RADIUS = 0.005; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
osascript -e 'tell application "iTunes" to activate' -e 'tell application "System Events"' -e 'tell application process "iTunes"' -e 'click menu item "Update iTunes Match" of menu 1 of menu bar item "Store" of menu bar 1' -e 'end tell' -e 'end tell' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$(document).scroll(function() { | |
$(".sticky").offset(function() { | |
var documentHeight = $(document).height(); | |
console.log(documentHeight); | |
$this = $(this); | |
var scrollTop = $(window).scrollTop(); | |
var offsetTop = $this.data("offset-top"); | |
if (scrollTop < 0) { | |
scrollTop = 0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Generated by CoffeeScript 1.3.3 | |
$(document).ready(function() { | |
$(".playlist").addClass("closed hidden transition transition-height"); | |
return $(".cover-picker").on("click", "a", function(event) { | |
var albumSelected, canvas, coverActive, coverAnchor, coverSelected, image, indicatorPosition, playlistHeight, switchPlaylistToAlbum, togglePlaylistForAlbum, | |
_this = this; | |
coverAnchor = this; | |
coverSelected = coverAnchor.parentNode; | |
coverActive = $(".cover-picker .active"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*! | |
* quantize.js Copyright 2008 Nick Rabinowitz. | |
* Licensed under the MIT license: http://www.opensource.org/licenses/mit-license.php | |
*/ | |
// fill out a couple protovis dependencies | |
/*! | |
* Block below copied from Protovis: http://mbostock.github.com/protovis/ | |
* Copyright 2010 Stanford Visualization Group | |
* Licensed under the BSD License: http://www.opensource.org/licenses/bsd-license.php |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def test_past_recording_is_associated_with_stream | |
stream = Stream.create(...) | |
recording = PastRecording.from_stream(stream) | |
assert_equal recording.stream, stream | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Heartbeat */ | |
/* | |
>> Pulse Sensor Amped 1.1 << | |
This code is for Pulse Sensor Amped by Joel Murphy and Yury Gitman | |
www.pulsesensor.com | |
>>> Pulse Sensor purple wire goes to Analog Pin 0 <<< | |
Pulse Sensor sample aquisition and processing happens in the background via Timer 2 interrupt. 2mS sample rate. | |
PWM on pins 3 and 11 will not work when using this code, because we are using Timer 2! | |
The following variables are automatically updated: | |
Signal : int that holds the analog signal data straight from the sensor. updated every 2mS. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function() { | |
var Drop = window.Drop = function() { | |
var files = []; | |
var add = function(word) { | |
files.push(word); | |
return files; | |
} | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/bin/env ruby | |
folder = '/Users/bmckim/Desktop/pushConfigFiles' | |
applications = Dir.glob(folder + '/*') | |
applications.each do |app| | |
application_name = app.split('/').last | |
new_config = app + '/PushPublishMap.txt' | |
new_config_lines = [] |
NewerOlder