Skip to content

Instantly share code, notes, and snippets.

View lance's full-sized avatar
🎯
Focusing

Lance Ball lance

🎯
Focusing
View GitHub Profile
~/s/jvm-npm git:master ❯❯❯ git log
commit e05ce0d5a46594c323a63a7db971680ec32b7716
Author: Lance Ball <[email protected]>
Date: Mon May 2 09:13:47 2016 -0400
Revert "Merge pull request #25 from ChristophKaser/sourceURL"
This reverts commit 253984b36a2c1a6ed2f2adca52644d228f4ee36f, reversing
changes made to a0c3f12d2bbdbb6a339a4f84f586c6b1d1ce67c1.
'use strict';
// Expected output
// initial value
// Setting 'context.val' set directly
// set directly
// set directly
// Setting 'context.val' using this
// using this
'use strict';
// Flags: --expose-internals
const stream = require('stream');
const REPL = require('internal/repl');
const assert = require('assert');
testDefault();
testFalse();
package org.wildfly.swarm.config.datasources;
import org.wildfly.apigen.invocation.Address;
import org.wildfly.apigen.invocation.Binding;
import java.util.List;
import org.wildfly.apigen.invocation.Subresource;
import org.wildfly.swarm.config.datasources.ConnectionProperties;
/**
* A JDBC data-source configuration
*/
~/t/myproj ❯❯❯ pwd
/Users/lanceball/tmp/myproj
~/t/myproj ❯❯❯ ls
~/t/myproj ❯❯❯ npm install rhq-metrics
[email protected] node_modules/rhq-metrics
├── [email protected]
└── [email protected]
~/t/myproj ❯❯❯ ls
node_modules
~/t/myproj ❯❯❯ ls node_modules/*
I throw a exception in encode method of MessageToByteEncoder, why nothing happens?
will anybody help me?
thanks ahead
so slient
@lance
lance / my_face.md
Last active August 29, 2015 14:02
These are my words that I spoke at Mike Ball's memorial service. I read this poem, and spoke about family.

In addition to reading this poem, I was asked to speak a few words about family. Mike was my uncle.

This poem speaks to me of finding and accepting who you are, because of (or in spite of) the face, the name, the family you are given. It is about acceptance.

There is a famous quote by Leo Tolstoy. I think it is the opening line of Anna Karenina. I am paraphrasing: "Every happy family is exactly the same. But each unhappy family is unhappy in its own unique way." I like this quote. But I don't really think it's true. I think ALL families are unhappy in some way. But that doesn't make them bad, or wrong. It just makes them real. It gives shape and contour to the mask of the face you are given.

function mixin(obj, mix) {
for (var n in mix) {
// only mixin behavior, not data
var f = mix[n];
if (typeof f === 'function') {
obj[n] = f;
}
}
}
// When vertx file system functions mirror node file system
// functions, we can use this high-order function to
// delegate. It passes args unmolested into the vertx
// API, and provides a possibly converted return value
// (or callback arg). If the type/order of function
// arguments don't match up between vertx and node, then
// don't use this function.
function delegateFunction(f, converter) {
return function() {
if (!converter) { converter = function(result) { return result; }; }
function delegateFunction(f) {
return function() {
var args = Array.prototype.slice.call(arguments);
var last = args.pop();
if (typeof last === 'function') {
args.push(nodyn.vertxHandler(last));
} else if (last !== undefined) {
args.push(last);
}
f.apply(f, args);