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 ( | |
"errors" | |
"log" | |
) | |
// rollback function | |
func rollback(rollbackCtrl *bool, rollbackFunc func()) { | |
if *rollbackCtrl { |
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
#![allow(dead_code)] | |
use std::collections::{HashMap, HashSet}; | |
use std::mem; | |
fn main() { | |
println!("Hello, world!"); | |
// test_vars(); | |
// test_operators(); | |
// test_constants(); |
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 perl | |
# | |
# Usage: ssh-deploy-key -h (--hostsfile) PATH_TO_HOSTS_FILE | |
# -p (--pubkeyfile) PATH_TO_PUBKEY_FILE | |
# [ -u (--user) USER ] | |
# | |
# Expects --hostsfile to contain 1 host per line | |
# Assumes current user if --user is not given | |
# |
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
<HEADER> | |
<TITLE>The World Wide Web project</TITLE> | |
<NEXTID N="55"> | |
</HEADER> | |
<BODY> | |
<H1>World Wide Web</H1>The WorldWideWeb (W3) is a wide-area<A | |
NAME=0 HREF="WhatIs.html"> | |
hypermedia</A> information retrieval | |
initiative aiming to give universal | |
access to a large universe of documents.<P> |
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
{ nodes: 42444, | |
time: Mon Jul 06 2015 16:36:48 GMT+0100 (WEST), | |
size_bytes: 7244456, | |
size: '6.91 mb' } | |
{ nodes: 45852, | |
time: Mon Jul 06 2015 16:36:48 GMT+0100 (WEST), | |
size_bytes: 7755120, | |
size: '7.4 mb' } | |
{ num_full_gc: 145, | |
num_inc_gc: 105, |
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
reporting-disabled = true | |
[admin] | |
bind-address = ":8083" | |
enabled = true | |
[cluster] | |
shard-writer-timeout = "5s" | |
[continuous_queries] |
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 node | |
var fs = require('fs'); | |
fs.readFile('urandomStrings', 'utf8', function (err,data) { | |
if (err) { | |
return console.log(err); | |
} else { | |
console.time('concat'); | |
var string = ''; |
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 bash | |
DST_IP=XXX.XXX.XXX.XXX | |
SRC_IP=$(/sbin/ip -f inet addr | grep inet | grep -v 127.0.0.1 | awk -F ' ' '{print $2}' | awk -F '/' '{print $1}') | |
PACKET_LOSS=$(/bin/ping -w 4 -q $DST_IP | tail -2 | awk -F ' ' '{print $6}' | awk -F '%' '{print $1}' | grep -v '^$') | |
SANITIZED_DST_IP="${DST_IP//./_}" | |
SANITIZED_SRC_IP="${SRC_IP//./_}" | |
METRIC_PREFIX="" |
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
require 'chef/provisioning' | |
with_driver 'aws' | |
with_machine_options :bootstrap_options => { | |
:security_group_ids => ["#{ENV['AWS_SECURITY_GROUP']}"], | |
:key_name => "#{ENV['AWS_KEY_NAME']}", | |
:image_id => "#{ENV['AWS_IMAGE_ID']}" | |
}, | |
:ssh_username => "#{ENV['AWS_SSH_USERNAME']}" |
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 bash | |
###### | |
# CPU | |
###### | |
if [ $# -lt 2 ] | |
then | |
echo "Missing arguments" | |
echo "Usage:" |
NewerOlder