Skip to content

Instantly share code, notes, and snippets.

@outbounder
outbounder / ClientHelper.java
Created July 7, 2011 13:08
jersey client helper for trusting all certificates in SSL/TLS
import java.security.SecureRandom;
import java.security.cert.CertificateException;
import java.security.cert.X509Certificate;
import javax.net.ssl.HostnameVerifier;
import javax.net.ssl.HttpsURLConnection;
import javax.net.ssl.SSLContext;
import javax.net.ssl.SSLSession;
import javax.net.ssl.TrustManager;
import javax.net.ssl.X509TrustManager;
@outbounder
outbounder / organic-and-lean-software-development.md
Last active October 4, 2018 16:37
outlines rapid agile lean software development aimed to be optimized for change

Software development

In a nutshell it is just the following:

  1. got a task/requirements/problem which can be solved with a computer
  2. implement a solution
  3. see that solution actually works (most of the time)
  4. see that solution fails in some cases
  5. iterate from 2) to 5) until the original task/requirement/problem is resolved to its full extend
@outbounder
outbounder / gist:8289977
Created January 6, 2014 21:17
node-thequest dependencies dated 06.01.2014
application-name@0.0.16 /home/outbounder/projects/outbounder/node-thequest
├─┬ browserify@1.16.1
│ ├─┬ buffer-browserify@0.0.3
│ │ └── base64-js@0.0.2
│ ├── coffee-script@1.3.3
│ ├── commondir@0.0.1
│ ├── crypto-browserify@0.1.1
│ ├─┬ deputy@0.0.4
│ │ └── mkdirp@0.3.4
│ ├─┬ detective@0.2.1
@outbounder
outbounder / gist:7759049
Last active December 30, 2015 01:49
fetch email without attachment via imap
var bodies
var attributes_fetch = imap.fetch(emailId, {
struct: true
});
attributes_fetch.on('message', function(msg, seqno) {
msg.once('attributes', function(attrs) {
// just extracts ["HEADER", "1", "1.MIME"] from a message
// which has "HEADER" and "1", "2" parts, where "2" is attachment
bodies = constructBodies(attrs)
@outbounder
outbounder / bindTo.js
Created December 5, 2012 14:24
Backbone bindTo enchanced
// Generated by CoffeeScript 1.3.1
/*
Backbone.BindTo
Author: Radoslav Stankov
Project site: https://github.com/RStankov/backbone-bind-to
Licensed under the MIT License.
*/
@outbounder
outbounder / installNodejs.sh
Created July 18, 2012 15:57
install node.js on ubuntu
#!/bin/bash
NODE=$1
NVMDIR=$2
NVM=$NVMDIR/nvm.sh
echo "installing node.js $1"
hash nvm 2>&- || {
echo "couldn't find nvm, checking for $NVM"
test -e $NVM || {
var allCount = items.length;
var handleSave = function(err) {
if(err) {
allCount = 0; // this will prevent sending success: true if invoked again...
res.send({ success: false, msg: err}, 400);
return;
}
allCount -= 1;
if(allCount == 0) {
@outbounder
outbounder / install.sh
Created September 14, 2011 10:30
auto-install nvm, node.js
#!/bin/bash
NODE="v0.4.11"
NVMDIR=~/.nvm
NVM=~/.nvm/nvm.sh
echo "installing projectman-repl"
hash nvm 2>&- || {
echo "couldn't find nvm, sourcing from $NVM"
test -e $NVM || {
echo "couldn't find $NVM -> installing..."