Skip to content

Instantly share code, notes, and snippets.

jameskyle / s3client.scala
Last active June 8, 2023 22:48
Dynamic bucket lookup and cross region copy object support.
import scala.util.{Try,Success,Failure}
Cross region copy object example with region code discovery for a bucket.
jameskyle / gitconfig
Created March 10, 2022 21:51
Aliasess and short cuts for git.
name = <name>
email = <email>
username = <username>
branch = auto
diff = auto
status = auto
[color "branch"]
@JsonIgnoreProperties(ignoreUnknown = true)
public class JsonExample {
boolean broken;
Boolean working;
#include <iostream>
using namespace std;
void overloaded(int a) {
cout << "This is an int: " << a << endl;
void overloaded(double a) {
cout << "This is a double: " << a << endl;
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
file { '/etc/uber/redis_ports.d':
# see also celery_port_queues.d
ensure => 'directory',
owner => 'root',
group => 'root',
mode => '0444',
source => 'puppet:///modules/redis/empty/',
recurse => true,
ignore => '.empty',
purge => true,
from __future__ import division
import matplotlib
import time
import sys
import math
import glob
import os
import cv2
from __future__ import print_function, division
import datetime as dt
import pandas as pd
import numpy as np
import scipy.optimize as sopt
def gradebook():
columns = ("Assignment", "Due", "Grade", "Weight")
import requests
import time
import gevent
from gevent.queue import JoinableQueue
class Consumer(object):
def __init__(self):
self.queue = JoinableQueue()
self.producers = [Producer(self.queue) for _ in range(10)]
import numpy as np
a = np.ones(shape=(1e9,), dtype=int)