This file contains hidden or 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 python | |
import sys | |
import os | |
import cgi | |
import cgimail | |
import random | |
import traceback | |
CTYPE_TEXT = "Content-Type: text/plain; charset=iso-8859-1" |
This file contains hidden or 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
import java.util.HashMap; | |
import java.util.Map; | |
import java.util.SortedMap; | |
import java.util.TreeMap; | |
import java.util.stream.Collectors; | |
public class IntelliJInferenceBug { | |
public static void main(String[] args) { | |
Map<String, Integer> map = new HashMap<>(); |
This file contains hidden or 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
import java.util.Arrays; | |
import java.util.List; | |
public class Yolo<T> { | |
private void printStringLengths(List<String> strings) { | |
strings.forEach(s -> System.out.println(s.length())); | |
} | |
public static void main(String[] args) { | |
List<Integer> numbers = Arrays.asList(5, 17, 23); |
This file contains hidden or 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
import java.util.Iterator; | |
public class Obliterator<E> implements Iterator<E> { | |
public static <E> Obliterator<E> of(Iterator<E> victim) { | |
return new Obliterator<E>(victim); | |
} | |
private final Iterator<E> victim; |
This file contains hidden or 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
import java.util.HashMap; | |
import java.util.Map; | |
public class DoesNotCompute { | |
public static void main(String[] args) { | |
System.out.println(System.getProperty("java.version")); | |
Map<String, Integer> map = new HashMap<>(); | |
map.computeIfAbsent("spud", s -> calculate(s, map)); |
This file contains hidden or 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
#! /bin/bash -eu | |
EXTERNAL_URL_HOST_NAME="$1" | |
ADMIN_USERNAME="$2" | |
ADMIN_PASSWORD="$3" | |
CONCOURSE_VERSION=${CONCOURSE_VERSION:-v1.1.0} | |
apt-get update | |
apt-get install -y postgresql postgresql-contrib |
This file contains hidden or 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
#! /bin/bash -eu | |
if [[ $# -gt 0 ]] | |
then | |
TIME=${1}H | |
else | |
END_OF_DAY=19 | |
NOW=$(($(date +%s) % 86400)) | |
EXPIRY=$((END_OF_DAY * 3600)) | |
TIME=$((EXPIRY - NOW))S |
This file contains hidden or 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
± |master ✗| → fly --atcURL=http://ci.initech.com:8080 configure | grep -A 32 'name: cm-service' | |
- name: cm-service | |
type: git | |
source: | |
branch: master | |
private_key: | | |
-----BEGIN RSA PRIVATE KEY----- | |
MIIEowIBAAKCAQEAvhb3ZvptWhyjMJ5+w25idzvykM9c9OGok1zQwTpItkJ5MWe+ | |
... snip crypto balls ... | |
Ulpm9T4G/DvQMtWCIaSPvI4+lAF5Vtl+nJZS3SrUyxt+BzEkQlQh |
This file contains hidden or 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
± |master ✗| → fly --atcURL=http://ci.initech.com:8080/ execute -c deploy.yml | |
2015/02/02 17:57:41 bad response when creating pipe: &{301 Moved Permanently 301 HTTP/1.1 1 1 map[Content-Length:[0] Content-Type:[text/plain; charset=utf-8] Location:[/api/v1/pipes] Date:[Mon, 02 Feb 2015 17:57:40 GMT]] 0xc208036e80 0 [] false map[] 0xc2080352b0 <nil>} | |
HTTP/1.1 301 Moved Permanently | |
Content-Length: 0 | |
Content-Type: text/plain; charset=utf-8 | |
Date: Mon, 02 Feb 2015 17:57:40 GMT | |
Location: /api/v1/pipes |
This file contains hidden or 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
diff --git a/commands/execute.go b/commands/execute.go | |
index d1a30ca..9d51506 100644 | |
--- a/commands/execute.go | |
+++ b/commands/execute.go | |
@@ -96,8 +96,8 @@ func Execute(c *cli.Context) { | |
signal.Notify(terminate, syscall.SIGINT, syscall.SIGTERM) | |
eventSource := &sse.EventSource{ | |
- Client: atcRequester.httpClient, | |
- CreateRequest: func() *http.Request { |