Skip to content

Instantly share code, notes, and snippets.

Lorenzo Sicilia aboutlo

Block or report user

Report or block aboutlo

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@aboutlo
aboutlo / asyncPipe.js
Last active Jan 24, 2018
A simple asyncPipe utility without any dependency to handle functions or promises
View asyncPipe.js
// Quick asyncPipe utility without any dependency
const asyncPipe = (f1, ...fns) => {
const toPromise = (fn, ...args) =>
new Promise((resolve, reject) => {
try {
return resolve(fn(...args));
} catch (e) {
return reject(e);
}
@aboutlo
aboutlo / trace
Created May 6, 2016
simple-example dokku deploy
View trace
root@dokku:~# dokku tags:deploy simple-example
+ case "$(lsb_release -si)" in
++ lsb_release -si
+ export DOKKU_DISTRO=ubuntu
+ DOKKU_DISTRO=ubuntu
+ export DOKKU_IMAGE=gliderlabs/herokuish
+ DOKKU_IMAGE=gliderlabs/herokuish
+ export DOKKU_LIB_ROOT=/var/lib/dokku
+ DOKKU_LIB_ROOT=/var/lib/dokku
+ export PLUGIN_PATH=/var/lib/dokku/plugins
View node-example deploy image
root@dokku:~# dokku tags:deploy node-example latest
+ case "$(lsb_release -si)" in
++ lsb_release -si
+ export DOKKU_DISTRO=ubuntu
+ DOKKU_DISTRO=ubuntu
+ export DOKKU_IMAGE=gliderlabs/herokuish
+ DOKKU_IMAGE=gliderlabs/herokuish
+ export DOKKU_LIB_ROOT=/var/lib/dokku
+ DOKKU_LIB_ROOT=/var/lib/dokku
+ export PLUGIN_PATH=/var/lib/dokku/plugins
View gist:b436a04a90453d6a50e2
Verifying that +aboutlo is my blockchain ID. https://onename.com/aboutlo
@aboutlo
aboutlo / example.js
Created Aug 28, 2015
es6-promise not resolved when I mix my promises with fetch promises
View example.js
function fetchSomething(){
console.log('fetchSomething')
return fetch('https://www.google.com', {
method: 'GET'
})
}
function doSomething(value){
console.log('doSomething');
//return true;
@aboutlo
aboutlo / Foo.js
Last active Aug 29, 2015
es6 example
View Foo.js
'use strict';
import _ from 'underscore'; // _ is white
import { EventEmitter } from 'events'; // EventeEmitter is white
import logger from 'loglevel'; // logger is white
let emitter = new EventEmitter();
var Foo = function () {
@aboutlo
aboutlo / MainView.js
Created Mar 8, 2015
Simple Test with Backbone using VirtualDom, Underscore Template and ConvertHTML
View MainView.js
'use strict';
var $ = require('jquery');
var _ = require('underscore');
var Backbone = require('backbone');
Backbone.$ = $;
var h = require('virtual-dom/h');
var diff = require('virtual-dom/diff');
var patch = require('virtual-dom/patch');
You can’t perform that action at this time.