Author: Sean Gillies Version: 1.0
This document describes a GeoJSON-like protocol for geo-spatial (GIS) vector data.
| The regex patterns in this gist are intended to match any URLs, | |
| including "mailto:foo@example.com", "x-whatever://foo", etc. For a | |
| pattern that attempts only to match web URLs (http, https), see: | |
| https://gist.github.com/gruber/8891611 | |
| # Single-line version of pattern: | |
| (?i)\b((?:[a-z][\w-]+:(?:/{1,3}|[a-z0-9%])|www\d{0,3}[.]|[a-z0-9.\-]+[.][a-z]{2,4}/)(?:[^\s()<>]+|\(([^\s()<>]+|(\([^\s()<>]+\)))*\))+(?:\(([^\s()<>]+|(\([^\s()<>]+\)))*\)|[^\s`!()\[\]{};:'".,<>?«»“”‘’])) |
| # Author: Pieter Noordhuis | |
| # Description: Simple demo to showcase Redis PubSub with EventMachine | |
| # | |
| # Update 7 Oct 2010: | |
| # - This example does *not* appear to work with Chrome >=6.0. Apparently, | |
| # the WebSocket protocol implementation in the cramp gem does not work | |
| # well with Chrome's (newer) WebSocket implementation. | |
| # | |
| # Requirements: | |
| # - rubygems: eventmachine, thin, cramp, sinatra, yajl-ruby |
| The regex patterns in this gist are intended only to match web URLs -- http, | |
| https, and naked domains like "example.com". For a pattern that attempts to | |
| match all URLs, regardless of protocol, see: https://gist.github.com/gruber/249502 | |
| # Single-line version: | |
| (?i)\b((?:https?:(?:/{1,3}|[a-z0-9%])|[a-z0-9.\-]+[.](?:com|net|org|edu|gov|mil|aero|asia|biz|cat|coop|info|int|jobs|mobi|museum|name|post|pro|tel|travel|xxx|ac|ad|ae|af|ag|ai|al|am|an|ao|aq|ar|as|at|au|aw|ax|az|ba|bb|bd|be|bf|bg|bh|bi|bj|bm|bn|bo|br|bs|bt|bv|bw|by|bz|ca|cc|cd|cf|cg|ch|ci|ck|cl|cm|cn|co|cr|cs|cu|cv|cx|cy|cz|dd|de|dj|dk|dm|do|dz|ec|ee|eg|eh|er|es|et|eu|fi|fj|fk|fm|fo|fr|ga|gb|gd|ge|gf|gg|gh|gi|gl|gm|gn|gp|gq|gr|gs|gt|gu|gw|gy|hk|hm|hn|hr|ht|hu|id|ie|il|im|in|io|iq|ir|is|it|je|jm|jo|jp|ke|kg|kh|ki|km|kn|kp|kr|kw|ky|kz|la|lb|lc|li|lk|lr|ls|lt|lu|lv|ly|ma|mc|md|me|mg|mh|mk|ml|mm|mn|mo|mp|mq|mr|ms|mt|mu|mv|mw|mx|my|mz|na|nc|ne|nf|ng|ni|nl|no|np|nr|nu|nz|om|pa|pe|pf|pg|ph|pk|pl|pm|pn|pr|ps|pt|pw|py|qa|re|ro|rs|ru|rw|sa|sb|sc|sd|se|sg|sh|si|s |
| # <type>: (If applied, this commit will...) <subject> (Max 50 char) | |
| # |<---- Using a Maximum Of 50 Characters ---->| | |
| # Explain why this change is being made | |
| # |<---- Try To Limit Each Line to a Maximum Of 72 Characters ---->| | |
| # Provide links or keys to any relevant tickets, articles or other resources | |
| # Example: Github issue #23 |
| server { | |
| listen 80; | |
| server_name domain.com; | |
| root /var/www/domain.com; | |
| location ~ /.well-known { | |
| allow all; | |
| } | |
| location ~ /\.ht { |
| { | |
| "vars": { | |
| "@gray-base": "#000", | |
| "@gray-darker": "lighten(@gray-base, 13.5%)", | |
| "@gray-dark": "lighten(@gray-base, 20%)", | |
| "@gray": "lighten(@gray-base, 33.5%)", | |
| "@gray-light": "lighten(@gray-base, 46.7%)", | |
| "@gray-lighter": "lighten(@gray-base, 93.5%)", | |
| "@brand-primary": "darken(#428bca, 6.5%)", | |
| "@brand-success": "#5cb85c", |
| server { | |
| listen 80; | |
| server_name your.domain.com; | |
| location = /analytics.js { | |
| # you have to compile nginx with http://nginx.org/en/docs/http/ngx_http_sub_module.html (this is not default) | |
| # and http://nginx.org/en/docs/http/ngx_http_proxy_module.html (it's a default module) | |
| proxy_set_header Accept-Encoding ""; |
| import asyncio | |
| import random | |
| import time | |
| async def worker(name, queue): | |
| while True: | |
| # Get a "work item" out of the queue. | |
| sleep_for = await queue.get() |