Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@nMustaki
nMustaki / gist:507c336013bf15a9f289
Created July 21, 2015 21:12
Use of Fabric as library (for fab-user mailing list)
# With many thanks to pmuller for its streamlogger class : # https://gist.githubusercontent.com/pmuller/2376336/raw/cc455144c66b058d8de56c5d6c0a87dbd7c301d5/streamlogger.py
class FabricException(Exception):
pass
def fabric_task(host, command, **kwargs):
"""
Args:
host (string): eg : server-id
@nMustaki
nMustaki / keybase.md
Last active August 29, 2015 14:08
keybase.md

Keybase proof

I hereby claim:

  • I am nmustaki on github.
  • I am feydaykyn (https://keybase.io/feydaykyn) on keybase.
  • I have a public key whose fingerprint is 1906 6EC2 15E6 DE38 A32E B0E4 E564 A2C7 DF07 AC8F

To claim this, I am signing this object:

@nMustaki
nMustaki / Working PKGBUILD for log4c 1.2.2
Created December 3, 2012 11:33
Working PKGBUILD for log4c 1.2.2
# Contributor: rockerzz <rockerzz@gmail.com>
#
pkgname=log4c
pkgver=1.2.2
pkgrel=1
pkgdesc="Logging FrameWork for C, as Log4j or Log4Cpp"
url="http://log4c.sourceforge.net/"
arch=('i686' 'x86_64')
license="LGPL"
depends=('gcc-libs')
{
"name": "serbanghita/mobile-detect",
"description": "Lightweight PHP class for detecting mobile devices",
"keywords": ["mobile", "mobile detect", "mobile detector", "mobile device"],
"homepage": "https://github.com/serbanghita/Mobile-Detect",
"type": "library",
"license": "MIT",
"authors": [
{
"name": "Serban Ghita",
<!DOCTYPE html>
<html lang="fr">
<head>
<meta charset="utf-8"/>
<title>Hisdesat</title>
<style type="text/css">.pagebreak {page-break-after: always}</style>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
</head>
<body>
<div class="pagebreak">
@nMustaki
nMustaki / gist:2917728
Created June 12, 2012 14:04
quick multiple replace in string
#include <string>
#include <iostream>
#include <algorithm>
#include <list>
std::string& bulk_replace(std::string& s, std::string &src, char dest)
{
std::string::iterator it;
for (it = src.begin(); it != src.end(); ++it)
@nMustaki
nMustaki / rvm-iconv-freebsd8.2
Created February 15, 2012 15:21
Install rvm and iconv on Freebsd 8.2
here is the complete list of what I needed to do in Freebsd 8.2
1 pkg_add -r ruby
2 cd /usr/ports/devel/autoconf;make install clean
3 cd /usr/ports/devel/automake;make install clean
4 bash < <(curl -s https://rvm.beginrescueend.com/install/rvm)