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
#!/bin/bash | |
set -euo pipefail | |
# Tail kubectl logs from multiple selected pods with colorized output. | |
function usage() { | |
local name="$(basename "${BASH_SOURCE[0]}")" | |
echo "Synopsis:" | |
echo -e "\t$name -n NAMESPACE -l SELECTOR [ -- KUBECTL_LOGS_ARGS ]\n" |
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
package main | |
import ( | |
"fmt" | |
"reflect" | |
) | |
// concat returns a slice of type t that contains the specified items. | |
// Each item is appended according to its type: if it has type t, it is | |
// appended; if it is a slice of values of type t, each of its elements |
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
# == Library code =========================================== | |
class Result | |
def self.success(value) | |
new(nil, value) | |
end | |
def self.error(err) | |
new(err, nil) | |
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
[{"loan":{"id":1,"borrower_id":1,"amount":10984659,"term":120},"period":{"start_at":"2017-05-22T00:00:00-06:00","end_at":"2017-06-21T23:59:59-06:00"},"principal":57702,"interest":83752,"rate_annual":900,"service_fee":{"amount":0,"rate":0}},{"loan":{"id":1,"borrower_id":1,"amount":10984659,"term":120},"period":{"start_at":"2017-06-22T00:00:00-06:00","end_at":"2017-07-21T23:59:59-06:00"},"principal":56262,"interest":80629,"rate_annual":900,"service_fee":{"amount":0,"rate":0}},{"loan":{"id":1,"borrower_id":1,"amount":10984659,"term":120},"period":{"start_at":"2017-07-22T00:00:00-06:00","end_at":"2017-08-21T23:59:59-06:00"},"principal":58577,"interest":82877,"rate_annual":900,"service_fee":{"amount":0,"rate":0}},{"loan":{"id":1,"borrower_id":1,"amount":10984659,"term":120},"period":{"start_at":"2017-08-22T00:00:00-06:00","end_at":"2017-09-21T23:59:59-06:00"},"principal":59026,"interest":82428,"rate_annual":900,"service_fee":{"amount":0,"rate":0}},{"loan":{"id":1,"borrower_id":1,"amount":10984659,"term":120},"peri |
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
/** | |
* Object.extend() | |
* @author Bryan Dragon | |
* @website www.bryandragon.com | |
* @license MIT License | |
*/ | |
(function () { | |
'use strict'; | |
var hasOwn = Object.prototype.hasOwnProperty |
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
/** | |
* mobile-viewport.js | |
* | |
* Simple script to hide the address bar on iPhone and iPod (when not in fullscreen app mode). | |
*/ | |
(function () { | |
var ADDR_BAR_HEIGHT = 60, | |
app = document.getElementById('myDomEl'), | |
ua = navigator.userAgent, | |
iphone = ~ua.indexOf('iPhone') || ~ua.indexOf('iPod'), |