Skip to content

Instantly share code, notes, and snippets.

@nfnty
nfnty / taha_less
Created December 7, 2016 17:04
`echodoc#util#get_func_text()` replicate performance issues
CLOCK_THREAD_CPUTIME_ID /this/is/a/long/path123456789/this/is/a/long/path123456789/this/is/a/long/path123456789/this/is/a/long/path123456789/this/is/a/long/path123456789 /^pub const CLOCK_THREAD_CPUTIME_ID: clockid_t = 14;$/;" c
CLOCK_THREAD_CPUTIME_ID /this/is/a/long/path123456789/this/is/a/long/path123456789/this/is/a/long/path123456789/this/is/a/long/path123456789/this/is/a/long/path123456789 /^pub const CLOCK_THREAD_CPUTIME_ID: clockid_t = 14;$/;" c
CLOCK_THREAD_CPUTIME_ID /this/is/a/long/path123456789/this/is/a/long/path123456789/this/is/a/long/path123456789/this/is/a/long/path123456789/this/is/a/long/path123456789 /^pub const CLOCK_THREAD_CPUTIME_ID: clockid_t = 14;$/;" c
CLOCK_THREAD_CPUTIME_ID /this/is/a/long/path123456789/this/is/a/long/path123456789/this/is/a/long/path123456789/this/is/a/long/path123456789/this/is/a/long/path123456789 /^pub const CLOCK_THREAD_CPUTIME_ID: clockid_t = 14;$/;" c
CLOCK_THREAD_CPUTIME_ID /this/is/a/long/path123456789/this/is/a/long/path123456789/this/is/a/long/path123456
@nfnty
nfnty / config.json
Last active February 20, 2020 01:40
powerdns-recursor lua-dns-script
{
"BlacklistSuffixes": [
],
"WhitelistSuffixes": [
"bitcointalk.org."
],
"WhitelistFullmatches": [
"s3.amazonaws.com.",
"yui.yahooapis.com."
],
@nfnty
nfnty / evdev_latency.py
Last active July 5, 2022 13:25
evdev latency tester
#!/usr/bin/python3
''' evdev latency tester '''
import argparse
import statistics
import evdev
@nfnty
nfnty / screensaver.py
Created November 18, 2015 12:22
bspwm events screensaver toggling
#!/usr/bin/python3 -u
''' Screensaver fullscreen toggling '''
import subprocess
import json
def class_find(windows, name):
''' Find className '''
for window in windows.values():
if window['client']['className'] == name:
/*--- waitForKeyElements(): A utility function, for Greasemonkey scripts,
that detects and handles AJAXed content.
Usage example:
waitForKeyElements (
"div.comments"
, commentCallbackFunction
);