This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* This is a modified version of https://github.com/nylki/lindenmayer. | |
** The modifications make it work in Internet Explorer again. | |
** The modifications include: | |
** * Replacing `let` with `var`. | |
** * Replacing `{ x }` with `{ x : x }` in object context. | |
** * Replacing `class` with `function. | |
** * Replacing `{ arg1, arg2, }` with `opts` in function definition context. | |
** * Replacing `x of obj` with a `for (var i = 0; i < obj.length; i++)` | |
** * Replacing default arguments with `if (arg === undefined) { arg = defaultVal; }` | |
** * Replacing `array.push(...obj)` with `array.extend(obj)`. |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use warnings; | |
use strict; | |
use Text::CSV; | |
use constant { | |
ID => 0, | |
TYPE => 1, | |
SOURCE => 2, | |
AMOUNT => 3, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
iptables.list('Tunnels', function (rules) { | |
var ports = {}; | |
rules.forEach(function (rule) { | |
if (rule.parsed.target == 'REJECT') return; | |
// extract tcp destination ports | |
var match = rule.raw.match(/tcp dpt:(\d+)/); | |
if (match) { | |
ports[parseInt(match[1])] = 1; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[daemons] | |
; enable SSL support by uncommenting the following line and supply the PEM's below. | |
; the default ssl port CouchDB listens on is 6984 | |
; httpsd = {couch_httpd, start_link, [https]} | |
compaction_daemon={couch_compaction_daemon, start_link, []} | |
[compaction_daemon] | |
; The delay, in seconds, between each check for which database and view indexes | |
; need to be compacted. | |
check_interval = 300 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$browserlingTunnelPort = 59374; | |
$browserlingTunnelUrl = "http://tunnel.browserling.com:" . $browserlingTunnelPort . "/WordPress/TestingWp/"; | |
if ($_SERVER['REMOTE_ADDR'] != '127.0.0.1') { | |
define('WP_SITEURL', $browserlingTunnelUrl); | |
define('WP_HOME', $browserlingTunnelUrl); | |
update_option('siteurl', $browserlingTunnelUrl); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <windows.h> | |
#include <cstdio> | |
int WINAPI wWinMain(HINSTANCE hInstance, HINSTANCE, PWSTR pCmdLine, int nCmdShow) { | |
while (1) { | |
HWND dialog = FindWindow("MozillaDialogClass", "FireFox Update"); | |
if (dialog) { | |
printf("Found dialog: %x\n", dialog); | |
HWND dialogItem = NULL; | |
SendMessage(dialog, WM_CLOSE, 0, 0); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var $ = require('jquery-browserify'); | |
$(window).ready(function () { | |
if (!window.navigator.userAgent.match(/chrome|chromium/i)) { | |
$('<div>') | |
.addClass('alert') | |
.append( | |
$('<img>').attr('src', '/img/chrome.png'), | |
$('<div>').text( | |
"You don't appear to be using chrome, " |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// server.js | |
var dnode = require('dnode'); | |
function Manager () { | |
var desktops = {}; | |
var self = this; | |
this.spawn = function (name) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Prelude hiding (catch) | |
import System (getArgs) | |
import System.IO (hPutStrLn, hSetBuffering, BufferMode(NoBuffering), hClose, Handle) | |
import System.IO.Error (isEOFError, IOError(..)) | |
import Network (connectTo, PortID(..), withSocketsDo) | |
import Control.Concurrent (forkIO, threadDelay) | |
import Control.Exception | |
delay :: Int | |
delay = 60 |
NewerOlder