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
################################################################################ | |
## OSX customisations | |
################################################################################ | |
# Map CAPS key to esc. - https://stackoverflow.com/a/40254864 | |
# Allow repeated keys | |
defaults write NSGlobalDomain ApplePressAndHoldEnabled -bool false | |
# Time until key repetition | |
defaults write -g InitialKeyRepeat -int 10 |
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
# upstart service file at /etc/init/meteorapp.conf | |
description "Meteor.js application" | |
author "Jose Constela <[email protected]>" | |
# When to start the service | |
start on started mongod and runlevel [2345] | |
# When to stop the service | |
stop on shutdown |
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
server_tokens off; # for security-by-obscurity: stop displaying nginx version | |
# this section is needed to proxy web-socket connections | |
map $http_upgrade $connection_upgrade { | |
default upgrade; | |
'' close; | |
} | |
server { |
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('./actions'); | |
describe( 'actions tests', () => { | |
it( 'dilbert', () => { | |
var actionResult = actions['dilbert'](); | |
assert.typeOf( actionResult, 'object' ); | |
assert.typeOf( actionResult.display, 'object' ); | |
assert.typeOf( actionResult.display.title, 'string' ); | |
assert.typeOf( actionResult.display.link, 'string' ); | |
assert.typeOf( actionResult.display.html, '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
language: node_js | |
node_js: | |
- '0.10' | |
sudo: required | |
before_install: | |
- curl https://install.meteor.com | /bin/sh | |
script: meteor test --once --driver-package dispatch:mocha-phantomjs |
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
/* | |
* 0.0.1 - 29.06.16 | |
* Experimental. | |
* | |
* Original code: https://github.com/parano/GeneticAlgorithm-TSP | |
*/ | |
Array.prototype.clone = function() { return this.slice(0); } | |
Array.prototype.shuffle = function() { | |
for(var j, x, i = this.length-1; i; j = randomNumber(i), x = this[--i], this[i] = this[j], this[j] = x); |
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
################################################################################ | |
# Prevent OSX calling home # | |
# # | |
# Mix of different /etc/hosts files found over internet, and calls filtered # | |
# using LittleSnitch for months. # | |
# # | |
# OSX sends a huge amount of requests to Cuppertino, even when you don't use # | |
# Spotlight suggestions, iCloud, updates and other services. Even if they are # | |
# disabled. # | |
# # |
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
"use strict" | |
let kafka = require('kafka-node'), | |
HighLevelProducer = kafka.HighLevelProducer, | |
client = new kafka.Client('localhost:2181/'), | |
producer = new HighLevelProducer(client) | |
// In this demo, topics are intended to be created already. | |
// See kafka docs (or check https://hub.docker.com/r/wurstmeister/kafka/ => | |
// "Automatically create topics") |
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
AT+RST | |
OK | |
WIFI DISCONNECT | |
ets J`n 8 2013,rst cause:2, boot mode:(3,6) | |
load 0x40100000,,tail 0 | |
chkstm 0x63 |
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
// XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX | |
// COMPOSITION | |
// XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX | |
composition: { | |
type: Object, | |
label: 'Composición (cada 100gr)', | |
optional: true | |
}, |