Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@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 / mongodb-sync.js
Created December 8, 2014 10:19
mongodb-sync.js
/**
* Usage: $ node mongodb-sync.js <user>@<ip> <database-name>
**/
require("shelljs/global")
// prepare remote db
var remote_commands = [
"mongodump --db "+process.argv[3]+" --out /tmp/mongodump-sync",
"tar -zcvf /tmp/mongodump-sync.tar.gz /tmp/mongodump-sync"
]
@outbounder
outbounder / cell.json
Created June 30, 2014 12:00
angelscripts cellcmds cell.json
{
"remote": "user@11.222.333.444",
"cwd": "~/app",
"source": "git@app.git",
"origin": "origin",
"branch": "develop",
"nvmPath": "~/.nvm/nvm.sh",
"nodeVersion": "v0.10.24",
"start": "forever --sourceDir /home/app -a -l /home/app/app.js.out --minUptime 5000 --spinSleepTime 2000 start app.js",
"stop": "forever stop app.js",
@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) {