Skip to content

Instantly share code, notes, and snippets.

View splitice's full-sized avatar

Mathew Heard splitice

View GitHub Profile
const otherFunc = async (timer, t, i) => {
if(timer === t._timer) {
t._timer = setTimeout(()=>t.main(++i), 0)
}
}
class test {
async main(i = 0){
const timer = this._timer
const otherFunc = async (timer, t, i) => {
if(timer === t._timer) {
t._timer = setTimeout((t)=>t.main(++i), 0, t)
}
}
class test {
async main(i = 0){
const timer = this._timer
class test {
async main(i = 0){
const timer = this._timer
const signal = () => {
return new Promise(cb => setImmediate(() => cb(i)))
}
const otherFunc = async () => {
if(timer === this._timer) this._timer = setTimeout(()=>this.main(++i), 0)
}
diff -u -r nginx/auto/options nginx-patched/auto/options
--- nginx/auto/options 2017-09-28 04:50:45.308000000 -0400
+++ nginx-patched/auto/options 2017-09-28 05:00:28.352000000 -0400
@@ -44,7 +44,7 @@
USE_THREADS=NO
NGX_FILE_AIO=NO
-
+NGX_TPROXY=NO
HTTP=YES
@splitice
splitice / luarocks
Created June 26, 2016 11:20 — forked from mariocesar/luarocks
Luarocks Ansible module
#!/usr/bin/env python
# vim:fileencoding=utf-8
"""
(c) 2014, Mario César Señoranis Ayala <mariocesar.c50@gmail.com>
TODO:
- Enforce version
- Support for --local argument
- Support build parameters
ip addr show eth0 | grep inet | awk '{print "timeout 2s arping -U "substr($2, 0, length($2)-3)}'
// hashexample.cpp : Defines the entry point for the console application.
//
#include "stdafx.h"
#include <vector>
#include <stdint.h>
#include "MurmurHash3.h"
#define TABLE_SIZE 6024000
uint16_t table_size_used;
// hashexample.cpp : Defines the entry point for the console application.
//
#include "stdafx.h"
#include <vector>
#include <stdint.h>
#include "MurmurHash3.h"
#define TABLE_SIZE 30240
uint16_t table_size_used = 1000;
#!/bin/bash
#Built during an OVH outage for https://www.x4b.net
#Absolutely NO warranty implied
#Do not even think of blaming me if something goes wrong
#Use at own risk
#Requires: curl, prips, openssl, jq
#FILL OUT!
AK=""
AS=""
ifconfig | grep "inet" | awk '{print $2}' | grep "64." | awk '{print "arping -A -c 1 -I eth0 " substr($1,6)}' | bash