Skip to content

Instantly share code, notes, and snippets.

@noomerikal
noomerikal / gist:2f7f9d13c5449849d0eb7f447175ee65
Created April 1, 2018 17:30
react-typeform-embed issue w/ gatsby
➜ yarn add react-typeform-embed
yarn add v1.5.1
[1/4] 🔍 Resolving packages...
[2/4] 🚚 Fetching packages...
[3/4] 🔗 Linking dependencies...
warning "gatsby > [email protected]" has unmet peer dependency "caniuse-db@^1.0.30000652".
warning " > [email protected]" has unmet peer dependency "babel-plugin-styled-components@>1.5.0".
warning "gatsby-plugin-typography > [email protected]" has unmet peer dependency "react@^0.14.0 || ^15.0.0 || ^16.0.0".
warning " > [email protected]" has unmet peer dependency "react@>=15.0.0".
warning "react-helmet > [email protected]" has unmet peer dependency "react@^0.13.0 || ^0.14.0 || ^15.0.0 || ^16.0.0".
Package failed to execute.
======== job_201608140909_0002 attempt_201608140909_0002_m_000000_0 stderr.summary ========
16/08/16 21:30:58 WARN tool.EvalSqlTool: SQL exception executing statement: org.postgresql.util.PSQLException: ERROR: Load into table 'fb_influencer_engagement_raw' failed. Check 'stl_load_errors' system table for details.
at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2270)
at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1998)
at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:255)
@noomerikal
noomerikal / gist:303cd59795ab992ba83a
Created January 16, 2016 10:08
divolte + mesosphere log
--container="mesos-3b7c8433-8718-49e5-a030-87cb29d51be3-S5.1274f78c-2c5f-4d27-92d6-bd568d386334" --docker="docker" --docker_socket="/var/run/docker.sock" --help="false" --initialize_driver_logging="true" --logbufsecs="0" --logging_level="INFO" --mapped_directory="/mnt/mesos/sandbox" --quiet="false" --sandbox_directory="/var/lib/mesos/slave/slaves/3b7c8433-8718-49e5-a030-87cb29d51be3-S5/frameworks/3b7c8433-8718-49e5-a030-87cb29d51be3-0000/executors/divolte.c3d80cb2-bc36-11e5-9846-12f99e861f93/runs/1274f78c-2c5f-4d27-92d6-bd568d386334" --stop_timeout="0ns"
--container="mesos-3b7c8433-8718-49e5-a030-87cb29d51be3-S5.1274f78c-2c5f-4d27-92d6-bd568d386334" --docker="docker" --docker_socket="/var/run/docker.sock" --help="false" --initialize_driver_logging="true" --logbufsecs="0" --logging_level="INFO" --mapped_directory="/mnt/mesos/sandbox" --quiet="false" --sandbox_directory="/var/lib/mesos/slave/slaves/3b7c8433-8718-49e5-a030-87cb29d51be3-S5/frameworks/3b7c8433-8718-49e5-a030-87cb29d51be3-0000/executors/divolte.c3d
@noomerikal
noomerikal / Statistics.js
Created November 28, 2015 11:31
Loading Segment.io analytics.js open source version async
// Create a dummy analytics object until real loaded
window.analytics || (window.analytics = []);
window.analytics.methods = ['identify', 'track', 'trackLink', 'trackForm', 'trackClick', 'trackSubmit', 'page', 'pageview', 'ab', 'alias', 'ready', 'group', 'on', 'once', 'off'];
window.analytics.factory = function(method) {
return function() {
var args = Array.prototype.slice.call(arguments);
args.unshift(method);
window.analytics.push(args);
return window.analytics;
};
# Puma upstream
upstream puma {
# fail_timeout=0 means we always retry an upstream even if it failed
# to return a good HTTP response (in case the Unicorn master nukes a
# single worker for timing out).
# for UNIX domain socket setups:
server unix:/mnt/project/api/shared/tmp/sockets/puma.sock fail_timeout=0;
}
<html>
<head>
<title>Checkbox</title>
<style>
input[type=checkbox] {
display:none;
}
input[type=checkbox] + label
{
require "spec_helper"
describe ExampleController do
context "GET #index" do
let(:resources) { FactoryGirl.create_list(:resource) }
before do
get :index
end

OS X Screencast to animated GIF

This gist shows how to create a GIF screencast using only free OS X tools: QuickTime, ffmpeg, and gifsicle.

Screencapture GIF

Instructions

To capture the video (filesize: 19MB), using the free "QuickTime Player" application:

@noomerikal
noomerikal / S3.java
Last active August 29, 2015 14:15 — forked from abh1nav/S3.java
package com.twitsprout.sproutscore.bolts;
import java.util.HashMap;
import java.util.Map;
import com.google.common.collect.Maps;
import backtype.storm.task.OutputCollector;
import backtype.storm.task.TopologyContext;
import backtype.storm.topology.IRichBolt;
<?xml version="1.0"?>
<response>
<sports>
<sportsItem>
<name>basketball</name>
<id>40</id>
<type>points</type>
<leagues>
<leaguesItem>
<name>National Basketball Assoc.</name>