Skip to content

Instantly share code, notes, and snippets.

<?php
namespace Rocket\Task\Service;
use DOMDocument;
use DOMNode;
use SoapClient;
use Exception;
/**
#include <cmath>
#include <cstdio>
#include <vector>
#include <iostream>
#include <algorithm>
#include <queue>
#include <set>
#include <climits>
using namespace std;
$count = array();
$path = __DIR__.'/php-fig/mbox/';
foreach(scandir($path) as $file) {
if(in_array($file, array('.', '..'))) {
continue;
}
$file = file_get_contents($path.$file);
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- Bootstrap -->
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css" rel="stylesheet">
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap-theme.min.css" rel="stylesheet">
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- Bootstrap -->
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css" rel="stylesheet">
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap-theme.min.css" rel="stylesheet">
#
# Automatically generated file; DO NOT EDIT.
# Linux/x86 4.1.6-gentoo Kernel Configuration
#
#
# Gentoo Linux
#
CONFIG_GENTOO_LINUX=y
CONFIG_GENTOO_LINUX_UDEV=y
# ~/.config/qtile/config.py
from libqtile.config import Key, Screen, Group, Drag, Click
from libqtile.command import lazy
from libqtile import layout, bar, widget
mod = "mod4"
keys = [
from libqtile.config import Key, Screen, Group, Drag, Click
from libqtile.command import lazy
from libqtile import layout, bar, widget
mod = "mod4"
keys = [
Key([mod], "h", lazy.layout.left()),
Key([mod], "l", lazy.layout.right()),

Ok here is my idea:

Mock server: Has a factory function which fork()s and then creates a simple socket server on specified port and initializes a pipe and returns information about that pipe

Mock client: Ensures a server is started, gets pipe info and uses that to communicate with the server. When setting up a mocj URL client pushes info through the pipe and the server sets up a coresponding route

draconyster@gmail.com