Skip to content

Instantly share code, notes, and snippets.

View rbarilani's full-sized avatar

Ruben Barilani rbarilani

  • Zalando
  • Berlin
View GitHub Profile
' Zalando PlantUML Theme
' Constants –––––––––––––––––
' Base
!define ROUND_CORNER 3
!define THICKNESS 1
' Colors
!define COLOR_YELLOW_LIGHT #F7DB79
(function (exports) {
var traverse = function (obj) {
return new Traverse(obj);
};
exports.traverse = traverse;
function Traverse (obj) {
this.value = obj;
@rbarilani
rbarilani / cli.sh
Last active February 5, 2017 01:17
mc_config_refactor.yaml
mc start --mc:port 3000 --mc:mode dist --mc:html:title MyApp
@rbarilani
rbarilani / subsetSum.js
Created September 12, 2015 20:07
Finding all possible combinations of numbers to reach a given sum ()
function subsetSum(numbers, target, partial) {
var s, n, remaining;
partial = partial || [];
// sum partial
s = partial.reduce(function (a, b) {
return a + b;
}, 0);
@rbarilani
rbarilani / howto.md
Last active August 29, 2015 14:22 — forked from leomelzer/howto.md
  1. You have Ghostscript installed, right? Otherwise sudo apt-get install ghostscript
  2. This is important and installs the headers (iapi.h etc) which are required but don't come with the default Ghostscript package: sudo apt-get install libgs-dev
  3. I also needed sudo apt-get install gs-esp
  4. For me the pre compiled version of ImageMagick never accepted Ghostscript, so let's remove it: sudo apt-get --purge remove imagemagick
  5. Get the source of ImageMagick, untar it, cd ImageMagick-xx
  6. ./configure --with-gslib=yes [and what else you need]
  7. Confirm in the output near the bottom gslib yes yes and not gslib yes no
  8. make
  9. make install
  10. Run convert -list configure | grep DELEGATES => DELEGATES bzlib djvu freetype gs jpeg jng jp2 lcms png tiff x11 xml zlib
@rbarilani
rbarilani / elastic search examples
Last active August 29, 2015 14:20 — forked from davidemoro/gist:431aebd16c1ba143a90c
elastic search examples
DELETE test
PUT /test/
{
"data": {
"properties": {
"state": {
"type": "string",
"index": "not_analyzed"
}
}