Skip to content

Instantly share code, notes, and snippets.

View Arie's full-sized avatar

Arie Arie

View GitHub Profile
@Arie
Arie / gist:25b260cc02d04a67d282
Last active October 22, 2020 21:37
Installing flent on OS/X with homebrew
`pip install flent matplotlib`
`brew install fping`
Netperf in homebrew is installed without demo mode by default, so we need to edit the recipe slightly, also demo mode fails to build under OS/X, requiring a tiny patch to netlib.c ( http://www.netperf.org/pipermail/netperf-talk/2013-December/001162.html ). The following recipe changes the URL to a prepatched version that I host and changes the configure line to enable demo mode.
`brew edit netperf`
```
class Netperf < Formula
desc "Benchmarks performance of many different types of networking"

Let's go Postal!

And start using a real database

"mysql is a network-attached spreadsheet used by porn sites and other dodgy entities across the Internet." -- http://elnur.pro/avoid-mysql/

@Arie
Arie / tidy_bytes_monkey_patch.rb
Last active December 16, 2015 12:58
active support tidy_byte monkey patch
#Given this input string, tidy_bytes explodes
#L 04/22/2013 - 19:56:11: "★radist★<14><STEAM_0:0:21110245><Red>" say_team "[P-REC] Çàïèñü ïîù¸ëú"
#This horrible monkey patch fixes it:
module ActiveSupport
module Multibyte
module Unicode
def tidy_byte(byte)
if byte.is_a? Integer