Skip to content

Instantly share code, notes, and snippets.

View rbenaley's full-sized avatar

Richard Ben Aleya rbenaley

  • Scalable Solutions
  • Belgium
View GitHub Profile
@ToddG
ToddG / rebar-reltool-relase-notes.md
Created September 15, 2012 16:46
using rebar to create an erlang app with a dependency, and then starting a release created with reltool

Summary

I'm trying to figure out how to use rebar to:

  • create erlang project
  • add a dependency on an erlang module from github
  • start the app via the erl console
  • create a release and start the app from the release (via the generated scripts)
@STrRedWolf
STrRedWolf / Stream_wolftv.sh
Created May 6, 2013 03:10
This is how to stream live video and transmux it to HTTP Live Streaming. Requires ffmpeg 1.2 or greater (no forked libav crap, it must be genuine original ffmpeg. Compile it yourself on Debian & Ubuntu!)
#!/bin/bash
rtmpdump -r 'rtmp://wolf.tv.macrophile.com/oflaDemo/wolftv' -v -q | \
ffmpeg -i pipe: -bsf h264_mp4toannexb -codec copy -map 0 -f ssegment \
-segment_list test.m3u8 -segment_time 4 -segment_wrap 24 \
-segment_format mpegts -segment_list_type hls stream%05d.ts
@essen
essen / http_specs.md
Last active January 10, 2022 02:01
HTTP and related specifications
@leikind
leikind / expand.ex
Last active August 29, 2015 14:18
Macro.expand and Macro.expand_once
defmodule UselessMacros do
defmacro bar(42) do
quote do
"the answer"
end
end
defmacro baz(42) do
quote do
@BinaryMuse
BinaryMuse / README.md
Last active April 20, 2022 21:45
Elixir Map/HashDict Performance on Erlang OTP R17 vs R18
@tjanczuk
tjanczuk / xpub-xsub.js
Created August 24, 2015 23:59
How to connect 5 publishers with 5 subscribers over TCP using ZeroMQ's XPUB/XSUB proxy
// How to connect 5 publishers with 5 subscribers
// over TCP using ZeroMQ's XPUB/XSUB proxy.
// sub (connect)
// <-8701->
// (bind) xpub <---> xsub (bind)
// <-8700->
// (connect) pub
var zmq = require('zmq');

Elm 0.15.1 vs 0.16 on Chrome

Result of running these benchmarks on Chrome 45.0.2454.101

These numbers seem to be pretty consistent on Blink-based browsers (Chrome and Opera) but are more like 20% to 50% improvements on FireFox, Safari, and IE. I am not sure how to explain that, so take these numbers more as an indicator of “Elm is generating faster code across the board” as opposed to “Elm is 10x faster!”

business logic from examples

@agnaldo4j
agnaldo4j / crawler_example.md
Last active October 15, 2016 11:20
Crawler example with mochiweb_html and mochiweb_xpath.

Elixir simple crawler example

This example uses thease projects:

  1. mochiweb
  2. mochiweb_xpath

The HtmlPageReader goes to html's page and transform that content with mochiweb_html.parse

defmodule Usecase.HtmlPageReader do
@oskar456
oskar456 / md4pass.sh
Created October 7, 2016 09:48
MSCHAPv2 hash generator one-liner
python -c 'import getpass,hashlib; print(hashlib.new("md4",getpass.getpass().encode("utf-16le")).hexdigest())'