├── site ├── data │ └── .gitignore ├── layouts │ ├── .gitignore │ ├── index.html │ ├── root │ │ ├── sponsors.html │ │ ├── foot.html │ │ ├── headline.html │ │ ├── head.html │ │ └── content.html │ └── 404.html ├── archetypes │ ├── .gitignore │ ├── post.md │ ├── page.md │ └── design.md ├── static │ ├── favicon.ico │ ├── mstile-70x70.png │ ├── favicon-16x16.png │ ├── favicon-32x32.png │ ├── favicon-96x96.png │ ├── ms-icon-70x70.png │ ├── mstile-144x144.png │ ├── mstile-150x150.png │ ├── mstile-310x150.png │ ├── mstile-310x310.png │ ├── apple-touch-icon.png │ ├── ms-icon-144x144.png │ ├── ms-icon-150x150.png │ ├── ms-icon-310x310.png │ ├── android-chrome-144x144.png │ ├── android-chrome-192x192.png │ ├── android-chrome-36x36.png │ ├── android-chrome-48x48.png │ ├── android-chrome-72x72.png │ ├── android-chrome-96x96.png │ ├── apple-touch-icon-57x57.png │ ├── apple-touch-icon-60x60.png │ ├── apple-touch-icon-72x72.png │ ├── apple-touch-icon-76x76.png │ ├── assets │ │ ├── img │ │ │ ├── book_blues.png │ │ │ ├── blur-a_blues.jpg │ │ │ ├── blur-b_blues.jpg │ │ │ ├── hubble_blues.jpg │ │ │ ├── otp_structure.png │ │ │ ├── grainy-a_blues.jpg │ │ │ └── grainy-b_blues.jpg │ │ ├── fonts │ │ │ ├── FontAwesome.otf │ │ │ ├── fontawesome-webfont.eot │ │ │ ├── fontawesome-webfont.ttf │ │ │ └── fontawesome-webfont.woff │ │ └── less │ │ │ └── style.less │ ├── apple-touch-icon-114x114.png │ ├── apple-touch-icon-120x120.png │ ├── apple-touch-icon-144x144.png │ ├── apple-touch-icon-152x152.png │ ├── apple-touch-icon-180x180.png │ ├── apple-touch-icon-precomposed.png │ ├── browserconfig.xml │ └── manifest.json ├── themes │ └── hyde-x │ │ ├── images │ │ ├── tn.png │ │ ├── screenshot.png │ │ └── theme-colours.png │ │ ├── archetypes │ │ └── default.md │ │ ├── static │ │ ├── css │ │ │ ├── poole-overrides.css │ │ │ ├── highlight │ │ │ │ ├── pojoaque.jpg │ │ │ │ ├── school_book.png │ │ │ │ ├── brown_papersq.png │ │ │ │ ├── androidstudio.css │ │ │ │ ├── ascetic.css │ │ │ │ ├── mono-blue.css │ │ │ │ ├── codepen-embed.css │ │ │ │ ├── tomorrow.css │ │ │ │ ├── vs.css │ │ │ │ ├── paraiso.dark.css │ │ │ │ ├── paraiso.light.css │ │ │ │ ├── kimbie.dark.css │ │ │ │ ├── ir_black.css │ │ │ │ ├── kimbie.light.css │ │ │ │ ├── tomorrow-night-bright.css │ │ │ │ ├── tomorrow-night-eighties.css │ │ │ │ ├── rainbow.css │ │ │ │ ├── atelier-dune.dark.css │ │ │ │ ├── atelier-dune.light.css │ │ │ │ ├── tomorrow-night.css │ │ │ │ ├── atelier-heath.dark.css │ │ │ │ ├── atelier-heath.light.css │ │ │ │ ├── tomorrow-night-blue.css │ │ │ │ ├── atelier-forest.dark.css │ │ │ │ ├── atelier-forest.light.css │ │ │ │ ├── atelier-seaside.dark.css │ │ │ │ ├── atelier-seaside.light.css │ │ │ │ ├── atelier-lakeside.dark.css │ │ │ │ ├── atelier-lakeside.light.css │ │ │ │ ├── atelier-sulphurpool.dark.css │ │ │ │ ├── atelier-sulphurpool.light.css │ │ │ │ ├── solarized_dark.css │ │ │ │ ├── solarized_light.css │ │ │ │ ├── pojoaque.css │ │ │ │ ├── dark.css │ │ │ │ ├── brown_paper.css │ │ │ │ ├── github.css │ │ │ │ ├── far.css │ │ │ │ ├── foundation.css │ │ │ │ ├── idea.css │ │ │ │ ├── zenburn.css │ │ │ │ ├── magula.css │ │ │ │ ├── school_book.css │ │ │ │ ├── atelier-cave.dark.css │ │ │ │ ├── atelier-cave.light.css │ │ │ │ ├── docco.css │ │ │ │ ├── atelier-estuary.dark.css │ │ │ │ ├── atelier-estuary.light.css │ │ │ │ ├── atelier-plateau.dark.css │ │ │ │ ├── atelier-plateau.light.css │ │ │ │ ├── atelier-savanna.dark.css │ │ │ │ ├── atelier-savanna.light.css │ │ │ │ ├── agate.css │ │ │ │ ├── monokai.css │ │ │ │ ├── googlecode.css │ │ │ │ ├── arta.css │ │ │ │ └── xcode.css │ │ │ └── hyde-overrides.css │ │ └── touch-icon-144-precomposed.png │ │ ├── layouts │ │ ├── _default │ │ │ ├── single.html │ │ │ └── list.html │ │ ├── 404.html │ │ ├── partials │ │ │ ├── foot.html │ │ │ ├── sidebar.html │ │ │ └── head.html │ │ ├── index.html │ │ └── post │ │ │ └── single.html │ │ ├── theme.toml │ │ └── LICENSE └── config.yaml ├── rel ├── sys.config └── vm.args ├── rebar.lock ├── rebar.config ├── test ├── data │ ├── m74.jpg │ ├── m74-1Kb.jpg │ ├── haves.trace │ ├── chunks.trace │ └── handshakes.trace ├── template_SUITE ├── ppspp_chunk_SUITE.erl ├── ppspp_have_SUITE.erl ├── ppspp_handshake_SUITE.erl ├── swarm_worker_SUITE.erl ├── peer_worker_SUITE.erl ├── swirl_SUITE.erl └── ppspp_options_SUITE.erl ├── relx.config ├── .gitignore ├── doc ├── content │ ├── encoder.md │ ├── storage.md │ ├── traversal.md │ ├── streaming.md │ ├── embedded.md │ ├── traffic.md │ ├── billing.md │ ├── deployment.md │ ├── browser.md │ ├── mobile.md │ ├── zeroconf.md │ ├── decoder.md │ ├── about.md │ └── url.md ├── README.md ├── overview.edoc └── blog │ └── fresh_start.md ├── .travis.yml ├── NOTICE.md ├── swirl.config ├── src ├── swirl.app.src ├── swirl_app.erl ├── convert.erl ├── swirl_sup.erl ├── swarm_sup.erl ├── peer_sup.erl ├── channel_sup.erl ├── template └── ppspp_have.erl └── include └── swirl.hrl /site/data/.gitignore: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /site/layouts/.gitignore: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /rel/sys.config: -------------------------------------------------------------------------------- 1 | [ 2 | ]. 3 | -------------------------------------------------------------------------------- /site/archetypes/.gitignore: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /rebar.lock: -------------------------------------------------------------------------------- 1 | [{<<"gproc">>,{pkg,<<"gproc">>,<<"0.5.0">>},0}]. 2 | -------------------------------------------------------------------------------- /rel/vm.args: -------------------------------------------------------------------------------- 1 | -name swirl@127.0.0.1 2 | -setcookie swirl 3 | -heart 4 | -------------------------------------------------------------------------------- /rebar.config: -------------------------------------------------------------------------------- 1 | {deps, [ 2 | {gproc, "0.5.0"} 3 | ] 4 | }. 5 | 6 | -------------------------------------------------------------------------------- /test/data/m74.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/test/data/m74.jpg -------------------------------------------------------------------------------- /site/static/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/favicon.ico -------------------------------------------------------------------------------- /test/data/m74-1Kb.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/test/data/m74-1Kb.jpg -------------------------------------------------------------------------------- /site/static/mstile-70x70.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/mstile-70x70.png -------------------------------------------------------------------------------- /site/static/favicon-16x16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/favicon-16x16.png -------------------------------------------------------------------------------- /site/static/favicon-32x32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/favicon-32x32.png -------------------------------------------------------------------------------- /site/static/favicon-96x96.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/favicon-96x96.png -------------------------------------------------------------------------------- /site/static/ms-icon-70x70.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/ms-icon-70x70.png -------------------------------------------------------------------------------- /site/static/mstile-144x144.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/mstile-144x144.png -------------------------------------------------------------------------------- /site/static/mstile-150x150.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/mstile-150x150.png -------------------------------------------------------------------------------- /site/static/mstile-310x150.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/mstile-310x150.png -------------------------------------------------------------------------------- /site/static/mstile-310x310.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/mstile-310x310.png -------------------------------------------------------------------------------- /site/static/apple-touch-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/apple-touch-icon.png -------------------------------------------------------------------------------- /site/static/ms-icon-144x144.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/ms-icon-144x144.png -------------------------------------------------------------------------------- /site/static/ms-icon-150x150.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/ms-icon-150x150.png -------------------------------------------------------------------------------- /site/static/ms-icon-310x310.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/ms-icon-310x310.png -------------------------------------------------------------------------------- /site/themes/hyde-x/images/tn.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/themes/hyde-x/images/tn.png -------------------------------------------------------------------------------- /site/static/android-chrome-144x144.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/android-chrome-144x144.png -------------------------------------------------------------------------------- /site/static/android-chrome-192x192.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/android-chrome-192x192.png -------------------------------------------------------------------------------- /site/static/android-chrome-36x36.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/android-chrome-36x36.png -------------------------------------------------------------------------------- /site/static/android-chrome-48x48.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/android-chrome-48x48.png -------------------------------------------------------------------------------- /site/static/android-chrome-72x72.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/android-chrome-72x72.png -------------------------------------------------------------------------------- /site/static/android-chrome-96x96.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/android-chrome-96x96.png -------------------------------------------------------------------------------- /site/static/apple-touch-icon-57x57.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/apple-touch-icon-57x57.png -------------------------------------------------------------------------------- /site/static/apple-touch-icon-60x60.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/apple-touch-icon-60x60.png -------------------------------------------------------------------------------- /site/static/apple-touch-icon-72x72.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/apple-touch-icon-72x72.png -------------------------------------------------------------------------------- /site/static/apple-touch-icon-76x76.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/apple-touch-icon-76x76.png -------------------------------------------------------------------------------- /site/static/assets/img/book_blues.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/assets/img/book_blues.png -------------------------------------------------------------------------------- /site/static/apple-touch-icon-114x114.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/apple-touch-icon-114x114.png -------------------------------------------------------------------------------- /site/static/apple-touch-icon-120x120.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/apple-touch-icon-120x120.png -------------------------------------------------------------------------------- /site/static/apple-touch-icon-144x144.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/apple-touch-icon-144x144.png -------------------------------------------------------------------------------- /site/static/apple-touch-icon-152x152.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/apple-touch-icon-152x152.png -------------------------------------------------------------------------------- /site/static/apple-touch-icon-180x180.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/apple-touch-icon-180x180.png -------------------------------------------------------------------------------- /site/static/assets/fonts/FontAwesome.otf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/assets/fonts/FontAwesome.otf -------------------------------------------------------------------------------- /site/static/assets/img/blur-a_blues.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/assets/img/blur-a_blues.jpg -------------------------------------------------------------------------------- /site/static/assets/img/blur-b_blues.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/assets/img/blur-b_blues.jpg -------------------------------------------------------------------------------- /site/static/assets/img/hubble_blues.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/assets/img/hubble_blues.jpg -------------------------------------------------------------------------------- /site/static/assets/img/otp_structure.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/assets/img/otp_structure.png -------------------------------------------------------------------------------- /site/themes/hyde-x/archetypes/default.md: -------------------------------------------------------------------------------- 1 | +++ 2 | title = "" 3 | description = "" 4 | keywords = [] 5 | categories = [] 6 | +++ 7 | -------------------------------------------------------------------------------- /site/themes/hyde-x/images/screenshot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/themes/hyde-x/images/screenshot.png -------------------------------------------------------------------------------- /site/static/assets/img/grainy-a_blues.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/assets/img/grainy-a_blues.jpg -------------------------------------------------------------------------------- /site/static/assets/img/grainy-b_blues.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/assets/img/grainy-b_blues.jpg -------------------------------------------------------------------------------- /site/themes/hyde-x/images/theme-colours.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/themes/hyde-x/images/theme-colours.png -------------------------------------------------------------------------------- /site/static/apple-touch-icon-precomposed.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/apple-touch-icon-precomposed.png -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/poole-overrides.css: -------------------------------------------------------------------------------- 1 | /* 2 | * Tweaks and overrides to poole.css 3 | */ 4 | 5 | pre { 6 | padding: 0 7 | } 8 | -------------------------------------------------------------------------------- /site/static/assets/fonts/fontawesome-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/assets/fonts/fontawesome-webfont.eot -------------------------------------------------------------------------------- /site/static/assets/fonts/fontawesome-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/assets/fonts/fontawesome-webfont.ttf -------------------------------------------------------------------------------- /site/static/assets/fonts/fontawesome-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/static/assets/fonts/fontawesome-webfont.woff -------------------------------------------------------------------------------- /site/archetypes/post.md: -------------------------------------------------------------------------------- 1 | --- 2 | categories: 3 | - blog 4 | - design 5 | tags: 6 | - update 7 | weight: 0 8 | draft: true 9 | --- 10 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/pojoaque.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/themes/hyde-x/static/css/highlight/pojoaque.jpg -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/school_book.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/themes/hyde-x/static/css/highlight/school_book.png -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/brown_papersq.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/themes/hyde-x/static/css/highlight/brown_papersq.png -------------------------------------------------------------------------------- /site/themes/hyde-x/static/touch-icon-144-precomposed.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/skunkwerks/swirl/HEAD/site/themes/hyde-x/static/touch-icon-144-precomposed.png -------------------------------------------------------------------------------- /site/archetypes/page.md: -------------------------------------------------------------------------------- 1 | --- 2 | categories: 3 | - overview 4 | - design 5 | tags: 6 | - page 7 | menu: main 8 | weight: 0 9 | draft: true 10 | --- 11 | -------------------------------------------------------------------------------- /relx.config: -------------------------------------------------------------------------------- 1 | {release, {swirl, "0.1"}, [swirl]}. 2 | {extended_start_script, true}. 3 | {include_src, false}. 4 | {sys_config, "rel/sys.config"}. 5 | {vm_args, "rel/vm.args"}. 6 | -------------------------------------------------------------------------------- /site/static/assets/less/style.less: -------------------------------------------------------------------------------- 1 | // 2 | // Import Cascade 3 | // -------------------------------------------------- 4 | 5 | @import '../../less/cascade.less'; 6 | @import 'cascade-variables.less'; 7 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *.swp 2 | erl_crash.dump 3 | /swirl 4 | /public/ 5 | .*.plt 6 | .erlang.mk.packages.* 7 | _rel 8 | /deps 9 | /ebin 10 | /logs 11 | /relx 12 | test/*.beam 13 | .erlang.mk 14 | doc/api 15 | _build/ 16 | -------------------------------------------------------------------------------- /site/themes/hyde-x/layouts/_default/single.html: -------------------------------------------------------------------------------- 1 | {{ partial "head.html" . }} 2 |
3 |
4 |

{{ .Title }}

5 | {{ .Content }} 6 |
7 |
8 | {{ partial "foot.html" . }} -------------------------------------------------------------------------------- /doc/content/encoder.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Packet Encoder 3 | description: Design for the Packet Encoder 4 | menu: main 5 | weight: 80 6 | draft: false 7 | --- 8 | 9 | This page is unintentionally left blank. We're working on more documentation all the time. 10 | -------------------------------------------------------------------------------- /site/layouts/index.html: -------------------------------------------------------------------------------- 1 | {{ template "root/head.html" . }} 2 | {{ template "root/headline.html" . }} 3 | {{ template "root/content.html" . }} 4 | {{ template "root/contributing.html" . }} 5 | {{ template "root/sponsors.html" . }} 6 | {{ template "root/foot.html" . }} 7 | -------------------------------------------------------------------------------- /doc/content/storage.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Storage Layer 3 | description: Design & Implementation of the Storage layer 4 | menu: main 5 | weight: 70 6 | draft: false 7 | --- 8 | 9 | This page is unintentionally left blank. We're working on more documentation all the time. 10 | -------------------------------------------------------------------------------- /doc/content/traversal.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: NAT & firewall traversal 3 | description: Using STUN/ICE/NAT strategies with swirl 4 | menu: main 5 | weight: 1000 6 | draft: false 7 | --- 8 | 9 | This page is unintentionally left blank. We're working on more documentation all the time. 10 | -------------------------------------------------------------------------------- /doc/content/streaming.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Live Streaming 3 | description: How the live streaming functionality is implemented 4 | menu: main 5 | weight: 1000 6 | draft: false 7 | --- 8 | 9 | This page is unintentionally left blank. We're working on more documentation all the time. 10 | -------------------------------------------------------------------------------- /doc/content/embedded.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Embedded Devices 3 | description: Embedding Swirl in small form-factor appliances and devices 4 | menu: main 5 | weight: 1000 6 | draft: false 7 | --- 8 | 9 | This page is unintentionally left blank. We're working on more documentation all the time. 10 | -------------------------------------------------------------------------------- /doc/content/traffic.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Traffic Management & Shaping 3 | description: Managing traffic and network flows using Swirl 4 | menu: main 5 | weight: 1000 6 | draft: false 7 | --- 8 | 9 | This page is unintentionally left blank. We're working on more documentation all the time. 10 | -------------------------------------------------------------------------------- /doc/content/billing.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Billing Capabilities 3 | description: Design for optional billing and usage tracking capabilities 4 | menu: main 5 | weight: 1000 6 | draft: false 7 | --- 8 | 9 | This page is unintentionally left blank. We're working on more documentation all the time. 10 | -------------------------------------------------------------------------------- /doc/content/deployment.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Deployment Options 3 | description: build OTP releases for Vagrant, FreeBSD, docker/LXC targets 4 | menu: main 5 | weight: 90 6 | draft: false 7 | --- 8 | 9 | This page is unintentionally left blank. We're working on more documentation all the time. 10 | -------------------------------------------------------------------------------- /doc/content/browser.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Browser and JavaScript Support 3 | description: Design for javascript-based browser and nodejs support 4 | menu: main 5 | weight: 1000 6 | draft: false 7 | --- 8 | 9 | This page is unintentionally left blank. We're working on more documentation all the time. 10 | -------------------------------------------------------------------------------- /doc/content/mobile.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Mobile Implementations 3 | description: Implementing Swirl as native code on mobile devices and platforms 4 | menu: main 5 | weight: 1000 6 | draft: false 7 | --- 8 | 9 | This page is unintentionally left blank. We're working on more documentation all the time. 10 | -------------------------------------------------------------------------------- /doc/content/zeroconf.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: ZeroConf Support 3 | description: Swirl supports peer and stream detection via mDNS or ZeroConf protocol 4 | menu: main 5 | weight: 1000 6 | draft: false 7 | --- 8 | 9 | This page is unintentionally left blank. We're working on more documentation all the time. 10 | -------------------------------------------------------------------------------- /site/themes/hyde-x/layouts/404.html: -------------------------------------------------------------------------------- 1 | {{ partial "head.html" . }} 2 |
3 |
4 |

404 Not Found

5 |

What you're looking for isn't here, sorry!

6 |

← Click here to go back home

7 |
8 |
9 | {{ partial "foot.html" . }} -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/hyde-overrides.css: -------------------------------------------------------------------------------- 1 | /* 2 | * Tweaks and overrides to hyde.css 3 | */ 4 | 5 | .sidebar-about h1 { 6 | color: #fff; 7 | margin-top: 0; 8 | font-family: "Abril Fatface", serif; 9 | font-size: 2.5rem; 10 | } 11 | 12 | .sidebar-nav { 13 | padding-left: 0; 14 | list-style: none; 15 | margin-bottom: 1rem; 16 | } 17 | -------------------------------------------------------------------------------- /site/layouts/root/sponsors.html: -------------------------------------------------------------------------------- 1 | 9 | -------------------------------------------------------------------------------- /site/layouts/404.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | the Swarm cannot help you now. 7 | 8 | 9 |
10 |
11 |

{{ .Title }}

12 |

The Swarm doesn't have what you need.. sorry about that.

13 |
14 |
15 | 16 | 17 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | language: erlang 2 | notifications: 3 | irc: irc.freenode.net#swirlproject 4 | slack: 5 | secure: NzsTh8t8lshkf9jEcp+INLW4Oo0sihS07UwLO7UE3EOIpcMNGd/GzDQSWydcE2ddv6yPCUDEsXQCp0dSRJoRQMPgnlkKC31O1G0zZrZij5kg+tSuQHh4SMlLJ28g/6inUYmmxbpmLHsokr1N625DQAhgiGgglBF1xbT0PEv8z70= 6 | script: V=1 make distcheck 7 | otp_release: 8 | - 18.2 9 | branches: 10 | only: 11 | - master 12 | - develop 13 | - "/^merge.+/" 14 | -------------------------------------------------------------------------------- /site/static/browserconfig.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | #2b5797 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /NOTICE.md: -------------------------------------------------------------------------------- 1 | # The Swirl Project 2 | 3 | Copyright 2014-2038 4 | SkunkWerks GmbH 5 | 6 | This project also gratefully includes the following third-party components. Your 7 | use of the code for the these subcomponents is subject to the terms and 8 | conditions of their respective licenses, not to mention their awesomeness: 9 | 10 | - [erlang.mk](https://github.com/extend/erlang.mk) ISC 11 | - [gproc](https://github.com/uwiger/gproc) EPL 1.1 12 | - [hyde-x](https://github.com/zyro/hyde-x) MIT 13 | - [highlightjs](https://highlightjs.org/) BSD3 14 | -------------------------------------------------------------------------------- /site/themes/hyde-x/layouts/partials/foot.html: -------------------------------------------------------------------------------- 1 | {{ if isset .Site.Params "highlight" }} 2 | {{ end }} 3 | {{ with .Site.Params.googleAnalytics }} 4 | 10 | {{ end }} 11 | 12 | -------------------------------------------------------------------------------- /site/themes/hyde-x/layouts/_default/list.html: -------------------------------------------------------------------------------- 1 | {{ partial "head.html" . }} 2 |
3 | 14 |
15 | {{ partial "foot.html" . }} -------------------------------------------------------------------------------- /doc/content/decoder.md: -------------------------------------------------------------------------------- 1 | --- 2 | date: 2015-06-03T22:08:50+02:00 3 | description: Design of wire format UDP datagram parser to native Erlang format 4 | menu: main 5 | title: Packet Decoder 6 | weight: 60 7 | --- 8 | 9 | This design doc is unintentionally left blank. We're working on more 10 | documentation all the time. 11 | 12 | ## Overview 13 | 14 | ## Description 15 | 16 | ## Implementation 17 | 18 | - Responsibilities 19 | - Modules 20 | - OTP Structure 21 | - Data types 22 | 23 | ## References 24 | 25 | ## Generated Module Docs 26 | 27 | ### Data Types 28 | ### Function Index 29 | ### Function Details 30 | -------------------------------------------------------------------------------- /site/archetypes/design.md: -------------------------------------------------------------------------------- 1 | --- 2 | description: a lovely design document 3 | menu: main 4 | tags: 5 | - page 6 | draft: true 7 | categories: 8 | - overview 9 | - design 10 | weight: 0 11 | --- 12 | 13 | This design doc is unintentionally left blank. We're working on more 14 | documentation all the time. 15 | 16 | ## Overview 17 | 18 | ## Description 19 | 20 | ## Implementation 21 | 22 | - Responsibilities 23 | - Modules 24 | - OTP Structure 25 | - Data types 26 | 27 | ## Testing 28 | 29 | ## References 30 | 31 | ## Generated Module Docs 32 | 33 | ### Data Types 34 | ### Function Index 35 | ### Function Details 36 | -------------------------------------------------------------------------------- /site/themes/hyde-x/theme.toml: -------------------------------------------------------------------------------- 1 | name = "Hyde-X" 2 | license = "MIT" 3 | licenselink = "https://github.com/zyro/hyde-x/LICENSE" 4 | description = "An elegant open source and mobile first theme, extended with new integrations and layout improvements" 5 | homepage = "https://github.com/zyro/hyde-x" 6 | tags = ["blog", "technical", "personal"] 7 | features = ["blog", "technical", "personal"] 8 | min_version=0.13 9 | 10 | [author] 11 | name = "Andrei Mihu" 12 | homepage = "http://andreimihu.com" 13 | 14 | # If Porting existing theme 15 | [original] 16 | author = "poole" 17 | homepage = "http://hyde.getpoole.com" 18 | repo = "https://github.com/poole/hyde" 19 | -------------------------------------------------------------------------------- /swirl.config: -------------------------------------------------------------------------------- 1 | %% -*- tab-width: 4;erlang-indent-level: 4;indent-tabs-mode: nil -*- 2 | %% ex: ft=erlang ts=4 sw=4 et 3 | %% Licensed under the Apache License, Version 2.0 (the "License"); you may not 4 | %% use this file except in compliance with the License. You may obtain a copy of 5 | %% the License at 6 | %% 7 | %% http://www.apache.org/licenses/LICENSE-2.0 8 | %% 9 | %% Unless required by applicable law or agreed to in writing, software 10 | %% distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | %% WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | %% License for the specific language governing permissions and limitations under 13 | %% the License. 14 | 15 | [ 16 | ]. 17 | -------------------------------------------------------------------------------- /site/config.yaml: -------------------------------------------------------------------------------- 1 | BaseURL: http://www.swirl-project.org 2 | languageCode: en-nz 3 | title: Bringing Peer-to-Peer Streaming to the World 4 | author: 5 | name: the Swirl Project 6 | builddrafts: false 7 | theme: hyde-x 8 | metadataformat: yaml 9 | canonifyurls: false 10 | relativeURLs: true 11 | contentdir: ../doc 12 | publishdir: ../public 13 | permalinks: 14 | page: pages/:filename 15 | blog: :year/:month/:day/:filename 16 | talk: talks/:year/:filename 17 | Params: 18 | defaultDescription: Bringing Peer-to-Peer Streaming to the World 19 | defaultKeywords: p2p,ppspp,streaming 20 | highlight: monokai_sublime 21 | tagline: Bringing Peer-to-Peer Streaming to the World 22 | copyright: "Copyright (c) 2014 - 2038 SkunkWerks GmbH; all rights reserved." 23 | github: https://github.com/skunkwerks/swirl 24 | twitter: http://twitter.com/swirl_project 25 | taxonomies: 26 | tag: tags 27 | category: categories 28 | ... 29 | -------------------------------------------------------------------------------- /site/static/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "swirl", 3 | "icons": [ 4 | { 5 | "src": "\/android-chrome-36x36.png", 6 | "sizes": "36x36", 7 | "type": "image\/png", 8 | "density": "0.75" 9 | }, 10 | { 11 | "src": "\/android-chrome-48x48.png", 12 | "sizes": "48x48", 13 | "type": "image\/png", 14 | "density": "1.0" 15 | }, 16 | { 17 | "src": "\/android-chrome-72x72.png", 18 | "sizes": "72x72", 19 | "type": "image\/png", 20 | "density": "1.5" 21 | }, 22 | { 23 | "src": "\/android-chrome-96x96.png", 24 | "sizes": "96x96", 25 | "type": "image\/png", 26 | "density": "2.0" 27 | }, 28 | { 29 | "src": "\/android-chrome-144x144.png", 30 | "sizes": "144x144", 31 | "type": "image\/png", 32 | "density": "3.0" 33 | }, 34 | { 35 | "src": "\/android-chrome-192x192.png", 36 | "sizes": "192x192", 37 | "type": "image\/png", 38 | "density": "4.0" 39 | } 40 | ] 41 | } 42 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/androidstudio.css: -------------------------------------------------------------------------------- 1 | /* 2 | Date: 24 Fev 2015 3 | Author: Pedro Oliveira 4 | */ 5 | 6 | .hljs { 7 | color: #a9b7c6; 8 | background: #282b2e; 9 | display: block; 10 | overflow-x: auto; 11 | padding: 0.5em; 12 | -webkit-text-size-adjust: none; 13 | } 14 | 15 | .hljs-number { 16 | color: #6897BB; 17 | } 18 | 19 | .hljs-keyword, 20 | .hljs-deletion { 21 | color: #cc7832; 22 | } 23 | 24 | .hljs-comment { 25 | color: #808080; 26 | } 27 | 28 | .hljs-annotation { 29 | color: #bbb529; 30 | } 31 | 32 | .hljs-string, 33 | .hljs-addition { 34 | color: #6A8759; 35 | } 36 | 37 | .hljs-function .hljs-title, 38 | .hljs-change { 39 | color: #ffc66d; 40 | } 41 | 42 | .hljs-tag .hljs-title, 43 | .hljs-doctype { 44 | color: #e8bf6a; 45 | } 46 | 47 | .hljs-tag .hljs-attribute { 48 | color: #bababa; 49 | } 50 | 51 | .hljs-tag .hljs-value { 52 | color: #a5c261; 53 | } 54 | -------------------------------------------------------------------------------- /site/layouts/root/foot.html: -------------------------------------------------------------------------------- 1 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/ascetic.css: -------------------------------------------------------------------------------- 1 | /* 2 | 3 | Original style from softwaremaniacs.org (c) Ivan Sagalaev 4 | 5 | */ 6 | 7 | .hljs { 8 | display: block; 9 | overflow-x: auto; 10 | padding: 0.5em; 11 | background: white; 12 | color: black; 13 | -webkit-text-size-adjust: none; 14 | } 15 | 16 | .hljs-string, 17 | .hljs-tag .hljs-value, 18 | .hljs-filter .hljs-argument, 19 | .hljs-addition, 20 | .hljs-change, 21 | .hljs-name, 22 | .apache .hljs-tag, 23 | .apache .hljs-cbracket, 24 | .nginx .hljs-built_in, 25 | .tex .hljs-formula { 26 | color: #888; 27 | } 28 | 29 | .hljs-comment, 30 | .hljs-shebang, 31 | .hljs-doctype, 32 | .hljs-pi, 33 | .hljs-deletion, 34 | .apache .hljs-sqbracket { 35 | color: #ccc; 36 | } 37 | 38 | .hljs-keyword, 39 | .hljs-tag .hljs-title, 40 | .ini .hljs-title, 41 | .lisp .hljs-title, 42 | .http .hljs-title, 43 | .nginx .hljs-title, 44 | .css .hljs-tag, 45 | .hljs-winutils, 46 | .hljs-flow, 47 | .apache .hljs-tag, 48 | .tex .hljs-command, 49 | .hljs-request, 50 | .hljs-status { 51 | font-weight: bold; 52 | } 53 | -------------------------------------------------------------------------------- /site/themes/hyde-x/LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2014 Andrei Mihu 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /src/swirl.app.src: -------------------------------------------------------------------------------- 1 | %% -*- tab-width: 4;erlang-indent-level: 4;indent-tabs-mode: nil -*- 2 | %% ex: ft=erlang ts=4 sw=4 et 3 | %% Licensed under the Apache License, Version 2.0 (the "License"); you may not 4 | %% use this file except in compliance with the License. You may obtain a copy of 5 | %% the License at 6 | %% 7 | %% http://www.apache.org/licenses/LICENSE-2.0 8 | %% 9 | %% Unless required by applicable law or agreed to in writing, software 10 | %% distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | %% WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | %% License for the specific language governing permissions and limitations under 13 | %% the License. 14 | 15 | {application, swirl, 16 | [ 17 | {description, "PPSP Protocol Streaming Peer Transport"}, 18 | {vsn, "v0.0.1"}, 19 | {id, "git"}, 20 | {modules, []}, 21 | {registered, [swirl_sup, peer_sup, swarm_sup, channel_sup]}, 22 | {applications, [ 23 | gproc, 24 | kernel, 25 | stdlib, 26 | sasl, 27 | crypto 28 | ]}, 29 | {mod, { swirl_app, []}}, 30 | {env, []} 31 | ]}. 32 | -------------------------------------------------------------------------------- /test/template_SUITE: -------------------------------------------------------------------------------- 1 | %% -*- tab-width: 4;erlang-indent-level: 4;indent-tabs-mode: nil -*- 2 | %% ex: ft=erlang ts=4 sw=4 et 3 | %% Licensed under the Apache License, Version 2.0 (the "License"); you may not 4 | %% use this file except in compliance with the License. You may obtain a copy of 5 | %% the License at 6 | %% 7 | %% http://www.apache.org/licenses/LICENSE-2.0 8 | %% 9 | %% Unless required by applicable law or agreed to in writing, software 10 | %% distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | %% WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | %% License for the specific language governing permissions and limitations under 13 | %% the License. 14 | 15 | %% @doc Swirl Tests. 16 | %% @end 17 | 18 | -module(_SUITE). 19 | -include("swirl.hrl"). 20 | -include_lib("common_test/include/ct.hrl"). 21 | 22 | -export([all/0]). 23 | -export([fu/1, 24 | baa/1 25 | ]). 26 | 27 | -spec all() -> [atom()]. 28 | all() -> [fu, 29 | baa 30 | ]. 31 | 32 | -spec fu(any()) -> true. 33 | fu(_Config) -> 34 | swirl:start(), 35 | true = ok. 36 | 37 | -spec baa(any()) -> true. 38 | baa(_Config) -> 39 | swirl:start(), 40 | ok = ok. 41 | -------------------------------------------------------------------------------- /site/layouts/root/headline.html: -------------------------------------------------------------------------------- 1 |
2 |
3 |
4 |
5 | 6 |

7 | Bringing Peer-to-Peer
8 | Streaming to the World.
9 |

10 |

11 | 12 | Making sharing and streaming as easy as taking a picture. 13 |

14 | 15 |
16 |
17 |
18 |
19 | 20 |
21 |
22 |
23 | 24 |
25 |

26 | Swirl Project

27 |

Static & live stream content for 28 | everybody — anywhere, any time, any device.

29 | 30 |
31 | 32 |
33 |
34 |
35 | 36 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/mono-blue.css: -------------------------------------------------------------------------------- 1 | /* 2 | Five-color theme from a single blue hue. 3 | */ 4 | .hljs { 5 | display: block; 6 | overflow-x: auto; 7 | padding: 0.5em; 8 | background: #eaeef3; 9 | -webkit-text-size-adjust: none; 10 | } 11 | 12 | .hljs, 13 | .hljs-list .hljs-built_in { 14 | color: #00193a; 15 | } 16 | 17 | .hljs-keyword, 18 | .hljs-title, 19 | .hljs-important, 20 | .hljs-request, 21 | .hljs-header, 22 | .hljs-doctag { 23 | font-weight: bold; 24 | } 25 | 26 | .hljs-comment, 27 | .hljs-chunk { 28 | color: #738191; 29 | } 30 | 31 | .hljs-string, 32 | .hljs-title, 33 | .hljs-parent, 34 | .hljs-built_in, 35 | .hljs-literal, 36 | .hljs-filename, 37 | .hljs-value, 38 | .hljs-addition, 39 | .hljs-tag, 40 | .hljs-argument, 41 | .hljs-link_label, 42 | .hljs-blockquote, 43 | .hljs-header, 44 | .hljs-name { 45 | color: #0048ab; 46 | } 47 | 48 | .hljs-decorator, 49 | .hljs-prompt, 50 | .hljs-subst, 51 | .hljs-symbol, 52 | .hljs-doctype, 53 | .hljs-regexp, 54 | .hljs-preprocessor, 55 | .hljs-pragma, 56 | .hljs-pi, 57 | .hljs-attribute, 58 | .hljs-attr_selector, 59 | .hljs-xmlDocTag, 60 | .hljs-deletion, 61 | .hljs-shebang, 62 | .hljs-string .hljs-variable, 63 | .hljs-link_url, 64 | .hljs-bullet, 65 | .hljs-sqbracket, 66 | .hljs-phony { 67 | color: #4c81c9; 68 | } 69 | -------------------------------------------------------------------------------- /doc/README.md: -------------------------------------------------------------------------------- 1 | # Swirl Documentation 2 | 3 | The [documentation] is written in markdown. The [raw pages] are located in 4 | `/doc/content/` in the git `develop` branch. We are using [Hugo] to generate 5 | both the website and the documentation directly from markdown source. 6 | 7 | The HTML for the [website] itself is stored in `/site/layouts/root/`, and the 8 | standard hugo [config] file `config.yaml` and the theme can be found in 9 | `/site/` directly. 10 | 11 | You can either build hugo from source, or more conveniently, download a static 12 | pre-built binary. Both are covered in Hugo's [installation guide]. 13 | 14 | [Hugo]: http://gohugo.io/ 15 | [installation guide]: http://gohugo.io/overview/installing/ 16 | 17 | To build, or re-build the documentation, simply run `make doc` or `make publish` 18 | to regenerate the docs. `publish` requires permissions to update the google 19 | storage site, if you don't have this, simply send a pull request to the project 20 | and we'll rebuild it when merging your contribution. 21 | 22 | [documentation]: http://www.swirl-project.org/content/about/ 23 | [raw pages]: https://github.com/skunkwerks/swirl/tree/develop/doc/content/ 24 | [website]: https://github.com/skunkwerks/swirl/tree/develop/site/layouts/root 25 | [config]: https://github.com/skunkwerks/swirl/blob/develop/site/config.yaml 26 | -------------------------------------------------------------------------------- /include/swirl.hrl: -------------------------------------------------------------------------------- 1 | %% -*- tab-width: 4;erlang-indent-level: 4;indent-tabs-mode: nil -*- 2 | %% ex: ft=erlang ts=4 sw=4 et 3 | %% Licensed under the Apache License, Version 2.0 (the "License"); you may not 4 | %% use this file except in compliance with the License. You may obtain a copy of 5 | %% the License at 6 | %% 7 | %% http://www.apache.org/licenses/LICENSE-2.0 8 | %% 9 | %% Unless required by applicable law or agreed to in writing, software 10 | %% distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | %% WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | %% License for the specific language governing permissions and limitations under 13 | %% the License. 14 | 15 | -include("ppspp.hrl"). 16 | -ifndef(SWIRL_PORT). 17 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 18 | %% application macros 19 | -define(SWIRL_PORT, 7777). 20 | -define(SWIRL_APP, swirl). 21 | 22 | %% maximum PPSP protocol version that swirl supports 23 | -define(SWIRL_MAX_PPSPP_VERSION, 1). 24 | 25 | -define(DEBUG(Format, Args), error_logger:info_msg(Format, Args)). 26 | -define(ERROR(Format, Args), error_logger:error_msg(Format, Args)). 27 | -define(WARN(Format, Args), error_logger:warning_msg(Format, Args)). 28 | -define(INFO(Format, Args), error_logger:info_msg(Format, Args)). 29 | 30 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 31 | -endif. 32 | -------------------------------------------------------------------------------- /site/themes/hyde-x/layouts/index.html: -------------------------------------------------------------------------------- 1 | {{ partial "head.html" . }} 2 |
3 |
4 | {{ $paginator := .Paginate (where .Data.Pages "Type" "post") }} 5 | {{ range $paginator.Pages }} 6 |
7 |

8 | {{ .Title }} 9 |

10 | 16 |

{{ .Description }}

17 | Read On → 18 |
19 | {{ end }} 20 | {{ template "_internal/pagination.html" . }} 21 |
22 |
23 | 24 | {{ with .Site.DisqusShortname }} 25 | 34 | {{ end }} 35 | {{ partial "foot.html" . }} -------------------------------------------------------------------------------- /test/ppspp_chunk_SUITE.erl: -------------------------------------------------------------------------------- 1 | %% -*- tab-width: 4;erlang-indent-level: 4;indent-tabs-mode: nil -*- 2 | %% ex: ft=erlang ts=4 sw=4 et 3 | %% Licensed under the Apache License, Version 2.0 (the "License"); you may not 4 | %% use this file except in compliance with the License. You may obtain a copy of 5 | %% the License at 6 | %% 7 | %% http://www.apache.org/licenses/LICENSE-2.0 8 | %% 9 | %% Unless required by applicable law or agreed to in writing, software 10 | %% distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | %% WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | %% License for the specific language governing permissions and limitations under 13 | %% the License. 14 | 15 | %% @doc Library for PPSPP over UDP, aka Swift protocol 16 | %%

This module implements a library of functions necessary to 17 | %% handle the wire-protocol of PPSPP over UDP, including 18 | %% functions for encoding and decoding messages.

19 | %% @end 20 | 21 | -module(ppspp_chunk_SUITE). 22 | -include("swirl.hrl"). 23 | -include_lib("common_test/include/ct.hrl"). 24 | 25 | -export([all/0]). 26 | -export([chunk/1]). 27 | 28 | -spec all() -> [atom()]. 29 | all() -> [chunk]. 30 | 31 | -spec chunk(any()) -> [any()]. 32 | chunk(_Config) -> 33 | ct:comment("ensure chunk parsing of wire format matches erlang term based format"), 34 | {ok, [Traces]} = file:consult("../../test/data/chunks.trace"), 35 | Test = fun({{Spec, Raw}, Expected}) -> 36 | Expected = ppspp_chunk:unpack(Spec, Raw) end, 37 | lists:map(Test, Traces). 38 | -------------------------------------------------------------------------------- /test/ppspp_have_SUITE.erl: -------------------------------------------------------------------------------- 1 | %% -*- tab-width: 4;erlang-indent-level: 4;indent-tabs-mode: nil -*- 2 | %% ex: ft=erlang ts=4 sw=4 et 3 | %% Licensed under the Apache License, Version 2.0 (the "License"); you may not 4 | %% use this file except in compliance with the License. You may obtain a copy of 5 | %% the License at 6 | %% 7 | %% http://www.apache.org/licenses/LICENSE-2.0 8 | %% 9 | %% Unless required by applicable law or agreed to in writing, software 10 | %% distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | %% WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | %% License for the specific language governing permissions and limitations under 13 | %% the License. 14 | 15 | %% @doc Library for PPSPP over UDP, aka Swift protocol 16 | %%

This module implements a library of functions necessary to 17 | %% handle the wire-protocol of PPSPP over UDP, including 18 | %% functions for encoding and decoding messages.

19 | %% @end 20 | 21 | -module(ppspp_have_SUITE). 22 | -include("swirl.hrl"). 23 | -include_lib("common_test/include/ct.hrl"). 24 | 25 | -export([all/0]). 26 | -export([have/1]). 27 | 28 | -spec all() -> [atom()]. 29 | all() -> [have]. 30 | 31 | -spec have(any()) -> [any()]. 32 | have(_Config) -> 33 | ct:comment("have: ensure parsing have() does not consume additional data"), 34 | %% have() is a thin wrapper around chunk handling 35 | Method = chunk_32bit_chunks, 36 | Garbage = crypto:strong_rand_bytes(10), 37 | Chunks = <<15:64, Garbage/binary>>, 38 | Expected = {#{chunk_32bit_chunks => {0,15}}, Garbage}, 39 | Expected = ppspp_have:unpack(Method, Chunks). 40 | -------------------------------------------------------------------------------- /test/data/haves.trace: -------------------------------------------------------------------------------- 1 | %% -*- tab-width: 4;erlang-indent-level: 4;indent-tabs-mode: nil -*- 2 | %% ex: ft=erlang ts=4 sw=4 et 3 | %% Licensed under the Apache License, Version 2.0 (the "License"); you may not 4 | %% use this file except in compliance with the License. You may obtain a copy of 5 | %% the License at 6 | %% 7 | %% http://www.apache.org/licenses/LICENSE-2.0 8 | %% 9 | %% Unless required by applicable law or agreed to in writing, software 10 | %% distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | %% WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | %% License for the specific language governing permissions and limitations under 13 | %% the License. 14 | %% TODO 15 | %% cover have of all, none, in each type 16 | %% check for 0xffffffff, 0xffffffffffffffff (empty or nothing) 17 | %% and 0x7fffffff, 0x7fffffffffffffff (everything) 18 | %% cover a range, a single chunk, invalid ranges 19 | %% chunk_32bit_bins 20 | %% chunk_64bit_bins 21 | %% chunk_64bit_bytes 22 | %% chunk_32bit_chunks 23 | %% chunk_64bit_chunks 24 | [{chunk_32bit_chunks, 25 | <<3,0,0,0,0,0,0,0,15>>, {chunk_32bit_chunks, 5, 6}}, 26 | {chunk_32bit_chunks, 27 | <<3,0,0,0,16,0,0,0,23>>, {chunk_32bit_chunks, 5, 6}}, 28 | {chunk_32bit_chunks, 29 | <<3,0,0,0,24,0,0,0,25>>, {chunk_32bit_chunks, 5, 6}}, 30 | {chunk_32bit_chunks, 31 | <<3,0,0,0,0,0,0,0,0>>, {chunk_32bit_chunks, 5, 6}}, 32 | {chunk_32bit_chunks, 33 | <<3,0,0,0,0,0,0,0,4>>, {chunk_32bit_chunks, 5, 6}}, 34 | {chunk_32bit_chunks, 35 | <<3,0,0,0,0,0,0,0,16>>, {chunk_32bit_chunks, 5, 6}}, 36 | {chunk_32bit_chunks, 37 | <<3,0,0,0,0,0,0,0,24>>, {chunk_32bit_chunks, 5, 6}} 38 | ]. 39 | -------------------------------------------------------------------------------- /test/ppspp_handshake_SUITE.erl: -------------------------------------------------------------------------------- 1 | %% -*- tab-width: 4;erlang-indent-level: 4;indent-tabs-mode: nil -*- 2 | %% ex: ft=erlang ts=4 sw=4 et 3 | %% Licensed under the Apache License, Version 2.0 (the "License"); you may not 4 | %% use this file except in compliance with the License. You may obtain a copy of 5 | %% the License at 6 | %% 7 | %% http://www.apache.org/licenses/LICENSE-2.0 8 | %% 9 | %% Unless required by applicable law or agreed to in writing, software 10 | %% distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | %% WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | %% License for the specific language governing permissions and limitations under 13 | %% the License. 14 | 15 | %% @doc Library for PPSPP over UDP, aka Swift protocol 16 | %%

This module implements a library of functions necessary to 17 | %% handle the wire-protocol of PPSPP over UDP, including 18 | %% functions for encoding and decoding messages.

19 | %% @end 20 | 21 | -module(ppspp_handshake_SUITE). 22 | -include("swirl.hrl"). 23 | -include_lib("common_test/include/ct.hrl"). 24 | 25 | -export([all/0]). 26 | -export([handshake/1]). 27 | 28 | -spec all() -> [atom()]. 29 | all() -> [handshake]. 30 | 31 | -spec handshake(any()) -> true. 32 | handshake(_Config) -> 33 | ct:comment("ensure handshake wire format matches erlang term based format"), 34 | {ok, [Traces]} = file:consult("../../test/data/handshakes.trace"), 35 | Root_Hash = <<200,152,0,191,200,46,208,30,214,227,191,213,64,140,81, 36 | 39,68,145,247,212>>, 37 | Test = fun({Raw, Expected}) -> 38 | Expected = ppspp_message:unpack(Raw, Root_Hash) end, 39 | lists:map(Test, Traces). 40 | 41 | -------------------------------------------------------------------------------- /test/data/chunks.trace: -------------------------------------------------------------------------------- 1 | %% -*- tab-width: 4;erlang-indent-level: 4;indent-tabs-mode: nil -*- 2 | %% ex: ft=erlang ts=4 sw=4 et 3 | %% Licensed under the Apache License, Version 2.0 (the "License"); you may not 4 | %% use this file except in compliance with the License. You may obtain a copy of 5 | %% the License at 6 | %% 7 | %% http://www.apache.org/licenses/LICENSE-2.0 8 | %% 9 | %% Unless required by applicable law or agreed to in writing, software 10 | %% distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | %% WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | %% License for the specific language governing permissions and limitations under 13 | %% the License. 14 | %% TODO 15 | %% cover have of all, none, in each type 16 | %% check for 0xffffffff, 0xffffffffffffffff (empty or nothing) 17 | %% and 0x7fffffff, 0x7fffffffffffffff (everything) 18 | %% cover a range, a single chunk, invalid ranges 19 | %% chunk_32bit_bins 20 | %% chunk_64bit_bins 21 | %% chunk_64bit_bytes 22 | %% chunk_32bit_chunks 23 | %% chunk_64bit_chunks 24 | [{{chunk_32bit_chunks,<<0,0,0,0,0,0,0,15>>}, 25 | {#{chunk_32bit_chunks => {0,15}},<<>>}}, 26 | {{chunk_32bit_chunks,<<0,0,0,16,0,0,0,23>>}, 27 | {#{chunk_32bit_chunks => {16,23}},<<>>}}, 28 | {{chunk_32bit_chunks,<<0,0,0,24,0,0,0,25>>}, 29 | {#{chunk_32bit_chunks => {24,25}},<<>>}}, 30 | {{chunk_32bit_chunks,<<0,0,0,0,0,0,0,0>>}, 31 | {#{chunk_32bit_chunks => {0,0}},<<>>}}, 32 | {{chunk_32bit_chunks,<<0,0,0,0,0,0,0,4>>}, 33 | {#{chunk_32bit_chunks => {0,4}},<<>>}}, 34 | {{chunk_32bit_chunks,<<0,0,0,0,0,0,0,16>>}, 35 | {#{chunk_32bit_chunks => {0,16}},<<>>}}, 36 | {{chunk_32bit_chunks,<<0,0,0,0,0,0,0,24>>}, 37 | {#{chunk_32bit_chunks => {0,24}},<<>>}}] 38 | . 39 | -------------------------------------------------------------------------------- /site/layouts/root/head.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | {{ .Site.Title }} — {{ .Site.Author.name }} 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /doc/content/about.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: About the Project 3 | description: Overview of the Project 4 | date: 2014-04-29 5 | tags: 6 | - overview 7 | menu: main 8 | weight: 0 9 | --- 10 | 11 | Swirl want to make sharing and streaming as easy as taking a picture. 12 | 13 | ## Broadcast Reliably 14 | 15 | Whether you're streaming a birthday or celebration from your phone, hosting the 16 | Olympics, or running a pay-per-view event, swirl has you covered. Its new, 17 | non-proprietary live streaming server & clients provide world-class reliability, 18 | using the legendary availability and low latency performance built into the 19 | Erlang/OTP platform. 20 | 21 | ## Start streaming now — or later 22 | 23 | Be first with the news. No need to wait for a broadcast or event to end, swirl 24 | lets you stream the moment you have the first frames on camera. But if you're 25 | late to the party, don't worry, you won't have missed a thing. Swirl is ready to 26 | kick off when you are — just pick up where you left off, on any device. 27 | 28 | ## Open & standard 29 | 30 | Unlike all those other tools, Swirl is both open source and open development, 31 | built on an open standard, with peer-to-peer scalability and fault-tolerance 32 | baked in from the beginning. 33 | 34 | The application is based on IETF RFC7574, or Peer-to-Peer Streaming Peer Protocol, 35 | known as PPSP normally. The protocol includes innovative features for fast 36 | streaming, security and performance, and is compatible with current network 37 | infrastructure without rearchitecting or forklift upgrades. 38 | 39 | ## More Information 40 | 41 | The menu on this page includes a link to the various components of Swirl. 42 | You will find it easiest to read them in order, at least initially, starting 43 | off with the [implementation]({{< relref "implementation.md" >}}) guide. 44 | -------------------------------------------------------------------------------- /test/data/handshakes.trace: -------------------------------------------------------------------------------- 1 | %% -*- tab-width: 4;erlang-indent-level: 4;indent-tabs-mode: nil -*- 2 | %% ex: ft=erlang ts=4 sw=4 et 3 | %% Licensed under the Apache License, Version 2.0 (the "License"); you may not 4 | %% use this file except in compliance with the License. You may obtain a copy of 5 | %% the License at 6 | %% 7 | %% http://www.apache.org/licenses/LICENSE-2.0 8 | %% 9 | %% Unless required by applicable law or agreed to in writing, software 10 | %% distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | %% WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | %% License for the specific language governing permissions and limitations under 13 | %% the License. 14 | %% 15 | %% the root hash used in a simple peer exchange of m74.jpg 16 | [{<<0,239,25,97,212,0,1,1,1,2,0,20,200,152,0,191,200,46,208,30,214,227,191,213 17 | ,64,140,81,39,68,145,247,212,3,1,4,0,6,2,255>>, 18 | [#{handshake => #{ 19 | channel => 4011418068, 20 | options => #{ 21 | chunk_addressing_method => chunk_32bit_chunks, 22 | content_integrity_check_method => merkle_hash_tree, 23 | merkle_hash_function => sha, 24 | minimum_version => 1, 25 | supported_version => 1, 26 | swarm_id => <<200,152,0,191,200,46,208,30,214,227,191,213,64,140,81, 27 | 39,68,145, 247,212>>}}}]}, 28 | 29 | {<<0,139,165,126,203,0,1,1,1,2,0,20,200,152,0,191,200,46,208,30,214,227,191, 30 | 213,64,140,81,39,68,145,247,212,3,1,4,0,6,2,255>>, 31 | [#{handshake => #{ 32 | channel => 2342878923, 33 | options => #{ 34 | chunk_addressing_method => chunk_32bit_chunks, 35 | content_integrity_check_method => merkle_hash_tree, 36 | merkle_hash_function => sha, 37 | minimum_version => 1, 38 | supported_version => 1, 39 | swarm_id => <<200,152,0,191,200,46,208,30,214,227,191,213,64,140,81, 40 | 39,68,145,247,212>>}}}]}]. 41 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/codepen-embed.css: -------------------------------------------------------------------------------- 1 | /* 2 | codepen.io Embed Theme 3 | Author: Justin Perry 4 | Original theme - https://github.com/chriskempson/tomorrow-theme 5 | */ 6 | 7 | .hljs { 8 | display: block; 9 | overflow-x: auto; 10 | padding: 0.5em; 11 | background: #222; 12 | color: #fff; 13 | font-family: Menlo, Monaco, 'Andale Mono', 'Lucida Console', 'Courier New', monospace; 14 | -webkit-text-size-adjust: none; 15 | } 16 | 17 | .hljs-comment, 18 | .hljs-title { 19 | color: #777; 20 | } 21 | 22 | .hljs-variable, 23 | .hljs-attribute, 24 | .hljs-tag, 25 | .hljs-regexp, 26 | .hljs-name, 27 | .ruby .constant, 28 | .xml .tag .title, 29 | .xml .pi, 30 | .xml .doctype, 31 | .html .doctype { 32 | color: #ab875d; 33 | } 34 | 35 | .css .value { 36 | color: #cd6a51; 37 | } 38 | 39 | .css .value .function, 40 | .css .value .string { 41 | color: #a67f59; 42 | } 43 | 44 | .css .value .number { 45 | color: #9b869c; 46 | } 47 | 48 | .css .id, 49 | .css .class, 50 | .css-pseudo, 51 | .css .selector, 52 | .css .tag { 53 | color: #dfc48c; 54 | } 55 | 56 | .hljs-number, 57 | .hljs-preprocessor, 58 | .hljs-built_in, 59 | .hljs-literal, 60 | .hljs-params, 61 | .hljs-constant { 62 | color: #ab875d; 63 | } 64 | 65 | .ruby .class .title, 66 | .css .rules .attribute { 67 | color: #9b869b; 68 | } 69 | 70 | .hljs-string, 71 | .hljs-value, 72 | .hljs-inheritance, 73 | .hljs-header, 74 | .ruby .symbol, 75 | .xml .cdata { 76 | color: #8f9c6c; 77 | } 78 | 79 | .css .hexcolor { 80 | color: #cd6a51; 81 | } 82 | 83 | .function, 84 | .python .decorator, 85 | .python .title, 86 | .ruby .function .title, 87 | .ruby .title .keyword, 88 | .perl .sub, 89 | .javascript .title, 90 | .coffeescript .title { 91 | color: #fff; 92 | } 93 | 94 | .hljs-keyword, 95 | .javascript .function { 96 | color: #8f9c6c; 97 | } 98 | -------------------------------------------------------------------------------- /site/themes/hyde-x/layouts/post/single.html: -------------------------------------------------------------------------------- 1 | {{ partial "head.html" . }} 2 |
3 |
4 |

{{ .Title }}

5 | 11 | {{ .Content }} 12 |
13 | {{ if .Site.DisqusShortname }}
{{ end }} 14 |
15 | 16 | {{ with .Site.DisqusShortname }} 17 | 26 | {{ end }} 27 | 28 | {{ with .Site.DisqusShortname }} 29 | 37 | 38 | comments powered by Disqus 39 | {{ end }} 40 | {{ partial "foot.html" . }} -------------------------------------------------------------------------------- /test/swarm_worker_SUITE.erl: -------------------------------------------------------------------------------- 1 | %% -*- tab-width: 4;erlang-indent-level: 4;indent-tabs-mode: nil -*- 2 | %% ex: ft=erlang ts=4 sw=4 et 3 | %% Licensed under the Apache License, Version 2.0 (the "License"); you may not 4 | %% use this file except in compliance with the License. You may obtain a copy of 5 | %% the License at 6 | %% 7 | %% http://www.apache.org/licenses/LICENSE-2.0 8 | %% 9 | %% Unless required by applicable law or agreed to in writing, software 10 | %% distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | %% WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | %% License for the specific language governing permissions and limitations under 13 | %% the License. 14 | 15 | %% @doc Library for PPSPP over UDP, aka Swift protocol 16 | %%

This module implements a library of functions necessary to 17 | %% handle the wire-protocol of PPSPP over UDP, including 18 | %% functions for encoding and decoding messages.

19 | %% @end 20 | 21 | -module(swarm_worker_SUITE). 22 | -include("swirl.hrl"). 23 | -include_lib("common_test/include/ct.hrl"). 24 | 25 | -export([all/0]). 26 | -export([start_swarm/1, 27 | stop_swarm/1 28 | ]). 29 | 30 | -spec all() -> [atom()]. 31 | all() -> [start_swarm, 32 | stop_swarm 33 | ]. 34 | 35 | -spec start_swarm(any()) -> true. 36 | start_swarm(_Config) -> 37 | swirl:start(), 38 | Swarm_Options = ppspp_options:use_default_options("c39e"), 39 | {ok, Worker} = swirl:start_swarm(Swarm_Options), 40 | timer:sleep(100), 41 | true = is_process_alive(Worker). 42 | 43 | -spec stop_swarm(any()) -> false. 44 | stop_swarm(_Config) -> 45 | Swarm_Options = ppspp_options:use_default_options("c39e"), 46 | Swarm_id = ppspp_options:get_swarm_id(Swarm_Options), 47 | {ok, Worker} = swarm_worker:where_is(Swarm_id), 48 | swirl:stop_swarm(Swarm_id), 49 | timer:sleep(100), 50 | false = is_process_alive(Worker). 51 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/tomorrow.css: -------------------------------------------------------------------------------- 1 | /* http://jmblog.github.com/color-themes-for-google-code-highlightjs */ 2 | 3 | /* Tomorrow Comment */ 4 | .hljs-comment { 5 | color: #8e908c; 6 | } 7 | 8 | /* Tomorrow Red */ 9 | .hljs-variable, 10 | .hljs-attribute, 11 | .hljs-tag, 12 | .hljs-regexp, 13 | .ruby .hljs-constant, 14 | .xml .hljs-tag .hljs-title, 15 | .xml .hljs-pi, 16 | .xml .hljs-doctype, 17 | .html .hljs-doctype, 18 | .css .hljs-id, 19 | .css .hljs-class, 20 | .css .hljs-pseudo { 21 | color: #c82829; 22 | } 23 | 24 | /* Tomorrow Orange */ 25 | .hljs-number, 26 | .hljs-preprocessor, 27 | .hljs-pragma, 28 | .hljs-built_in, 29 | .hljs-literal, 30 | .hljs-params, 31 | .hljs-constant { 32 | color: #f5871f; 33 | } 34 | 35 | /* Tomorrow Yellow */ 36 | .ruby .hljs-class .hljs-title, 37 | .css .hljs-rule .hljs-attribute { 38 | color: #eab700; 39 | } 40 | 41 | /* Tomorrow Green */ 42 | .hljs-string, 43 | .hljs-value, 44 | .hljs-inheritance, 45 | .hljs-header, 46 | .hljs-name, 47 | .ruby .hljs-symbol, 48 | .xml .hljs-cdata { 49 | color: #718c00; 50 | } 51 | 52 | /* Tomorrow Aqua */ 53 | .hljs-title, 54 | .css .hljs-hexcolor { 55 | color: #3e999f; 56 | } 57 | 58 | /* Tomorrow Blue */ 59 | .hljs-function, 60 | .python .hljs-decorator, 61 | .python .hljs-title, 62 | .ruby .hljs-function .hljs-title, 63 | .ruby .hljs-title .hljs-keyword, 64 | .perl .hljs-sub, 65 | .javascript .hljs-title, 66 | .coffeescript .hljs-title { 67 | color: #4271ae; 68 | } 69 | 70 | /* Tomorrow Purple */ 71 | .hljs-keyword, 72 | .javascript .hljs-function { 73 | color: #8959a8; 74 | } 75 | 76 | .hljs { 77 | display: block; 78 | overflow-x: auto; 79 | background: white; 80 | color: #4d4d4c; 81 | padding: 0.5em; 82 | -webkit-text-size-adjust: none; 83 | } 84 | 85 | .coffeescript .javascript, 86 | .javascript .xml, 87 | .tex .hljs-formula, 88 | .xml .javascript, 89 | .xml .vbscript, 90 | .xml .css, 91 | .xml .hljs-cdata { 92 | opacity: 0.5; 93 | } 94 | -------------------------------------------------------------------------------- /src/swirl_app.erl: -------------------------------------------------------------------------------- 1 | %% -*- tab-width: 4;erlang-indent-level: 4;indent-tabs-mode: nil -*- 2 | %% ex: ft=erlang ts=4 sw=4 et 3 | %% Licensed under the Apache License, Version 2.0 (the "License"); you may not 4 | %% use this file except in compliance with the License. You may obtain a copy of 5 | %% the License at 6 | %% 7 | %% http://www.apache.org/licenses/LICENSE-2.0 8 | %% 9 | %% Unless required by applicable law or agreed to in writing, software 10 | %% distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | %% WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | %% License for the specific language governing permissions and limitations under 13 | %% the License. 14 | 15 | %% @doc Library for PPSPP over UDP, aka Swift protocol 16 | %% 17 | %% This module implements a library of functions necessary to 18 | %% handle the wire-protocol of PPSPP over UDP, including 19 | %% functions for encoding and decoding messages. 20 | %% @end 21 | 22 | -module(swirl_app). 23 | -include("swirl.hrl"). 24 | 25 | -behaviour(application). 26 | 27 | %% api 28 | -export([version/0]). 29 | 30 | %% callbacks 31 | -export([start/2, 32 | stop/1]). 33 | 34 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 35 | %% api 36 | 37 | -spec version() -> {string(), string()}. 38 | version() -> 39 | %% id key is set in swirl.app.src during build phase 40 | {ok, Version} = application:get_key(swirl, id), 41 | {?PPSPP_RELEASE, Version}. 42 | 43 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 44 | %% callbacks 45 | 46 | %% used by application:start/1 47 | -spec start(_ ,_ ) -> {ok, pid()} | {error,_ }. 48 | start(_Type, _Start_Args) -> 49 | {Protocol, Version} = version(), 50 | ?INFO("swirl: protocol ~s~n", [Protocol]), 51 | ?INFO("swirl: version #~s~n", [Version]), 52 | swirl_sup:start_link(). 53 | 54 | -spec stop(_) -> ok. 55 | stop(_State) -> 56 | ok. 57 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/vs.css: -------------------------------------------------------------------------------- 1 | /* 2 | 3 | Visual Studio-like style based on original C# coloring by Jason Diamond 4 | 5 | */ 6 | .hljs { 7 | display: block; 8 | overflow-x: auto; 9 | padding: 0.5em; 10 | background: white; 11 | color: black; 12 | -webkit-text-size-adjust: none; 13 | } 14 | 15 | .hljs-comment, 16 | .hljs-annotation, 17 | .diff .hljs-header, 18 | .hljs-chunk, 19 | .apache .hljs-cbracket { 20 | color: #008000; 21 | } 22 | 23 | .hljs-keyword, 24 | .hljs-id, 25 | .hljs-built_in, 26 | .smalltalk .hljs-class, 27 | .hljs-winutils, 28 | .bash .hljs-variable, 29 | .tex .hljs-command, 30 | .hljs-request, 31 | .hljs-status, 32 | .nginx .hljs-title, 33 | .xml .hljs-tag, 34 | .xml .hljs-tag .hljs-value { 35 | color: #00f; 36 | } 37 | 38 | .hljs-string, 39 | .hljs-title, 40 | .hljs-parent, 41 | .hljs-tag .hljs-value, 42 | .hljs-rule .hljs-value, 43 | .ruby .hljs-symbol, 44 | .ruby .hljs-symbol .hljs-string, 45 | .hljs-template_tag, 46 | .django .hljs-variable, 47 | .hljs-addition, 48 | .hljs-flow, 49 | .hljs-stream, 50 | .apache .hljs-tag, 51 | .hljs-date, 52 | .tex .hljs-formula, 53 | .coffeescript .hljs-attribute, 54 | .hljs-name { 55 | color: #a31515; 56 | } 57 | 58 | .ruby .hljs-string, 59 | .hljs-decorator, 60 | .hljs-filter .hljs-argument, 61 | .hljs-localvars, 62 | .hljs-array, 63 | .hljs-attr_selector, 64 | .hljs-pseudo, 65 | .hljs-pi, 66 | .hljs-doctype, 67 | .hljs-deletion, 68 | .hljs-envvar, 69 | .hljs-shebang, 70 | .hljs-preprocessor, 71 | .hljs-pragma, 72 | .userType, 73 | .apache .hljs-sqbracket, 74 | .nginx .hljs-built_in, 75 | .tex .hljs-special, 76 | .hljs-prompt { 77 | color: #2b91af; 78 | } 79 | 80 | .hljs-doctag, 81 | .hljs-xmlDocTag { 82 | color: #808080; 83 | } 84 | 85 | .hljs-type, 86 | .hljs-typename { font-weight: bold; } 87 | 88 | .vhdl .hljs-string { color: #666666; } 89 | .vhdl .hljs-literal { color: #a31515; } 90 | .vhdl .hljs-attribute { color: #00b0e8; } 91 | 92 | .xml .hljs-attribute { color: #f00; } 93 | -------------------------------------------------------------------------------- /doc/content/url.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: PPSPP URL Draft 3 | description: A Proposed URL Specification for the PPSP Protocol 4 | categories: 5 | - overview 6 | - design 7 | date: 2015-06-24T13:28:19+02:00 8 | menu: main 9 | tags: 10 | - page 11 | - url 12 | weight: 100 13 | --- 14 | 15 | While there is no official PPSPP URL defined yet, the following 16 | simple structure has been used, based off a quick reading of 17 | [Guidelines for new URL Schemes](https://tools.ietf.org/html/rfc2718) and 18 | [URI Generic Syntax](https://tools.ietf.org/html/rfc3986). 19 | 20 | - `scheme`: defines the protocol in use, always `ppspp` 21 | - `authority`: the IP address and port `example.net:7777` 22 | - `path`: the root hash in use, or requested filename `c89800bf` or `messier74.jpg` 23 | - optional `query` string: supports passing swarm options such as: `content_integrity_protection_method=merkle_hash_tree &merkle_hash_tree_function=sha-256` 24 | 25 | The keys and values used for the optional query string are the lower-case 26 | versions, with whitespace replaced by underscores, of those referred to in 27 | [PPSPP section 7] (https://tools.ietf.org/html/rfc7574-12#section-7) and the canonical [PPSPP IANA registry](https://www.iana.org/assignments/ppspp/ppspp.xhtml). 28 | 29 | Some examples are: 30 | 31 | - using DNS name and IP Port transport address as authority, with root hash: [ppspp://example.net:7777/c89800bf](ppspp://example.net:7777/c89800bf) 32 | - same root hash with IPv6 address and UDP port: [ppspp://[2a01:4f8:200:12cf::2]:7777/c89800bf](ppspp://[2a01:4f8:200:12cf::2]:7777/c89800bf) 33 | - requesting a filename with complex swarm options: [ppspp://example.net:7777/messier74.jpg?content_integrity_protection_method=merkle_hash_tree&merkle_hash_tree_function=sha-256&chunk_addressing_method=32-bit_bins](ppspp://example.net:7777/messier74.jpg?content_integrity_protection_method=merkle_hash_tree&merkle_hash_tree_function=sha-256&chunk_addressing_method=32-bit_bins) 34 | 35 | Comments and suggestions to improve this are welcomed. 36 | -------------------------------------------------------------------------------- /src/convert.erl: -------------------------------------------------------------------------------- 1 | %% -*- tab-width: 4;erlang-indent-level: 4;indent-tabs-mode: nil -*- 2 | %% ex: ft=erlang ts=4 sw=4 et 3 | %% Licensed under the Apache License, Version 2.0 (the "License"); you may not 4 | %% use this file except in compliance with the License. You may obtain a copy of 5 | %% the License at 6 | %% 7 | %% http://www.apache.org/licenses/LICENSE-2.0 8 | %% 9 | %% Unless required by applicable law or agreed to in writing, software 10 | %% distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | %% WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | %% License for the specific language governing permissions and limitations under 13 | %% the License. 14 | 15 | %% @doc Conversion Helper Functions 16 | %% 17 | %% This module implements a set of helper functions to convert various 18 | %% erlang or binary formats to human-readable text. 19 | %% @end 20 | 21 | -module(convert). 22 | -include("swirl.hrl"). 23 | 24 | %% api 25 | -export([bin_to_hex/1, 26 | int_to_hex/1, 27 | bin_to_string/1, 28 | hex_string_to_padded_binary/1]). 29 | 30 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 31 | %% api 32 | 33 | -spec bin_to_hex(binary()) -> string(). 34 | bin_to_hex(Binary) when is_binary(Binary) -> 35 | lists:flatten([io_lib:format("~2.16.0b",[N]) || <> <= Binary]). 36 | 37 | -spec int_to_hex(non_neg_integer()) -> string(). 38 | int_to_hex(Int) when is_integer(Int), Int >=0, Int =< 16#ffffffff -> 39 | lists:flatten([io_lib:format("0x~8.16.0b",[Int])]). 40 | 41 | -spec bin_to_string(binary()) -> string(). 42 | bin_to_string(Binary) when is_binary(Binary) -> 43 | lists:flatten(["0x", bin_to_hex(Binary)]). 44 | 45 | -spec hex_string_to_padded_binary(string()) -> binary(). 46 | hex_string_to_padded_binary(String) when is_list(String) -> 47 | Bytes_Length = (length(String) + 1) div 2, 48 | {ok, [Int], []} = io_lib:fread("~16u", String), 49 | <>. 50 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/paraiso.dark.css: -------------------------------------------------------------------------------- 1 | /* 2 | Paraíso (dark) 3 | Created by Jan T. Sott (http://github.com/idleberg) 4 | Inspired by the art of Rubens LP (http://www.rubenslp.com.br) 5 | */ 6 | 7 | /* Paraíso Comment */ 8 | .hljs-comment, 9 | .hljs-title { 10 | color: #8d8687; 11 | } 12 | 13 | /* Paraíso Red */ 14 | .hljs-variable, 15 | .hljs-attribute, 16 | .hljs-tag, 17 | .hljs-regexp, 18 | .hljs-name, 19 | .ruby .hljs-constant, 20 | .xml .hljs-tag .hljs-title, 21 | .xml .hljs-pi, 22 | .xml .hljs-doctype, 23 | .html .hljs-doctype, 24 | .css .hljs-id, 25 | .css .hljs-class, 26 | .css .hljs-pseudo { 27 | color: #ef6155; 28 | } 29 | 30 | /* Paraíso Orange */ 31 | .hljs-number, 32 | .hljs-preprocessor, 33 | .hljs-built_in, 34 | .hljs-literal, 35 | .hljs-params, 36 | .hljs-constant { 37 | color: #f99b15; 38 | } 39 | 40 | /* Paraíso Yellow */ 41 | .ruby .hljs-class .hljs-title, 42 | .css .hljs-rule .hljs-attribute { 43 | color: #fec418; 44 | } 45 | 46 | /* Paraíso Green */ 47 | .hljs-string, 48 | .hljs-value, 49 | .hljs-inheritance, 50 | .hljs-header, 51 | .ruby .hljs-symbol, 52 | .xml .hljs-cdata { 53 | color: #48b685; 54 | } 55 | 56 | /* Paraíso Aqua */ 57 | .css .hljs-hexcolor { 58 | color: #5bc4bf; 59 | } 60 | 61 | /* Paraíso Blue */ 62 | .hljs-function, 63 | .python .hljs-decorator, 64 | .python .hljs-title, 65 | .ruby .hljs-function .hljs-title, 66 | .ruby .hljs-title .hljs-keyword, 67 | .perl .hljs-sub, 68 | .javascript .hljs-title, 69 | .coffeescript .hljs-title { 70 | color: #06b6ef; 71 | } 72 | 73 | /* Paraíso Purple */ 74 | .hljs-keyword, 75 | .javascript .hljs-function { 76 | color: #815ba4; 77 | } 78 | 79 | .hljs { 80 | display: block; 81 | overflow-x: auto; 82 | background: #2f1e2e; 83 | color: #a39e9b; 84 | padding: 0.5em; 85 | -webkit-text-size-adjust: none; 86 | } 87 | 88 | .coffeescript .javascript, 89 | .javascript .xml, 90 | .tex .hljs-formula, 91 | .xml .javascript, 92 | .xml .vbscript, 93 | .xml .css, 94 | .xml .hljs-cdata { 95 | opacity: 0.5; 96 | } 97 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/paraiso.light.css: -------------------------------------------------------------------------------- 1 | /* 2 | Paraíso (light) 3 | Created by Jan T. Sott (http://github.com/idleberg) 4 | Inspired by the art of Rubens LP (http://www.rubenslp.com.br) 5 | */ 6 | 7 | /* Paraíso Comment */ 8 | .hljs-comment, 9 | .hljs-title { 10 | color: #776e71; 11 | } 12 | 13 | /* Paraíso Red */ 14 | .hljs-variable, 15 | .hljs-attribute, 16 | .hljs-tag, 17 | .hljs-regexp, 18 | .hljs-name, 19 | .ruby .hljs-constant, 20 | .xml .hljs-tag .hljs-title, 21 | .xml .hljs-pi, 22 | .xml .hljs-doctype, 23 | .html .hljs-doctype, 24 | .css .hljs-id, 25 | .css .hljs-class, 26 | .css .hljs-pseudo { 27 | color: #ef6155; 28 | } 29 | 30 | /* Paraíso Orange */ 31 | .hljs-number, 32 | .hljs-preprocessor, 33 | .hljs-built_in, 34 | .hljs-literal, 35 | .hljs-params, 36 | .hljs-constant { 37 | color: #f99b15; 38 | } 39 | 40 | /* Paraíso Yellow */ 41 | .ruby .hljs-class .hljs-title, 42 | .css .hljs-rule .hljs-attribute { 43 | color: #fec418; 44 | } 45 | 46 | /* Paraíso Green */ 47 | .hljs-string, 48 | .hljs-value, 49 | .hljs-inheritance, 50 | .hljs-header, 51 | .ruby .hljs-symbol, 52 | .xml .hljs-cdata { 53 | color: #48b685; 54 | } 55 | 56 | /* Paraíso Aqua */ 57 | .css .hljs-hexcolor { 58 | color: #5bc4bf; 59 | } 60 | 61 | /* Paraíso Blue */ 62 | .hljs-function, 63 | .python .hljs-decorator, 64 | .python .hljs-title, 65 | .ruby .hljs-function .hljs-title, 66 | .ruby .hljs-title .hljs-keyword, 67 | .perl .hljs-sub, 68 | .javascript .hljs-title, 69 | .coffeescript .hljs-title { 70 | color: #06b6ef; 71 | } 72 | 73 | /* Paraíso Purple */ 74 | .hljs-keyword, 75 | .javascript .hljs-function { 76 | color: #815ba4; 77 | } 78 | 79 | .hljs { 80 | display: block; 81 | overflow-x: auto; 82 | background: #e7e9db; 83 | color: #4f424c; 84 | padding: 0.5em; 85 | -webkit-text-size-adjust: none; 86 | } 87 | 88 | .coffeescript .javascript, 89 | .javascript .xml, 90 | .tex .hljs-formula, 91 | .xml .javascript, 92 | .xml .vbscript, 93 | .xml .css, 94 | .xml .hljs-cdata { 95 | opacity: 0.5; 96 | } 97 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/kimbie.dark.css: -------------------------------------------------------------------------------- 1 | /* 2 | Name: Kimbie (dark) 3 | Author: Jan T. Sott 4 | License: Creative Commons Attribution-ShareAlike 4.0 Unported License 5 | URL: https://github.com/idleberg/Kimbie-highlight.js 6 | */ 7 | 8 | /* Kimbie Comment */ 9 | .hljs-comment, 10 | .hljs-title { 11 | color: #d6baad; 12 | } 13 | 14 | /* Kimbie Red */ 15 | .hljs-variable, 16 | .hljs-attribute, 17 | .hljs-tag, 18 | .hljs-regexp, 19 | .hljs-name, 20 | .ruby .hljs-constant, 21 | .xml .hljs-tag .hljs-title, 22 | .xml .hljs-pi, 23 | .xml .hljs-doctype, 24 | .html .hljs-doctype, 25 | .css .hljs-id, 26 | .css .hljs-class, 27 | .css .hljs-pseudo { 28 | color: #dc3958; 29 | } 30 | 31 | /* Kimbie Orange */ 32 | .hljs-number, 33 | .hljs-preprocessor, 34 | .hljs-built_in, 35 | .hljs-literal, 36 | .hljs-params, 37 | .hljs-constant { 38 | color: #f79a32; 39 | } 40 | 41 | /* Kimbie Yellow */ 42 | .ruby .hljs-class .hljs-title, 43 | .css .hljs-rule .hljs-attribute { 44 | color: #f06431; 45 | } 46 | 47 | /* Kimbie Green */ 48 | .hljs-string, 49 | .hljs-value, 50 | .hljs-inheritance, 51 | .hljs-header, 52 | .ruby .hljs-symbol, 53 | .xml .hljs-cdata { 54 | color: #889b4a; 55 | } 56 | 57 | /* Kimbie Aqua */ 58 | .css .hljs-hexcolor { 59 | color: #088649; 60 | } 61 | 62 | /* Kimbie Blue */ 63 | .hljs-function, 64 | .python .hljs-decorator, 65 | .python .hljs-title, 66 | .ruby .hljs-function .hljs-title, 67 | .ruby .hljs-title .hljs-keyword, 68 | .perl .hljs-sub, 69 | .javascript .hljs-title, 70 | .coffeescript .hljs-title { 71 | color: #8ab1b0; 72 | } 73 | 74 | /* Kimbie Purple */ 75 | .hljs-keyword, 76 | .javascript .hljs-function { 77 | color: #98676a; 78 | } 79 | 80 | .hljs { 81 | display: block; 82 | overflow-x: auto; 83 | background: #221a0f; 84 | color: #d3af86; 85 | padding: 0.5em; 86 | -webkit-text-size-adjust: none; 87 | } 88 | 89 | .coffeescript .javascript, 90 | .javascript .xml, 91 | .tex .hljs-formula, 92 | .xml .javascript, 93 | .xml .vbscript, 94 | .xml .css, 95 | .xml .hljs-cdata { 96 | opacity: 0.5; 97 | } 98 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/ir_black.css: -------------------------------------------------------------------------------- 1 | /* 2 | IR_Black style (c) Vasily Mikhailitchenko 3 | */ 4 | 5 | .hljs { 6 | display: block; 7 | overflow-x: auto; 8 | padding: 0.5em; 9 | background: #000; 10 | color: #f8f8f8; 11 | -webkit-text-size-adjust: none; 12 | } 13 | 14 | .hljs-shebang, 15 | .hljs-comment { 16 | color: #7c7c7c; 17 | } 18 | 19 | .hljs-keyword, 20 | .hljs-tag, 21 | .tex .hljs-command, 22 | .hljs-request, 23 | .hljs-status, 24 | .clojure .hljs-attribute { 25 | color: #96cbfe; 26 | } 27 | 28 | .hljs-sub .hljs-keyword, 29 | .method, 30 | .hljs-list .hljs-title, 31 | .nginx .hljs-title { 32 | color: #ffffb6; 33 | } 34 | 35 | .hljs-string, 36 | .hljs-tag .hljs-value, 37 | .hljs-cdata, 38 | .hljs-filter .hljs-argument, 39 | .hljs-attr_selector, 40 | .apache .hljs-cbracket, 41 | .hljs-date, 42 | .coffeescript .hljs-attribute { 43 | color: #a8ff60; 44 | } 45 | 46 | .hljs-subst { 47 | color: #daefa3; 48 | } 49 | 50 | .hljs-regexp { 51 | color: #e9c062; 52 | } 53 | 54 | .hljs-title, 55 | .hljs-sub .hljs-identifier, 56 | .hljs-pi, 57 | .hljs-decorator, 58 | .tex .hljs-special, 59 | .hljs-type, 60 | .hljs-constant, 61 | .smalltalk .hljs-class, 62 | .hljs-doctag, 63 | .nginx .hljs-built_in { 64 | color: #ffffb6; 65 | } 66 | 67 | .hljs-symbol, 68 | .ruby .hljs-symbol .hljs-string, 69 | .hljs-number, 70 | .hljs-variable, 71 | .vbscript, 72 | .hljs-literal, 73 | .hljs-name { 74 | color: #c6c5fe; 75 | } 76 | 77 | .css .hljs-tag { 78 | color: #96cbfe; 79 | } 80 | 81 | .css .hljs-rule .hljs-property, 82 | .css .hljs-id { 83 | color: #ffffb6; 84 | } 85 | 86 | .css .hljs-class { 87 | color: #fff; 88 | } 89 | 90 | .hljs-hexcolor { 91 | color: #c6c5fe; 92 | } 93 | 94 | .hljs-number { 95 | color:#ff73fd; 96 | } 97 | 98 | .coffeescript .javascript, 99 | .javascript .xml, 100 | .tex .hljs-formula, 101 | .xml .javascript, 102 | .xml .vbscript, 103 | .xml .css, 104 | .xml .hljs-cdata { 105 | opacity: 0.7; 106 | } 107 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/kimbie.light.css: -------------------------------------------------------------------------------- 1 | /* 2 | Name: Kimbie (light) 3 | Author: Jan T. Sott 4 | License: Creative Commons Attribution-ShareAlike 4.0 Unported License 5 | URL: https://github.com/idleberg/Kimbie-highlight.js 6 | */ 7 | 8 | /* Kimbie Comment */ 9 | .hljs-comment, 10 | .hljs-title { 11 | color: #a57a4c; 12 | } 13 | 14 | /* Kimbie Red */ 15 | .hljs-variable, 16 | .hljs-attribute, 17 | .hljs-tag, 18 | .hljs-regexp, 19 | .hljs-name, 20 | .ruby .hljs-constant, 21 | .xml .hljs-tag .hljs-title, 22 | .xml .hljs-pi, 23 | .xml .hljs-doctype, 24 | .html .hljs-doctype, 25 | .css .hljs-id, 26 | .css .hljs-class, 27 | .css .hljs-pseudo { 28 | color: #dc3958; 29 | } 30 | 31 | /* Kimbie Orange */ 32 | .hljs-number, 33 | .hljs-preprocessor, 34 | .hljs-built_in, 35 | .hljs-literal, 36 | .hljs-params, 37 | .hljs-constant { 38 | color: #f79a32; 39 | } 40 | 41 | /* Kimbie Yellow */ 42 | .ruby .hljs-class .hljs-title, 43 | .css .hljs-rule .hljs-attribute { 44 | color: #f06431; 45 | } 46 | 47 | /* Kimbie Green */ 48 | .hljs-string, 49 | .hljs-value, 50 | .hljs-inheritance, 51 | .hljs-header, 52 | .ruby .hljs-symbol, 53 | .xml .hljs-cdata { 54 | color: #889b4a; 55 | } 56 | 57 | /* Kimbie Aqua */ 58 | .css .hljs-hexcolor { 59 | color: #088649; 60 | } 61 | 62 | /* Kimbie Blue */ 63 | .hljs-function, 64 | .python .hljs-decorator, 65 | .python .hljs-title, 66 | .ruby .hljs-function .hljs-title, 67 | .ruby .hljs-title .hljs-keyword, 68 | .perl .hljs-sub, 69 | .javascript .hljs-title, 70 | .coffeescript .hljs-title { 71 | color: #8ab1b0; 72 | } 73 | 74 | /* Kimbie Purple */ 75 | .hljs-keyword, 76 | .javascript .hljs-function { 77 | color: #98676a; 78 | } 79 | 80 | .hljs { 81 | display: block; 82 | overflow-x: auto; 83 | background: #fbebd4; 84 | color: #84613d; 85 | padding: 0.5em; 86 | -webkit-text-size-adjust: none; 87 | } 88 | 89 | .coffeescript .javascript, 90 | .javascript .xml, 91 | .tex .hljs-formula, 92 | .xml .javascript, 93 | .xml .vbscript, 94 | .xml .css, 95 | .xml .hljs-cdata { 96 | opacity: 0.5; 97 | } 98 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/tomorrow-night-bright.css: -------------------------------------------------------------------------------- 1 | /* Tomorrow Night Bright Theme */ 2 | /* Original theme - https://github.com/chriskempson/tomorrow-theme */ 3 | /* http://jmblog.github.com/color-themes-for-google-code-highlightjs */ 4 | 5 | /* Tomorrow Comment */ 6 | .hljs-comment { 7 | color: #969896; 8 | } 9 | 10 | /* Tomorrow Red */ 11 | .hljs-variable, 12 | .hljs-attribute, 13 | .hljs-tag, 14 | .hljs-regexp, 15 | .ruby .hljs-constant, 16 | .xml .hljs-tag .hljs-title, 17 | .xml .hljs-pi, 18 | .xml .hljs-doctype, 19 | .html .hljs-doctype, 20 | .css .hljs-id, 21 | .css .hljs-class, 22 | .css .hljs-pseudo { 23 | color: #d54e53; 24 | } 25 | 26 | /* Tomorrow Orange */ 27 | .hljs-number, 28 | .hljs-preprocessor, 29 | .hljs-pragma, 30 | .hljs-built_in, 31 | .hljs-literal, 32 | .hljs-params, 33 | .hljs-constant { 34 | color: #e78c45; 35 | } 36 | 37 | /* Tomorrow Yellow */ 38 | .ruby .hljs-class .hljs-title, 39 | .css .hljs-rule .hljs-attribute { 40 | color: #e7c547; 41 | } 42 | 43 | /* Tomorrow Green */ 44 | .hljs-string, 45 | .hljs-value, 46 | .hljs-inheritance, 47 | .hljs-header, 48 | .hljs-name, 49 | .ruby .hljs-symbol, 50 | .xml .hljs-cdata { 51 | color: #b9ca4a; 52 | } 53 | 54 | /* Tomorrow Aqua */ 55 | .hljs-title, 56 | .css .hljs-hexcolor { 57 | color: #70c0b1; 58 | } 59 | 60 | /* Tomorrow Blue */ 61 | .hljs-function, 62 | .python .hljs-decorator, 63 | .python .hljs-title, 64 | .ruby .hljs-function .hljs-title, 65 | .ruby .hljs-title .hljs-keyword, 66 | .perl .hljs-sub, 67 | .javascript .hljs-title, 68 | .coffeescript .hljs-title { 69 | color: #7aa6da; 70 | } 71 | 72 | /* Tomorrow Purple */ 73 | .hljs-keyword, 74 | .javascript .hljs-function { 75 | color: #c397d8; 76 | } 77 | 78 | .hljs { 79 | display: block; 80 | overflow-x: auto; 81 | background: black; 82 | color: #eaeaea; 83 | padding: 0.5em; 84 | -webkit-text-size-adjust: none; 85 | } 86 | 87 | .coffeescript .javascript, 88 | .javascript .xml, 89 | .tex .hljs-formula, 90 | .xml .javascript, 91 | .xml .vbscript, 92 | .xml .css, 93 | .xml .hljs-cdata { 94 | opacity: 0.5; 95 | } 96 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/tomorrow-night-eighties.css: -------------------------------------------------------------------------------- 1 | /* Tomorrow Night Eighties Theme */ 2 | /* Original theme - https://github.com/chriskempson/tomorrow-theme */ 3 | /* http://jmblog.github.com/color-themes-for-google-code-highlightjs */ 4 | 5 | /* Tomorrow Comment */ 6 | .hljs-comment { 7 | color: #999999; 8 | } 9 | 10 | /* Tomorrow Red */ 11 | .hljs-variable, 12 | .hljs-attribute, 13 | .hljs-tag, 14 | .hljs-regexp, 15 | .ruby .hljs-constant, 16 | .xml .hljs-tag .hljs-title, 17 | .xml .hljs-pi, 18 | .xml .hljs-doctype, 19 | .html .hljs-doctype, 20 | .css .hljs-id, 21 | .css .hljs-class, 22 | .css .hljs-pseudo { 23 | color: #f2777a; 24 | } 25 | 26 | /* Tomorrow Orange */ 27 | .hljs-number, 28 | .hljs-preprocessor, 29 | .hljs-pragma, 30 | .hljs-built_in, 31 | .hljs-literal, 32 | .hljs-params, 33 | .hljs-constant { 34 | color: #f99157; 35 | } 36 | 37 | /* Tomorrow Yellow */ 38 | .ruby .hljs-class .hljs-title, 39 | .css .hljs-rule .hljs-attribute { 40 | color: #ffcc66; 41 | } 42 | 43 | /* Tomorrow Green */ 44 | .hljs-string, 45 | .hljs-value, 46 | .hljs-inheritance, 47 | .hljs-header, 48 | .hljs-name, 49 | .ruby .hljs-symbol, 50 | .xml .hljs-cdata { 51 | color: #99cc99; 52 | } 53 | 54 | /* Tomorrow Aqua */ 55 | .hljs-title, 56 | .css .hljs-hexcolor { 57 | color: #66cccc; 58 | } 59 | 60 | /* Tomorrow Blue */ 61 | .hljs-function, 62 | .python .hljs-decorator, 63 | .python .hljs-title, 64 | .ruby .hljs-function .hljs-title, 65 | .ruby .hljs-title .hljs-keyword, 66 | .perl .hljs-sub, 67 | .javascript .hljs-title, 68 | .coffeescript .hljs-title { 69 | color: #6699cc; 70 | } 71 | 72 | /* Tomorrow Purple */ 73 | .hljs-keyword, 74 | .javascript .hljs-function { 75 | color: #cc99cc; 76 | } 77 | 78 | .hljs { 79 | display: block; 80 | overflow-x: auto; 81 | background: #2d2d2d; 82 | color: #cccccc; 83 | padding: 0.5em; 84 | -webkit-text-size-adjust: none; 85 | } 86 | 87 | .coffeescript .javascript, 88 | .javascript .xml, 89 | .tex .hljs-formula, 90 | .xml .javascript, 91 | .xml .vbscript, 92 | .xml .css, 93 | .xml .hljs-cdata { 94 | opacity: 0.5; 95 | } 96 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/rainbow.css: -------------------------------------------------------------------------------- 1 | /* 2 | 3 | Style with support for rainbow parens 4 | 5 | */ 6 | 7 | .hljs { 8 | display: block; 9 | overflow-x: auto; 10 | padding: 0.5em; 11 | background: #474949; 12 | color: #d1d9e1; 13 | -webkit-text-size-adjust: none; 14 | } 15 | 16 | 17 | .hljs-body, 18 | .hljs-collection { 19 | color: #d1d9e1; 20 | } 21 | 22 | .hljs-comment, 23 | .diff .hljs-header, 24 | .hljs-doctype, 25 | .lisp .hljs-string { 26 | color: #969896; 27 | font-style: italic; 28 | } 29 | 30 | .hljs-keyword, 31 | .clojure .hljs-attribute, 32 | .hljs-winutils, 33 | .javascript .hljs-title, 34 | .hljs-addition, 35 | .css .hljs-tag { 36 | color: #cc99cc; 37 | } 38 | 39 | .hljs-number { color: #f99157; } 40 | 41 | .hljs-command, 42 | .hljs-string, 43 | .hljs-tag .hljs-value, 44 | .hljs-doctag, 45 | .tex .hljs-formula, 46 | .hljs-regexp, 47 | .hljs-hexcolor { 48 | color: #8abeb7; 49 | } 50 | 51 | .hljs-title, 52 | .hljs-localvars, 53 | .hljs-function .hljs-title, 54 | .hljs-chunk, 55 | .hljs-decorator, 56 | .hljs-built_in, 57 | .hljs-identifier { 58 | color: #b5bd68; 59 | } 60 | 61 | .hljs-class .hljs-keyword { 62 | color: #f2777a; 63 | } 64 | 65 | .hljs-variable, 66 | .smalltalk .hljs-number, 67 | .hljs-constant, 68 | .hljs-class .hljs-title, 69 | .hljs-parent, 70 | .haskell .hljs-label, 71 | .hljs-id, 72 | .hljs-name { 73 | color: #ffcc66; 74 | } 75 | 76 | .hljs-tag .hljs-title, 77 | .hljs-rule .hljs-property, 78 | .django .hljs-tag .hljs-keyword { 79 | font-weight: bold; 80 | } 81 | 82 | .hljs-attribute { 83 | color: #81a2be; 84 | } 85 | 86 | .hljs-preprocessor, 87 | .hljs-pragma, 88 | .hljs-pi, 89 | .hljs-shebang, 90 | .hljs-symbol, 91 | .hljs-symbol .hljs-string, 92 | .diff .hljs-change, 93 | .hljs-special, 94 | .hljs-attr_selector, 95 | .hljs-important, 96 | .hljs-subst, 97 | .hljs-cdata { 98 | color: #f99157; 99 | } 100 | 101 | .hljs-deletion { 102 | color: #dc322f; 103 | } 104 | 105 | .tex .hljs-formula { 106 | background: #eee8d5; 107 | } 108 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/atelier-dune.dark.css: -------------------------------------------------------------------------------- 1 | /* Base16 Atelier Dune Dark - Theme */ 2 | /* by Bram de Haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/dune) */ 3 | /* Original Base16 color scheme by Chris Kempson (https://github.com/chriskempson/base16) */ 4 | 5 | /* Atelier-Dune Comment */ 6 | .hljs-comment { 7 | color: #999580; 8 | } 9 | 10 | /* Atelier-Dune Red */ 11 | .hljs-variable, 12 | .hljs-attribute, 13 | .hljs-tag, 14 | .hljs-regexp, 15 | .hljs-name, 16 | .ruby .hljs-constant, 17 | .xml .hljs-tag .hljs-title, 18 | .xml .hljs-pi, 19 | .xml .hljs-doctype, 20 | .html .hljs-doctype, 21 | .css .hljs-id, 22 | .css .hljs-class, 23 | .css .hljs-pseudo { 24 | color: #d73737; 25 | } 26 | 27 | /* Atelier-Dune Orange */ 28 | .hljs-number, 29 | .hljs-preprocessor, 30 | .hljs-built_in, 31 | .hljs-literal, 32 | .hljs-params, 33 | .hljs-constant { 34 | color: #b65611; 35 | } 36 | 37 | /* Atelier-Dune Yellow */ 38 | .ruby .hljs-class .hljs-title, 39 | .css .hljs-rule .hljs-attribute { 40 | color: #ae9513; 41 | } 42 | 43 | /* Atelier-Dune Green */ 44 | .hljs-string, 45 | .hljs-value, 46 | .hljs-inheritance, 47 | .hljs-header, 48 | .ruby .hljs-symbol, 49 | .xml .hljs-cdata { 50 | color: #60ac39; 51 | } 52 | 53 | /* Atelier-Dune Aqua */ 54 | .hljs-title, 55 | .css .hljs-hexcolor { 56 | color: #1fad83; 57 | } 58 | 59 | /* Atelier-Dune Blue */ 60 | .hljs-function, 61 | .python .hljs-decorator, 62 | .python .hljs-title, 63 | .ruby .hljs-function .hljs-title, 64 | .ruby .hljs-title .hljs-keyword, 65 | .perl .hljs-sub, 66 | .javascript .hljs-title, 67 | .coffeescript .hljs-title { 68 | color: #6684e1; 69 | } 70 | 71 | /* Atelier-Dune Purple */ 72 | .hljs-keyword, 73 | .javascript .hljs-function { 74 | color: #b854d4; 75 | } 76 | 77 | .hljs { 78 | display: block; 79 | overflow-x: auto; 80 | background: #20201d; 81 | color: #a6a28c; 82 | padding: 0.5em; 83 | -webkit-text-size-adjust: none; 84 | } 85 | 86 | .coffeescript .javascript, 87 | .javascript .xml, 88 | .tex .hljs-formula, 89 | .xml .javascript, 90 | .xml .vbscript, 91 | .xml .css, 92 | .xml .hljs-cdata { 93 | opacity: 0.5; 94 | } 95 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/atelier-dune.light.css: -------------------------------------------------------------------------------- 1 | /* Base16 Atelier Dune Light - Theme */ 2 | /* by Bram de Haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/dune) */ 3 | /* Original Base16 color scheme by Chris Kempson (https://github.com/chriskempson/base16) */ 4 | 5 | /* Atelier-Dune Comment */ 6 | .hljs-comment { 7 | color: #7d7a68; 8 | } 9 | 10 | /* Atelier-Dune Red */ 11 | .hljs-variable, 12 | .hljs-attribute, 13 | .hljs-tag, 14 | .hljs-regexp, 15 | .hljs-name, 16 | .ruby .hljs-constant, 17 | .xml .hljs-tag .hljs-title, 18 | .xml .hljs-pi, 19 | .xml .hljs-doctype, 20 | .html .hljs-doctype, 21 | .css .hljs-id, 22 | .css .hljs-class, 23 | .css .hljs-pseudo { 24 | color: #d73737; 25 | } 26 | 27 | /* Atelier-Dune Orange */ 28 | .hljs-number, 29 | .hljs-preprocessor, 30 | .hljs-built_in, 31 | .hljs-literal, 32 | .hljs-params, 33 | .hljs-constant { 34 | color: #b65611; 35 | } 36 | 37 | /* Atelier-Dune Yellow */ 38 | .ruby .hljs-class .hljs-title, 39 | .css .hljs-rule .hljs-attribute { 40 | color: #ae9513; 41 | } 42 | 43 | /* Atelier-Dune Green */ 44 | .hljs-string, 45 | .hljs-value, 46 | .hljs-inheritance, 47 | .hljs-header, 48 | .ruby .hljs-symbol, 49 | .xml .hljs-cdata { 50 | color: #60ac39; 51 | } 52 | 53 | /* Atelier-Dune Aqua */ 54 | .hljs-title, 55 | .css .hljs-hexcolor { 56 | color: #1fad83; 57 | } 58 | 59 | /* Atelier-Dune Blue */ 60 | .hljs-function, 61 | .python .hljs-decorator, 62 | .python .hljs-title, 63 | .ruby .hljs-function .hljs-title, 64 | .ruby .hljs-title .hljs-keyword, 65 | .perl .hljs-sub, 66 | .javascript .hljs-title, 67 | .coffeescript .hljs-title { 68 | color: #6684e1; 69 | } 70 | 71 | /* Atelier-Dune Purple */ 72 | .hljs-keyword, 73 | .javascript .hljs-function { 74 | color: #b854d4; 75 | } 76 | 77 | .hljs { 78 | display: block; 79 | overflow-x: auto; 80 | background: #fefbec; 81 | color: #6e6b5e; 82 | padding: 0.5em; 83 | -webkit-text-size-adjust: none; 84 | } 85 | 86 | .coffeescript .javascript, 87 | .javascript .xml, 88 | .tex .hljs-formula, 89 | .xml .javascript, 90 | .xml .vbscript, 91 | .xml .css, 92 | .xml .hljs-cdata { 93 | opacity: 0.5; 94 | } 95 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/tomorrow-night.css: -------------------------------------------------------------------------------- 1 | /* Tomorrow Night Theme */ 2 | /* http://jmblog.github.com/color-themes-for-google-code-highlightjs */ 3 | /* Original theme - https://github.com/chriskempson/tomorrow-theme */ 4 | /* http://jmblog.github.com/color-themes-for-google-code-highlightjs */ 5 | 6 | /* Tomorrow Comment */ 7 | .hljs-comment { 8 | color: #969896; 9 | } 10 | 11 | /* Tomorrow Red */ 12 | .hljs-variable, 13 | .hljs-attribute, 14 | .hljs-tag, 15 | .hljs-regexp, 16 | .ruby .hljs-constant, 17 | .xml .hljs-tag .hljs-title, 18 | .xml .hljs-pi, 19 | .xml .hljs-doctype, 20 | .html .hljs-doctype, 21 | .css .hljs-id, 22 | .css .hljs-class, 23 | .css .hljs-pseudo { 24 | color: #cc6666; 25 | } 26 | 27 | /* Tomorrow Orange */ 28 | .hljs-number, 29 | .hljs-preprocessor, 30 | .hljs-pragma, 31 | .hljs-built_in, 32 | .hljs-literal, 33 | .hljs-params, 34 | .hljs-constant { 35 | color: #de935f; 36 | } 37 | 38 | /* Tomorrow Yellow */ 39 | .ruby .hljs-class .hljs-title, 40 | .css .hljs-rule .hljs-attribute { 41 | color: #f0c674; 42 | } 43 | 44 | /* Tomorrow Green */ 45 | .hljs-string, 46 | .hljs-value, 47 | .hljs-inheritance, 48 | .hljs-header, 49 | .hljs-name, 50 | .ruby .hljs-symbol, 51 | .xml .hljs-cdata { 52 | color: #b5bd68; 53 | } 54 | 55 | /* Tomorrow Aqua */ 56 | .hljs-title, 57 | .css .hljs-hexcolor { 58 | color: #8abeb7; 59 | } 60 | 61 | /* Tomorrow Blue */ 62 | .hljs-function, 63 | .python .hljs-decorator, 64 | .python .hljs-title, 65 | .ruby .hljs-function .hljs-title, 66 | .ruby .hljs-title .hljs-keyword, 67 | .perl .hljs-sub, 68 | .javascript .hljs-title, 69 | .coffeescript .hljs-title { 70 | color: #81a2be; 71 | } 72 | 73 | /* Tomorrow Purple */ 74 | .hljs-keyword, 75 | .javascript .hljs-function { 76 | color: #b294bb; 77 | } 78 | 79 | .hljs { 80 | display: block; 81 | overflow-x: auto; 82 | background: #1d1f21; 83 | color: #c5c8c6; 84 | padding: 0.5em; 85 | -webkit-text-size-adjust: none; 86 | } 87 | 88 | .coffeescript .javascript, 89 | .javascript .xml, 90 | .tex .hljs-formula, 91 | .xml .javascript, 92 | .xml .vbscript, 93 | .xml .css, 94 | .xml .hljs-cdata { 95 | opacity: 0.5; 96 | } 97 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/atelier-heath.dark.css: -------------------------------------------------------------------------------- 1 | /* Base16 Atelier Heath Dark - Theme */ 2 | /* by Bram de Haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/heath) */ 3 | /* Original Base16 color scheme by Chris Kempson (https://github.com/chriskempson/base16) */ 4 | 5 | /* Atelier-Heath Comment */ 6 | .hljs-comment { 7 | color: #9e8f9e; 8 | } 9 | 10 | /* Atelier-Heath Red */ 11 | .hljs-variable, 12 | .hljs-attribute, 13 | .hljs-tag, 14 | .hljs-regexp, 15 | .hljs-name, 16 | .ruby .hljs-constant, 17 | .xml .hljs-tag .hljs-title, 18 | .xml .hljs-pi, 19 | .xml .hljs-doctype, 20 | .html .hljs-doctype, 21 | .css .hljs-id, 22 | .css .hljs-class, 23 | .css .hljs-pseudo { 24 | color: #ca402b; 25 | } 26 | 27 | /* Atelier-Heath Orange */ 28 | .hljs-number, 29 | .hljs-preprocessor, 30 | .hljs-built_in, 31 | .hljs-literal, 32 | .hljs-params, 33 | .hljs-constant { 34 | color: #a65926; 35 | } 36 | 37 | /* Atelier-Heath Yellow */ 38 | .ruby .hljs-class .hljs-title, 39 | .css .hljs-rule .hljs-attribute { 40 | color: #bb8a35; 41 | } 42 | 43 | /* Atelier-Heath Green */ 44 | .hljs-string, 45 | .hljs-value, 46 | .hljs-inheritance, 47 | .hljs-header, 48 | .ruby .hljs-symbol, 49 | .xml .hljs-cdata { 50 | color: #918b3b; 51 | } 52 | 53 | /* Atelier-Heath Aqua */ 54 | .hljs-title, 55 | .css .hljs-hexcolor { 56 | color: #159393; 57 | } 58 | 59 | /* Atelier-Heath Blue */ 60 | .hljs-function, 61 | .python .hljs-decorator, 62 | .python .hljs-title, 63 | .ruby .hljs-function .hljs-title, 64 | .ruby .hljs-title .hljs-keyword, 65 | .perl .hljs-sub, 66 | .javascript .hljs-title, 67 | .coffeescript .hljs-title { 68 | color: #516aec; 69 | } 70 | 71 | /* Atelier-Heath Purple */ 72 | .hljs-keyword, 73 | .javascript .hljs-function { 74 | color: #7b59c0; 75 | } 76 | 77 | .hljs { 78 | display: block; 79 | overflow-x: auto; 80 | background: #1b181b; 81 | color: #ab9bab; 82 | padding: 0.5em; 83 | -webkit-text-size-adjust: none; 84 | } 85 | 86 | .coffeescript .javascript, 87 | .javascript .xml, 88 | .tex .hljs-formula, 89 | .xml .javascript, 90 | .xml .vbscript, 91 | .xml .css, 92 | .xml .hljs-cdata { 93 | opacity: 0.5; 94 | } 95 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/atelier-heath.light.css: -------------------------------------------------------------------------------- 1 | /* Base16 Atelier Heath Light - Theme */ 2 | /* by Bram de Haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/heath) */ 3 | /* Original Base16 color scheme by Chris Kempson (https://github.com/chriskempson/base16) */ 4 | 5 | /* Atelier-Heath Comment */ 6 | .hljs-comment { 7 | color: #776977; 8 | } 9 | 10 | /* Atelier-Heath Red */ 11 | .hljs-variable, 12 | .hljs-attribute, 13 | .hljs-tag, 14 | .hljs-regexp, 15 | .hljs-name, 16 | .ruby .hljs-constant, 17 | .xml .hljs-tag .hljs-title, 18 | .xml .hljs-pi, 19 | .xml .hljs-doctype, 20 | .html .hljs-doctype, 21 | .css .hljs-id, 22 | .css .hljs-class, 23 | .css .hljs-pseudo { 24 | color: #ca402b; 25 | } 26 | 27 | /* Atelier-Heath Orange */ 28 | .hljs-number, 29 | .hljs-preprocessor, 30 | .hljs-built_in, 31 | .hljs-literal, 32 | .hljs-params, 33 | .hljs-constant { 34 | color: #a65926; 35 | } 36 | 37 | /* Atelier-Heath Yellow */ 38 | .ruby .hljs-class .hljs-title, 39 | .css .hljs-rule .hljs-attribute { 40 | color: #bb8a35; 41 | } 42 | 43 | /* Atelier-Heath Green */ 44 | .hljs-string, 45 | .hljs-value, 46 | .hljs-inheritance, 47 | .hljs-header, 48 | .ruby .hljs-symbol, 49 | .xml .hljs-cdata { 50 | color: #918b3b; 51 | } 52 | 53 | /* Atelier-Heath Aqua */ 54 | .hljs-title, 55 | .css .hljs-hexcolor { 56 | color: #159393; 57 | } 58 | 59 | /* Atelier-Heath Blue */ 60 | .hljs-function, 61 | .python .hljs-decorator, 62 | .python .hljs-title, 63 | .ruby .hljs-function .hljs-title, 64 | .ruby .hljs-title .hljs-keyword, 65 | .perl .hljs-sub, 66 | .javascript .hljs-title, 67 | .coffeescript .hljs-title { 68 | color: #516aec; 69 | } 70 | 71 | /* Atelier-Heath Purple */ 72 | .hljs-keyword, 73 | .javascript .hljs-function { 74 | color: #7b59c0; 75 | } 76 | 77 | .hljs { 78 | display: block; 79 | overflow-x: auto; 80 | background: #f7f3f7; 81 | color: #695d69; 82 | padding: 0.5em; 83 | -webkit-text-size-adjust: none; 84 | } 85 | 86 | .coffeescript .javascript, 87 | .javascript .xml, 88 | .tex .hljs-formula, 89 | .xml .javascript, 90 | .xml .vbscript, 91 | .xml .css, 92 | .xml .hljs-cdata { 93 | opacity: 0.5; 94 | } 95 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/tomorrow-night-blue.css: -------------------------------------------------------------------------------- 1 | /* Tomorrow Night Blue Theme */ 2 | /* http://jmblog.github.com/color-themes-for-google-code-highlightjs */ 3 | /* Original theme - https://github.com/chriskempson/tomorrow-theme */ 4 | /* http://jmblog.github.com/color-themes-for-google-code-highlightjs */ 5 | 6 | /* Tomorrow Comment */ 7 | .hljs-comment { 8 | color: #7285b7; 9 | } 10 | 11 | /* Tomorrow Red */ 12 | .hljs-variable, 13 | .hljs-attribute, 14 | .hljs-tag, 15 | .hljs-regexp, 16 | .ruby .hljs-constant, 17 | .xml .hljs-tag .hljs-title, 18 | .xml .hljs-pi, 19 | .xml .hljs-doctype, 20 | .html .hljs-doctype, 21 | .css .hljs-id, 22 | .css .hljs-class, 23 | .css .hljs-pseudo { 24 | color: #ff9da4; 25 | } 26 | 27 | /* Tomorrow Orange */ 28 | .hljs-number, 29 | .hljs-preprocessor, 30 | .hljs-pragma, 31 | .hljs-built_in, 32 | .hljs-literal, 33 | .hljs-params, 34 | .hljs-constant { 35 | color: #ffc58f; 36 | } 37 | 38 | /* Tomorrow Yellow */ 39 | .ruby .hljs-class .hljs-title, 40 | .css .hljs-rule .hljs-attribute { 41 | color: #ffeead; 42 | } 43 | 44 | /* Tomorrow Green */ 45 | .hljs-string, 46 | .hljs-value, 47 | .hljs-inheritance, 48 | .hljs-header, 49 | .hljs-name, 50 | .ruby .hljs-symbol, 51 | .xml .hljs-cdata { 52 | color: #d1f1a9; 53 | } 54 | 55 | /* Tomorrow Aqua */ 56 | .hljs-title, 57 | .css .hljs-hexcolor { 58 | color: #99ffff; 59 | } 60 | 61 | /* Tomorrow Blue */ 62 | .hljs-function, 63 | .python .hljs-decorator, 64 | .python .hljs-title, 65 | .ruby .hljs-function .hljs-title, 66 | .ruby .hljs-title .hljs-keyword, 67 | .perl .hljs-sub, 68 | .javascript .hljs-title, 69 | .coffeescript .hljs-title { 70 | color: #bbdaff; 71 | } 72 | 73 | /* Tomorrow Purple */ 74 | .hljs-keyword, 75 | .javascript .hljs-function { 76 | color: #ebbbff; 77 | } 78 | 79 | .hljs { 80 | display: block; 81 | overflow-x: auto; 82 | background: #002451; 83 | color: white; 84 | padding: 0.5em; 85 | -webkit-text-size-adjust: none; 86 | } 87 | 88 | .coffeescript .javascript, 89 | .javascript .xml, 90 | .tex .hljs-formula, 91 | .xml .javascript, 92 | .xml .vbscript, 93 | .xml .css, 94 | .xml .hljs-cdata { 95 | opacity: 0.5; 96 | } 97 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/atelier-forest.dark.css: -------------------------------------------------------------------------------- 1 | /* Base16 Atelier Forest Dark - Theme */ 2 | /* by Bram de Haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/forest) */ 3 | /* Original Base16 color scheme by Chris Kempson (https://github.com/chriskempson/base16) */ 4 | 5 | /* Atelier-Forest Comment */ 6 | .hljs-comment { 7 | color: #9c9491; 8 | } 9 | 10 | /* Atelier-Forest Red */ 11 | .hljs-variable, 12 | .hljs-attribute, 13 | .hljs-tag, 14 | .hljs-regexp, 15 | .hljs-name, 16 | .ruby .hljs-constant, 17 | .xml .hljs-tag .hljs-title, 18 | .xml .hljs-pi, 19 | .xml .hljs-doctype, 20 | .html .hljs-doctype, 21 | .css .hljs-id, 22 | .css .hljs-class, 23 | .css .hljs-pseudo { 24 | color: #f22c40; 25 | } 26 | 27 | /* Atelier-Forest Orange */ 28 | .hljs-number, 29 | .hljs-preprocessor, 30 | .hljs-built_in, 31 | .hljs-literal, 32 | .hljs-params, 33 | .hljs-constant { 34 | color: #df5320; 35 | } 36 | 37 | /* Atelier-Forest Yellow */ 38 | .ruby .hljs-class .hljs-title, 39 | .css .hljs-rule .hljs-attribute { 40 | color: #c38418; 41 | } 42 | 43 | /* Atelier-Forest Green */ 44 | .hljs-string, 45 | .hljs-value, 46 | .hljs-inheritance, 47 | .hljs-header, 48 | .ruby .hljs-symbol, 49 | .xml .hljs-cdata { 50 | color: #7b9726; 51 | } 52 | 53 | /* Atelier-Forest Aqua */ 54 | .hljs-title, 55 | .css .hljs-hexcolor { 56 | color: #3d97b8; 57 | } 58 | 59 | /* Atelier-Forest Blue */ 60 | .hljs-function, 61 | .python .hljs-decorator, 62 | .python .hljs-title, 63 | .ruby .hljs-function .hljs-title, 64 | .ruby .hljs-title .hljs-keyword, 65 | .perl .hljs-sub, 66 | .javascript .hljs-title, 67 | .coffeescript .hljs-title { 68 | color: #407ee7; 69 | } 70 | 71 | /* Atelier-Forest Purple */ 72 | .hljs-keyword, 73 | .javascript .hljs-function { 74 | color: #6666ea; 75 | } 76 | 77 | .hljs { 78 | display: block; 79 | overflow-x: auto; 80 | background: #1b1918; 81 | color: #a8a19f; 82 | padding: 0.5em; 83 | -webkit-text-size-adjust: none; 84 | } 85 | 86 | .coffeescript .javascript, 87 | .javascript .xml, 88 | .tex .hljs-formula, 89 | .xml .javascript, 90 | .xml .vbscript, 91 | .xml .css, 92 | .xml .hljs-cdata { 93 | opacity: 0.5; 94 | } 95 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/atelier-forest.light.css: -------------------------------------------------------------------------------- 1 | /* Base16 Atelier Forest Light - Theme */ 2 | /* by Bram de Haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/forest) */ 3 | /* Original Base16 color scheme by Chris Kempson (https://github.com/chriskempson/base16) */ 4 | 5 | /* Atelier-Forest Comment */ 6 | .hljs-comment { 7 | color: #766e6b; 8 | } 9 | 10 | /* Atelier-Forest Red */ 11 | .hljs-variable, 12 | .hljs-attribute, 13 | .hljs-tag, 14 | .hljs-regexp, 15 | .hljs-name, 16 | .ruby .hljs-constant, 17 | .xml .hljs-tag .hljs-title, 18 | .xml .hljs-pi, 19 | .xml .hljs-doctype, 20 | .html .hljs-doctype, 21 | .css .hljs-id, 22 | .css .hljs-class, 23 | .css .hljs-pseudo { 24 | color: #f22c40; 25 | } 26 | 27 | /* Atelier-Forest Orange */ 28 | .hljs-number, 29 | .hljs-preprocessor, 30 | .hljs-built_in, 31 | .hljs-literal, 32 | .hljs-params, 33 | .hljs-constant { 34 | color: #df5320; 35 | } 36 | 37 | /* Atelier-Forest Yellow */ 38 | .ruby .hljs-class .hljs-title, 39 | .css .hljs-rule .hljs-attribute { 40 | color: #c38418; 41 | } 42 | 43 | /* Atelier-Forest Green */ 44 | .hljs-string, 45 | .hljs-value, 46 | .hljs-inheritance, 47 | .hljs-header, 48 | .ruby .hljs-symbol, 49 | .xml .hljs-cdata { 50 | color: #7b9726; 51 | } 52 | 53 | /* Atelier-Forest Aqua */ 54 | .hljs-title, 55 | .css .hljs-hexcolor { 56 | color: #3d97b8; 57 | } 58 | 59 | /* Atelier-Forest Blue */ 60 | .hljs-function, 61 | .python .hljs-decorator, 62 | .python .hljs-title, 63 | .ruby .hljs-function .hljs-title, 64 | .ruby .hljs-title .hljs-keyword, 65 | .perl .hljs-sub, 66 | .javascript .hljs-title, 67 | .coffeescript .hljs-title { 68 | color: #407ee7; 69 | } 70 | 71 | /* Atelier-Forest Purple */ 72 | .hljs-keyword, 73 | .javascript .hljs-function { 74 | color: #6666ea; 75 | } 76 | 77 | .hljs { 78 | display: block; 79 | overflow-x: auto; 80 | background: #f1efee; 81 | color: #68615e; 82 | padding: 0.5em; 83 | -webkit-text-size-adjust: none; 84 | } 85 | 86 | .coffeescript .javascript, 87 | .javascript .xml, 88 | .tex .hljs-formula, 89 | .xml .javascript, 90 | .xml .vbscript, 91 | .xml .css, 92 | .xml .hljs-cdata { 93 | opacity: 0.5; 94 | } 95 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/atelier-seaside.dark.css: -------------------------------------------------------------------------------- 1 | /* Base16 Atelier Seaside Dark - Theme */ 2 | /* by Bram de Haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/seaside) */ 3 | /* Original Base16 color scheme by Chris Kempson (https://github.com/chriskempson/base16) */ 4 | 5 | /* Atelier-Seaside Comment */ 6 | .hljs-comment { 7 | color: #809980; 8 | } 9 | 10 | /* Atelier-Seaside Red */ 11 | .hljs-variable, 12 | .hljs-attribute, 13 | .hljs-tag, 14 | .hljs-regexp, 15 | .hljs-name, 16 | .ruby .hljs-constant, 17 | .xml .hljs-tag .hljs-title, 18 | .xml .hljs-pi, 19 | .xml .hljs-doctype, 20 | .html .hljs-doctype, 21 | .css .hljs-id, 22 | .css .hljs-class, 23 | .css .hljs-pseudo { 24 | color: #e6193c; 25 | } 26 | 27 | /* Atelier-Seaside Orange */ 28 | .hljs-number, 29 | .hljs-preprocessor, 30 | .hljs-built_in, 31 | .hljs-literal, 32 | .hljs-params, 33 | .hljs-constant { 34 | color: #87711d; 35 | } 36 | 37 | /* Atelier-Seaside Yellow */ 38 | .ruby .hljs-class .hljs-title, 39 | .css .hljs-rule .hljs-attribute { 40 | color: #98981b; 41 | } 42 | 43 | /* Atelier-Seaside Green */ 44 | .hljs-string, 45 | .hljs-value, 46 | .hljs-inheritance, 47 | .hljs-header, 48 | .ruby .hljs-symbol, 49 | .xml .hljs-cdata { 50 | color: #29a329; 51 | } 52 | 53 | /* Atelier-Seaside Aqua */ 54 | .hljs-title, 55 | .css .hljs-hexcolor { 56 | color: #1999b3; 57 | } 58 | 59 | /* Atelier-Seaside Blue */ 60 | .hljs-function, 61 | .python .hljs-decorator, 62 | .python .hljs-title, 63 | .ruby .hljs-function .hljs-title, 64 | .ruby .hljs-title .hljs-keyword, 65 | .perl .hljs-sub, 66 | .javascript .hljs-title, 67 | .coffeescript .hljs-title { 68 | color: #3d62f5; 69 | } 70 | 71 | /* Atelier-Seaside Purple */ 72 | .hljs-keyword, 73 | .javascript .hljs-function { 74 | color: #ad2bee; 75 | } 76 | 77 | .hljs { 78 | display: block; 79 | overflow-x: auto; 80 | background: #131513; 81 | color: #8ca68c; 82 | padding: 0.5em; 83 | -webkit-text-size-adjust: none; 84 | } 85 | 86 | .coffeescript .javascript, 87 | .javascript .xml, 88 | .tex .hljs-formula, 89 | .xml .javascript, 90 | .xml .vbscript, 91 | .xml .css, 92 | .xml .hljs-cdata { 93 | opacity: 0.5; 94 | } 95 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/atelier-seaside.light.css: -------------------------------------------------------------------------------- 1 | /* Base16 Atelier Seaside Light - Theme */ 2 | /* by Bram de Haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/seaside) */ 3 | /* Original Base16 color scheme by Chris Kempson (https://github.com/chriskempson/base16) */ 4 | 5 | /* Atelier-Seaside Comment */ 6 | .hljs-comment { 7 | color: #687d68; 8 | } 9 | 10 | /* Atelier-Seaside Red */ 11 | .hljs-variable, 12 | .hljs-attribute, 13 | .hljs-tag, 14 | .hljs-regexp, 15 | .hljs-name, 16 | .ruby .hljs-constant, 17 | .xml .hljs-tag .hljs-title, 18 | .xml .hljs-pi, 19 | .xml .hljs-doctype, 20 | .html .hljs-doctype, 21 | .css .hljs-id, 22 | .css .hljs-class, 23 | .css .hljs-pseudo { 24 | color: #e6193c; 25 | } 26 | 27 | /* Atelier-Seaside Orange */ 28 | .hljs-number, 29 | .hljs-preprocessor, 30 | .hljs-built_in, 31 | .hljs-literal, 32 | .hljs-params, 33 | .hljs-constant { 34 | color: #87711d; 35 | } 36 | 37 | /* Atelier-Seaside Yellow */ 38 | .ruby .hljs-class .hljs-title, 39 | .css .hljs-rule .hljs-attribute { 40 | color: #98981b; 41 | } 42 | 43 | /* Atelier-Seaside Green */ 44 | .hljs-string, 45 | .hljs-value, 46 | .hljs-inheritance, 47 | .hljs-header, 48 | .ruby .hljs-symbol, 49 | .xml .hljs-cdata { 50 | color: #29a329; 51 | } 52 | 53 | /* Atelier-Seaside Aqua */ 54 | .hljs-title, 55 | .css .hljs-hexcolor { 56 | color: #1999b3; 57 | } 58 | 59 | /* Atelier-Seaside Blue */ 60 | .hljs-function, 61 | .python .hljs-decorator, 62 | .python .hljs-title, 63 | .ruby .hljs-function .hljs-title, 64 | .ruby .hljs-title .hljs-keyword, 65 | .perl .hljs-sub, 66 | .javascript .hljs-title, 67 | .coffeescript .hljs-title { 68 | color: #3d62f5; 69 | } 70 | 71 | /* Atelier-Seaside Purple */ 72 | .hljs-keyword, 73 | .javascript .hljs-function { 74 | color: #ad2bee; 75 | } 76 | 77 | .hljs { 78 | display: block; 79 | overflow-x: auto; 80 | background: #f4fbf4; 81 | color: #5e6e5e; 82 | padding: 0.5em; 83 | -webkit-text-size-adjust: none; 84 | } 85 | 86 | .coffeescript .javascript, 87 | .javascript .xml, 88 | .tex .hljs-formula, 89 | .xml .javascript, 90 | .xml .vbscript, 91 | .xml .css, 92 | .xml .hljs-cdata { 93 | opacity: 0.5; 94 | } 95 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/atelier-lakeside.dark.css: -------------------------------------------------------------------------------- 1 | /* Base16 Atelier Lakeside Dark - Theme */ 2 | /* by Bram de Haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/lakeside) */ 3 | /* Original Base16 color scheme by Chris Kempson (https://github.com/chriskempson/base16) */ 4 | 5 | /* Atelier-Lakeside Comment */ 6 | .hljs-comment { 7 | color: #7195a8; 8 | } 9 | 10 | /* Atelier-Lakeside Red */ 11 | .hljs-variable, 12 | .hljs-attribute, 13 | .hljs-tag, 14 | .hljs-regexp, 15 | .hljs-name, 16 | .ruby .hljs-constant, 17 | .xml .hljs-tag .hljs-title, 18 | .xml .hljs-pi, 19 | .xml .hljs-doctype, 20 | .html .hljs-doctype, 21 | .css .hljs-id, 22 | .css .hljs-class, 23 | .css .hljs-pseudo { 24 | color: #d22d72; 25 | } 26 | 27 | /* Atelier-Lakeside Orange */ 28 | .hljs-number, 29 | .hljs-preprocessor, 30 | .hljs-built_in, 31 | .hljs-literal, 32 | .hljs-params, 33 | .hljs-constant { 34 | color: #935c25; 35 | } 36 | 37 | /* Atelier-Lakeside Yellow */ 38 | .ruby .hljs-class .hljs-title, 39 | .css .hljs-rule .hljs-attribute { 40 | color: #8a8a0f; 41 | } 42 | 43 | /* Atelier-Lakeside Green */ 44 | .hljs-string, 45 | .hljs-value, 46 | .hljs-inheritance, 47 | .hljs-header, 48 | .ruby .hljs-symbol, 49 | .xml .hljs-cdata { 50 | color: #568c3b; 51 | } 52 | 53 | /* Atelier-Lakeside Aqua */ 54 | .hljs-title, 55 | .css .hljs-hexcolor { 56 | color: #2d8f6f; 57 | } 58 | 59 | /* Atelier-Lakeside Blue */ 60 | .hljs-function, 61 | .python .hljs-decorator, 62 | .python .hljs-title, 63 | .ruby .hljs-function .hljs-title, 64 | .ruby .hljs-title .hljs-keyword, 65 | .perl .hljs-sub, 66 | .javascript .hljs-title, 67 | .coffeescript .hljs-title { 68 | color: #257fad; 69 | } 70 | 71 | /* Atelier-Lakeside Purple */ 72 | .hljs-keyword, 73 | .javascript .hljs-function { 74 | color: #6b6bb8; 75 | } 76 | 77 | .hljs { 78 | display: block; 79 | overflow-x: auto; 80 | background: #161b1d; 81 | color: #7ea2b4; 82 | padding: 0.5em; 83 | -webkit-text-size-adjust: none; 84 | } 85 | 86 | .coffeescript .javascript, 87 | .javascript .xml, 88 | .tex .hljs-formula, 89 | .xml .javascript, 90 | .xml .vbscript, 91 | .xml .css, 92 | .xml .hljs-cdata { 93 | opacity: 0.5; 94 | } 95 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/atelier-lakeside.light.css: -------------------------------------------------------------------------------- 1 | /* Base16 Atelier Lakeside Light - Theme */ 2 | /* by Bram de Haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/lakeside) */ 3 | /* Original Base16 color scheme by Chris Kempson (https://github.com/chriskempson/base16) */ 4 | 5 | /* Atelier-Lakeside Comment */ 6 | .hljs-comment { 7 | color: #5a7b8c; 8 | } 9 | 10 | /* Atelier-Lakeside Red */ 11 | .hljs-variable, 12 | .hljs-attribute, 13 | .hljs-tag, 14 | .hljs-regexp, 15 | .hljs-name, 16 | .ruby .hljs-constant, 17 | .xml .hljs-tag .hljs-title, 18 | .xml .hljs-pi, 19 | .xml .hljs-doctype, 20 | .html .hljs-doctype, 21 | .css .hljs-id, 22 | .css .hljs-class, 23 | .css .hljs-pseudo { 24 | color: #d22d72; 25 | } 26 | 27 | /* Atelier-Lakeside Orange */ 28 | .hljs-number, 29 | .hljs-preprocessor, 30 | .hljs-built_in, 31 | .hljs-literal, 32 | .hljs-params, 33 | .hljs-constant { 34 | color: #935c25; 35 | } 36 | 37 | /* Atelier-Lakeside Yellow */ 38 | .ruby .hljs-class .hljs-title, 39 | .css .hljs-rule .hljs-attribute { 40 | color: #8a8a0f; 41 | } 42 | 43 | /* Atelier-Lakeside Green */ 44 | .hljs-string, 45 | .hljs-value, 46 | .hljs-inheritance, 47 | .hljs-header, 48 | .ruby .hljs-symbol, 49 | .xml .hljs-cdata { 50 | color: #568c3b; 51 | } 52 | 53 | /* Atelier-Lakeside Aqua */ 54 | .hljs-title, 55 | .css .hljs-hexcolor { 56 | color: #2d8f6f; 57 | } 58 | 59 | /* Atelier-Lakeside Blue */ 60 | .hljs-function, 61 | .python .hljs-decorator, 62 | .python .hljs-title, 63 | .ruby .hljs-function .hljs-title, 64 | .ruby .hljs-title .hljs-keyword, 65 | .perl .hljs-sub, 66 | .javascript .hljs-title, 67 | .coffeescript .hljs-title { 68 | color: #257fad; 69 | } 70 | 71 | /* Atelier-Lakeside Purple */ 72 | .hljs-keyword, 73 | .javascript .hljs-function { 74 | color: #6b6bb8; 75 | } 76 | 77 | .hljs { 78 | display: block; 79 | overflow-x: auto; 80 | background: #ebf8ff; 81 | color: #516d7b; 82 | padding: 0.5em; 83 | -webkit-text-size-adjust: none; 84 | } 85 | 86 | .coffeescript .javascript, 87 | .javascript .xml, 88 | .tex .hljs-formula, 89 | .xml .javascript, 90 | .xml .vbscript, 91 | .xml .css, 92 | .xml .hljs-cdata { 93 | opacity: 0.5; 94 | } 95 | -------------------------------------------------------------------------------- /site/themes/hyde-x/layouts/partials/sidebar.html: -------------------------------------------------------------------------------- 1 | 37 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/atelier-sulphurpool.dark.css: -------------------------------------------------------------------------------- 1 | /* Base16 Atelier Sulphurpool Dark - Theme */ 2 | /* by Bram de Haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/sulphurpool) */ 3 | /* Original Base16 color scheme by Chris Kempson (https://github.com/chriskempson/base16) */ 4 | 5 | /* Atelier-Sulphurpool Comment */ 6 | .hljs-comment { 7 | color: #898ea4; 8 | } 9 | 10 | /* Atelier-Sulphurpool Red */ 11 | .hljs-variable, 12 | .hljs-attribute, 13 | .hljs-tag, 14 | .hljs-regexp, 15 | .hljs-name, 16 | .ruby .hljs-constant, 17 | .xml .hljs-tag .hljs-title, 18 | .xml .hljs-pi, 19 | .xml .hljs-doctype, 20 | .html .hljs-doctype, 21 | .css .hljs-id, 22 | .css .hljs-class, 23 | .css .hljs-pseudo { 24 | color: #c94922; 25 | } 26 | 27 | /* Atelier-Sulphurpool Orange */ 28 | .hljs-number, 29 | .hljs-preprocessor, 30 | .hljs-built_in, 31 | .hljs-literal, 32 | .hljs-params, 33 | .hljs-constant { 34 | color: #c76b29; 35 | } 36 | 37 | /* Atelier-Sulphurpool Yellow */ 38 | .ruby .hljs-class .hljs-title, 39 | .css .hljs-rule .hljs-attribute { 40 | color: #c08b30; 41 | } 42 | 43 | /* Atelier-Sulphurpool Green */ 44 | .hljs-string, 45 | .hljs-value, 46 | .hljs-inheritance, 47 | .hljs-header, 48 | .ruby .hljs-symbol, 49 | .xml .hljs-cdata { 50 | color: #ac9739; 51 | } 52 | 53 | /* Atelier-Sulphurpool Aqua */ 54 | .hljs-title, 55 | .css .hljs-hexcolor { 56 | color: #22a2c9; 57 | } 58 | 59 | /* Atelier-Sulphurpool Blue */ 60 | .hljs-function, 61 | .python .hljs-decorator, 62 | .python .hljs-title, 63 | .ruby .hljs-function .hljs-title, 64 | .ruby .hljs-title .hljs-keyword, 65 | .perl .hljs-sub, 66 | .javascript .hljs-title, 67 | .coffeescript .hljs-title { 68 | color: #3d8fd1; 69 | } 70 | 71 | /* Atelier-Sulphurpool Purple */ 72 | .hljs-keyword, 73 | .javascript .hljs-function { 74 | color: #6679cc; 75 | } 76 | 77 | .hljs { 78 | display: block; 79 | overflow-x: auto; 80 | background: #202746; 81 | color: #979db4; 82 | padding: 0.5em; 83 | -webkit-text-size-adjust: none; 84 | } 85 | 86 | .coffeescript .javascript, 87 | .javascript .xml, 88 | .tex .hljs-formula, 89 | .xml .javascript, 90 | .xml .vbscript, 91 | .xml .css, 92 | .xml .hljs-cdata { 93 | opacity: 0.5; 94 | } 95 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/atelier-sulphurpool.light.css: -------------------------------------------------------------------------------- 1 | /* Base16 Atelier Sulphurpool Light - Theme */ 2 | /* by Bram de Haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/sulphurpool) */ 3 | /* Original Base16 color scheme by Chris Kempson (https://github.com/chriskempson/base16) */ 4 | 5 | /* Atelier-Sulphurpool Comment */ 6 | .hljs-comment { 7 | color: #6b7394; 8 | } 9 | 10 | /* Atelier-Sulphurpool Red */ 11 | .hljs-variable, 12 | .hljs-attribute, 13 | .hljs-tag, 14 | .hljs-regexp, 15 | .hljs-name, 16 | .ruby .hljs-constant, 17 | .xml .hljs-tag .hljs-title, 18 | .xml .hljs-pi, 19 | .xml .hljs-doctype, 20 | .html .hljs-doctype, 21 | .css .hljs-id, 22 | .css .hljs-class, 23 | .css .hljs-pseudo { 24 | color: #c94922; 25 | } 26 | 27 | /* Atelier-Sulphurpool Orange */ 28 | .hljs-number, 29 | .hljs-preprocessor, 30 | .hljs-built_in, 31 | .hljs-literal, 32 | .hljs-params, 33 | .hljs-constant { 34 | color: #c76b29; 35 | } 36 | 37 | /* Atelier-Sulphurpool Yellow */ 38 | .ruby .hljs-class .hljs-title, 39 | .css .hljs-rule .hljs-attribute { 40 | color: #c08b30; 41 | } 42 | 43 | /* Atelier-Sulphurpool Green */ 44 | .hljs-string, 45 | .hljs-value, 46 | .hljs-inheritance, 47 | .hljs-header, 48 | .ruby .hljs-symbol, 49 | .xml .hljs-cdata { 50 | color: #ac9739; 51 | } 52 | 53 | /* Atelier-Sulphurpool Aqua */ 54 | .hljs-title, 55 | .css .hljs-hexcolor { 56 | color: #22a2c9; 57 | } 58 | 59 | /* Atelier-Sulphurpool Blue */ 60 | .hljs-function, 61 | .python .hljs-decorator, 62 | .python .hljs-title, 63 | .ruby .hljs-function .hljs-title, 64 | .ruby .hljs-title .hljs-keyword, 65 | .perl .hljs-sub, 66 | .javascript .hljs-title, 67 | .coffeescript .hljs-title { 68 | color: #3d8fd1; 69 | } 70 | 71 | /* Atelier-Sulphurpool Purple */ 72 | .hljs-keyword, 73 | .javascript .hljs-function { 74 | color: #6679cc; 75 | } 76 | 77 | .hljs { 78 | display: block; 79 | overflow-x: auto; 80 | background: #f5f7ff; 81 | color: #5e6687; 82 | padding: 0.5em; 83 | -webkit-text-size-adjust: none; 84 | } 85 | 86 | .coffeescript .javascript, 87 | .javascript .xml, 88 | .tex .hljs-formula, 89 | .xml .javascript, 90 | .xml .vbscript, 91 | .xml .css, 92 | .xml .hljs-cdata { 93 | opacity: 0.5; 94 | } 95 | -------------------------------------------------------------------------------- /site/themes/hyde-x/layouts/partials/head.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | {{ .Title }} · {{ .Site.Author.name }} 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | {{ if isset .Site.Params "highlight" }}{{ end }} 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | {{ $siteTitle := .Site.Title }} 28 | {{ $authorName := .Site.Author.name }} 29 | {{ with .RSSLink }}{{ end }} 30 | 31 | 32 | 33 | {{ with .Site.Params.googleAuthorship }}{{ end }} 34 | 35 | 36 | {{ partial "sidebar.html" . }} 37 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/solarized_dark.css: -------------------------------------------------------------------------------- 1 | /* 2 | 3 | Orginal Style from ethanschoonover.com/solarized (c) Jeremy Hull 4 | 5 | */ 6 | 7 | .hljs { 8 | display: block; 9 | overflow-x: auto; 10 | padding: 0.5em; 11 | background: #002b36; 12 | color: #839496; 13 | -webkit-text-size-adjust: none; 14 | } 15 | 16 | .hljs-comment, 17 | .diff .hljs-header, 18 | .hljs-doctype, 19 | .hljs-pi, 20 | .lisp .hljs-string { 21 | color: #586e75; 22 | } 23 | 24 | /* Solarized Green */ 25 | .hljs-keyword, 26 | .hljs-winutils, 27 | .method, 28 | .hljs-addition, 29 | .css .hljs-tag, 30 | .hljs-request, 31 | .hljs-status, 32 | .nginx .hljs-title { 33 | color: #859900; 34 | } 35 | 36 | /* Solarized Cyan */ 37 | .hljs-number, 38 | .hljs-command, 39 | .hljs-string, 40 | .hljs-tag .hljs-value, 41 | .hljs-rule .hljs-value, 42 | .hljs-doctag, 43 | .tex .hljs-formula, 44 | .hljs-regexp, 45 | .hljs-hexcolor, 46 | .hljs-link_url { 47 | color: #2aa198; 48 | } 49 | 50 | /* Solarized Blue */ 51 | .hljs-title, 52 | .hljs-localvars, 53 | .hljs-chunk, 54 | .hljs-decorator, 55 | .hljs-built_in, 56 | .hljs-identifier, 57 | .vhdl .hljs-literal, 58 | .hljs-id, 59 | .css .hljs-function, 60 | .hljs-name { 61 | color: #268bd2; 62 | } 63 | 64 | /* Solarized Yellow */ 65 | .hljs-attribute, 66 | .hljs-variable, 67 | .lisp .hljs-body, 68 | .smalltalk .hljs-number, 69 | .hljs-constant, 70 | .hljs-class .hljs-title, 71 | .hljs-parent, 72 | .hljs-type, 73 | .hljs-link_reference { 74 | color: #b58900; 75 | } 76 | 77 | /* Solarized Orange */ 78 | .hljs-preprocessor, 79 | .hljs-preprocessor .hljs-keyword, 80 | .hljs-pragma, 81 | .hljs-shebang, 82 | .hljs-symbol, 83 | .hljs-symbol .hljs-string, 84 | .diff .hljs-change, 85 | .hljs-special, 86 | .hljs-attr_selector, 87 | .hljs-subst, 88 | .hljs-cdata, 89 | .css .hljs-pseudo, 90 | .hljs-header { 91 | color: #cb4b16; 92 | } 93 | 94 | /* Solarized Red */ 95 | .hljs-deletion, 96 | .hljs-important { 97 | color: #dc322f; 98 | } 99 | 100 | /* Solarized Violet */ 101 | .hljs-link_label { 102 | color: #6c71c4; 103 | } 104 | 105 | .tex .hljs-formula { 106 | background: #073642; 107 | } 108 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/solarized_light.css: -------------------------------------------------------------------------------- 1 | /* 2 | 3 | Orginal Style from ethanschoonover.com/solarized (c) Jeremy Hull 4 | 5 | */ 6 | 7 | .hljs { 8 | display: block; 9 | overflow-x: auto; 10 | padding: 0.5em; 11 | background: #fdf6e3; 12 | color: #657b83; 13 | -webkit-text-size-adjust: none; 14 | } 15 | 16 | .hljs-comment, 17 | .diff .hljs-header, 18 | .hljs-doctype, 19 | .hljs-pi, 20 | .lisp .hljs-string { 21 | color: #93a1a1; 22 | } 23 | 24 | /* Solarized Green */ 25 | .hljs-keyword, 26 | .hljs-winutils, 27 | .method, 28 | .hljs-addition, 29 | .css .hljs-tag, 30 | .hljs-request, 31 | .hljs-status, 32 | .nginx .hljs-title { 33 | color: #859900; 34 | } 35 | 36 | /* Solarized Cyan */ 37 | .hljs-number, 38 | .hljs-command, 39 | .hljs-string, 40 | .hljs-tag .hljs-value, 41 | .hljs-rule .hljs-value, 42 | .hljs-doctag, 43 | .tex .hljs-formula, 44 | .hljs-regexp, 45 | .hljs-hexcolor, 46 | .hljs-link_url { 47 | color: #2aa198; 48 | } 49 | 50 | /* Solarized Blue */ 51 | .hljs-title, 52 | .hljs-localvars, 53 | .hljs-chunk, 54 | .hljs-decorator, 55 | .hljs-built_in, 56 | .hljs-identifier, 57 | .vhdl .hljs-literal, 58 | .hljs-id, 59 | .css .hljs-function, 60 | .hljs-name { 61 | color: #268bd2; 62 | } 63 | 64 | /* Solarized Yellow */ 65 | .hljs-attribute, 66 | .hljs-variable, 67 | .lisp .hljs-body, 68 | .smalltalk .hljs-number, 69 | .hljs-constant, 70 | .hljs-class .hljs-title, 71 | .hljs-parent, 72 | .hljs-type, 73 | .hljs-link_reference { 74 | color: #b58900; 75 | } 76 | 77 | /* Solarized Orange */ 78 | .hljs-preprocessor, 79 | .hljs-preprocessor .hljs-keyword, 80 | .hljs-pragma, 81 | .hljs-shebang, 82 | .hljs-symbol, 83 | .hljs-symbol .hljs-string, 84 | .diff .hljs-change, 85 | .hljs-special, 86 | .hljs-attr_selector, 87 | .hljs-subst, 88 | .hljs-cdata, 89 | .css .hljs-pseudo, 90 | .hljs-header { 91 | color: #cb4b16; 92 | } 93 | 94 | /* Solarized Red */ 95 | .hljs-deletion, 96 | .hljs-important { 97 | color: #dc322f; 98 | } 99 | 100 | /* Solarized Violet */ 101 | .hljs-link_label { 102 | color: #6c71c4; 103 | } 104 | 105 | .tex .hljs-formula { 106 | background: #eee8d5; 107 | } 108 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/pojoaque.css: -------------------------------------------------------------------------------- 1 | /* 2 | 3 | Pojoaque Style by Jason Tate 4 | http://web-cms-designs.com/ftopict-10-pojoaque-style-for-highlight-js-code-highlighter.html 5 | Based on Solarized Style from http://ethanschoonover.com/solarized 6 | 7 | */ 8 | 9 | .hljs { 10 | display: block; 11 | overflow-x: auto; 12 | padding: 0.5em; 13 | color: #dccf8f; 14 | background: url(./pojoaque.jpg) repeat scroll left top #181914; 15 | -webkit-text-size-adjust: none; 16 | } 17 | 18 | .hljs-comment, 19 | .diff .hljs-header, 20 | .hljs-doctype, 21 | .lisp .hljs-string { 22 | color: #586e75; 23 | font-style: italic; 24 | } 25 | 26 | .hljs-keyword, 27 | .css .rule .hljs-keyword, 28 | .hljs-winutils, 29 | .javascript .hljs-title, 30 | .method, 31 | .hljs-addition, 32 | .css .hljs-tag, 33 | .hljs-list .hljs-keyword, 34 | .nginx .hljs-title { 35 | color: #b64926; 36 | } 37 | 38 | .hljs-number, 39 | .hljs-command, 40 | .hljs-string, 41 | .hljs-tag .hljs-value, 42 | .hljs-doctag, 43 | .tex .hljs-formula, 44 | .hljs-regexp, 45 | .hljs-hexcolor { 46 | color: #468966; 47 | } 48 | 49 | .hljs-title, 50 | .hljs-localvars, 51 | .hljs-function .hljs-title, 52 | .hljs-chunk, 53 | .hljs-decorator, 54 | .hljs-built_in, 55 | .hljs-identifier, 56 | .hljs-name, 57 | .hljs-id { 58 | color: #ffb03b; 59 | } 60 | 61 | .hljs-attribute, 62 | .hljs-variable, 63 | .lisp .hljs-body, 64 | .smalltalk .hljs-number, 65 | .hljs-constant, 66 | .hljs-class .hljs-title, 67 | .hljs-parent, 68 | .hljs-type { 69 | color: #b58900; 70 | } 71 | 72 | .css .hljs-attribute { 73 | color: #b89859; 74 | } 75 | 76 | .css .hljs-number, 77 | .css .hljs-hexcolor { 78 | color: #dccf8f; 79 | } 80 | 81 | .css .hljs-class { 82 | color: #d3a60c; 83 | } 84 | 85 | .hljs-preprocessor, 86 | .hljs-pragma, 87 | .hljs-pi, 88 | .hljs-shebang, 89 | .hljs-symbol, 90 | .hljs-symbol .hljs-string, 91 | .diff .hljs-change, 92 | .hljs-special, 93 | .hljs-attr_selector, 94 | .hljs-important, 95 | .hljs-subst, 96 | .hljs-cdata { 97 | color: #cb4b16; 98 | } 99 | 100 | .hljs-deletion { 101 | color: #dc322f; 102 | } 103 | 104 | .tex .hljs-formula { 105 | background: #073642; 106 | } 107 | -------------------------------------------------------------------------------- /src/swirl_sup.erl: -------------------------------------------------------------------------------- 1 | %% -*- tab-width: 4;erlang-indent-level: 4;indent-tabs-mode: nil -*- 2 | %% ex: ft=erlang ts=4 sw=4 et 3 | %% Licensed under the Apache License, Version 2.0 (the "License"); you may not 4 | %% use this file except in compliance with the License. You may obtain a copy of 5 | %% the License at 6 | %% 7 | %% http://www.apache.org/licenses/LICENSE-2.0 8 | %% 9 | %% Unless required by applicable law or agreed to in writing, software 10 | %% distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | %% WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | %% License for the specific language governing permissions and limitations under 13 | %% the License. 14 | 15 | %% @doc Library for PPSPP over UDP, aka Swift protocol 16 | %% 17 | %% This module implements a library of functions necessary to 18 | %% handle the wire-protocol of PPSPP over UDP, including 19 | %% functions for encoding and decoding messages. 20 | %% @end 21 | 22 | -module(swirl_sup). 23 | -include("swirl.hrl"). 24 | 25 | -behaviour(supervisor). 26 | 27 | %% api 28 | -export([start_link/0]). 29 | 30 | %% callbacks 31 | -export([init/1]). 32 | 33 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 34 | %% api 35 | 36 | -spec start_link() -> {ok, pid()} | {error, _}. 37 | start_link() -> 38 | supervisor:start_link({local, ?MODULE}, ?MODULE, []). 39 | 40 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 41 | %% callbacks 42 | 43 | -spec init([]) -> {ok,{{one_for_one, 10,60}, [supervisor:child_spec()] }}. 44 | init([]) -> 45 | Supervisors = [ {peer_sup, {peer_sup, start_link, []}, 46 | permanent, 47 | infinity, 48 | supervisor, [peer_sup]}, 49 | {swarm_sup, {swarm_sup, start_link, []}, 50 | permanent, 51 | infinity, 52 | supervisor, [swarm_sup]}, 53 | {channel_sup, {channel_sup, start_link, []}, 54 | permanent, 55 | infinity, 56 | supervisor, [channel_sup]} ], 57 | 58 | % summon the supervisors 59 | {ok, {{one_for_one, 10, 60}, Supervisors}}. 60 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/dark.css: -------------------------------------------------------------------------------- 1 | /* 2 | 3 | Dark style from softwaremaniacs.org (c) Ivan Sagalaev 4 | 5 | */ 6 | 7 | .hljs { 8 | display: block; 9 | overflow-x: auto; 10 | padding: 0.5em; 11 | background: #444; 12 | -webkit-text-size-adjust: none; 13 | } 14 | 15 | .hljs-keyword, 16 | .hljs-literal, 17 | .hljs-change, 18 | .hljs-winutils, 19 | .hljs-flow, 20 | .nginx .hljs-title, 21 | .tex .hljs-special { 22 | color: white; 23 | } 24 | 25 | .hljs, 26 | .hljs-subst { 27 | color: #ddd; 28 | } 29 | 30 | .hljs-string, 31 | .hljs-title, 32 | .hljs-type, 33 | .ini .hljs-title, 34 | .hljs-tag .hljs-value, 35 | .css .hljs-rule .hljs-value, 36 | .hljs-preprocessor, 37 | .hljs-pragma, 38 | .ruby .hljs-symbol, 39 | .ruby .hljs-symbol .hljs-string, 40 | .ruby .hljs-class .hljs-parent, 41 | .hljs-built_in, 42 | .django .hljs-template_tag, 43 | .django .hljs-variable, 44 | .smalltalk .hljs-class, 45 | .ruby .hljs-string, 46 | .django .hljs-filter .hljs-argument, 47 | .smalltalk .hljs-localvars, 48 | .smalltalk .hljs-array, 49 | .hljs-attr_selector, 50 | .hljs-pseudo, 51 | .hljs-addition, 52 | .hljs-stream, 53 | .hljs-envvar, 54 | .apache .hljs-tag, 55 | .apache .hljs-cbracket, 56 | .tex .hljs-command, 57 | .hljs-prompt, 58 | .coffeescript .hljs-attribute, 59 | .hljs-name { 60 | color: #d88; 61 | } 62 | 63 | .hljs-comment, 64 | .hljs-annotation, 65 | .hljs-decorator, 66 | .hljs-pi, 67 | .hljs-doctype, 68 | .hljs-deletion, 69 | .hljs-shebang, 70 | .apache .hljs-sqbracket, 71 | .tex .hljs-formula { 72 | color: #777; 73 | } 74 | 75 | .hljs-keyword, 76 | .hljs-literal, 77 | .hljs-title, 78 | .css .hljs-id, 79 | .hljs-doctag, 80 | .hljs-type, 81 | .vbscript .hljs-built_in, 82 | .rsl .hljs-built_in, 83 | .smalltalk .hljs-class, 84 | .diff .hljs-header, 85 | .hljs-chunk, 86 | .hljs-winutils, 87 | .bash .hljs-variable, 88 | .apache .hljs-tag, 89 | .tex .hljs-special, 90 | .hljs-request, 91 | .hljs-status { 92 | font-weight: bold; 93 | } 94 | 95 | .coffeescript .javascript, 96 | .javascript .xml, 97 | .tex .hljs-formula, 98 | .xml .javascript, 99 | .xml .vbscript, 100 | .xml .css, 101 | .xml .hljs-cdata { 102 | opacity: 0.5; 103 | } 104 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/brown_paper.css: -------------------------------------------------------------------------------- 1 | /* 2 | 3 | Brown Paper style from goldblog.com.ua (c) Zaripov Yura 4 | 5 | */ 6 | 7 | .hljs { 8 | display: block; 9 | overflow-x: auto; 10 | padding: 0.5em; 11 | background:#b7a68e url(./brown_papersq.png); 12 | -webkit-text-size-adjust: none; 13 | } 14 | 15 | .hljs-keyword, 16 | .hljs-literal, 17 | .hljs-change, 18 | .hljs-winutils, 19 | .hljs-flow, 20 | .nginx .hljs-title, 21 | .tex .hljs-special, 22 | .hljs-request, 23 | .hljs-status { 24 | color:#005599; 25 | font-weight:bold; 26 | } 27 | 28 | .hljs, 29 | .hljs-subst, 30 | .hljs-tag .hljs-keyword { 31 | color: #363c69; 32 | } 33 | 34 | .hljs-string, 35 | .hljs-title, 36 | .hljs-type, 37 | .hljs-tag .hljs-value, 38 | .css .hljs-rule .hljs-value, 39 | .hljs-preprocessor, 40 | .hljs-pragma, 41 | .ruby .hljs-symbol, 42 | .ruby .hljs-symbol .hljs-string, 43 | .ruby .hljs-class .hljs-parent, 44 | .hljs-built_in, 45 | .django .hljs-template_tag, 46 | .django .hljs-variable, 47 | .smalltalk .hljs-class, 48 | .ruby .hljs-string, 49 | .django .hljs-filter .hljs-argument, 50 | .smalltalk .hljs-localvars, 51 | .smalltalk .hljs-array, 52 | .hljs-attr_selector, 53 | .hljs-pseudo, 54 | .hljs-addition, 55 | .hljs-stream, 56 | .hljs-envvar, 57 | .apache .hljs-tag, 58 | .apache .hljs-cbracket, 59 | .tex .hljs-number, 60 | .hljs-name { 61 | color: #2c009f; 62 | } 63 | 64 | .hljs-comment, 65 | .hljs-annotation, 66 | .hljs-decorator, 67 | .hljs-pi, 68 | .hljs-doctype, 69 | .hljs-deletion, 70 | .hljs-shebang, 71 | .apache .hljs-sqbracket, 72 | .nginx .hljs-built_in, 73 | .tex .hljs-formula { 74 | color: #802022; 75 | } 76 | 77 | .hljs-keyword, 78 | .hljs-literal, 79 | .css .hljs-id, 80 | .hljs-doctag, 81 | .hljs-title, 82 | .hljs-type, 83 | .vbscript .hljs-built_in, 84 | .rsl .hljs-built_in, 85 | .smalltalk .hljs-class, 86 | .diff .hljs-header, 87 | .hljs-chunk, 88 | .hljs-winutils, 89 | .bash .hljs-variable, 90 | .apache .hljs-tag, 91 | .tex .hljs-command { 92 | font-weight: bold; 93 | } 94 | 95 | .coffeescript .javascript, 96 | .javascript .xml, 97 | .tex .hljs-formula, 98 | .xml .javascript, 99 | .xml .vbscript, 100 | .xml .css, 101 | .xml .hljs-cdata { 102 | opacity: 0.8; 103 | } 104 | -------------------------------------------------------------------------------- /src/swarm_sup.erl: -------------------------------------------------------------------------------- 1 | %% -*- tab-width: 4;erlang-indent-level: 4;indent-tabs-mode: nil -*- 2 | %% ex: ft=erlang ts=4 sw=4 et 3 | %% Licensed under the Apache License, Version 2.0 (the "License"); you may not 4 | %% use this file except in compliance with the License. You may obtain a copy of 5 | %% the License at 6 | %% 7 | %% http://www.apache.org/licenses/LICENSE-2.0 8 | %% 9 | %% Unless required by applicable law or agreed to in writing, software 10 | %% distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | %% WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | %% License for the specific language governing permissions and limitations under 13 | %% the License. 14 | 15 | %% @doc Library for PPSPP over UDP, aka Swift protocol 16 | %% 17 | %% This module implements a library of functions necessary to 18 | %% handle the wire-protocol of PPSPP over UDP, including 19 | %% functions for encoding and decoding messages. 20 | %% @end 21 | 22 | -module(swarm_sup). 23 | -include("swirl.hrl"). 24 | 25 | -behaviour(supervisor). 26 | 27 | %% api 28 | -export([start_link/0, 29 | start_child/1 ]). 30 | 31 | %% callbacks 32 | -export([init/1]). 33 | 34 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 35 | %% api 36 | 37 | -spec start_link() -> {ok, pid()} | ignore | {error, any()}. 38 | 39 | start_link() -> 40 | supervisor:start_link({local, ?MODULE}, ?MODULE, []). 41 | 42 | -spec start_child([ppspp_options:options()]) -> 43 | {error,_} | {ok, pid()}. 44 | start_child([Swarm_Options]) -> 45 | supervisor:start_child(?MODULE, [Swarm_Options]). 46 | 47 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 48 | %% callbacks 49 | 50 | -spec init([]) -> {ok,{{simple_one_for_one, 10,60}, [supervisor:child_spec()] }}. 51 | init([])-> 52 | RestartStrategy = simple_one_for_one, 53 | MaxRestarts = 10, 54 | MaxSecondsBetweenRestarts = 60, 55 | Options = {RestartStrategy, MaxRestarts, MaxSecondsBetweenRestarts}, 56 | Restart = transient, 57 | Shutdown = 1000, 58 | Type = worker, 59 | 60 | Worker = {swarm_worker, {swarm_worker, start_link, []}, 61 | Restart, 62 | Shutdown, 63 | Type, 64 | [swarm_worker]}, 65 | 66 | {ok, {Options, [Worker]}}. 67 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/github.css: -------------------------------------------------------------------------------- 1 | /* 2 | 3 | github.com style (c) Vasily Polovnyov 4 | 5 | */ 6 | 7 | .hljs { 8 | display: block; 9 | overflow-x: auto; 10 | padding: 0.5em; 11 | color: #333; 12 | background: #f8f8f8; 13 | -webkit-text-size-adjust: none; 14 | } 15 | 16 | .hljs-comment, 17 | .diff .hljs-header { 18 | color: #998; 19 | font-style: italic; 20 | } 21 | 22 | .hljs-keyword, 23 | .css .rule .hljs-keyword, 24 | .hljs-winutils, 25 | .nginx .hljs-title, 26 | .hljs-subst, 27 | .hljs-request, 28 | .hljs-status { 29 | color: #333; 30 | font-weight: bold; 31 | } 32 | 33 | .hljs-number, 34 | .hljs-hexcolor, 35 | .ruby .hljs-constant { 36 | color: #008080; 37 | } 38 | 39 | .hljs-string, 40 | .hljs-tag .hljs-value, 41 | .hljs-doctag, 42 | .tex .hljs-formula { 43 | color: #d14; 44 | } 45 | 46 | .hljs-title, 47 | .hljs-id, 48 | .scss .hljs-preprocessor { 49 | color: #900; 50 | font-weight: bold; 51 | } 52 | 53 | .hljs-list .hljs-keyword, 54 | .hljs-subst { 55 | font-weight: normal; 56 | } 57 | 58 | .hljs-class .hljs-title, 59 | .hljs-type, 60 | .vhdl .hljs-literal, 61 | .tex .hljs-command { 62 | color: #458; 63 | font-weight: bold; 64 | } 65 | 66 | .hljs-tag, 67 | .hljs-tag .hljs-title, 68 | .hljs-rule .hljs-property, 69 | .django .hljs-tag .hljs-keyword { 70 | color: #000080; 71 | font-weight: normal; 72 | } 73 | 74 | .hljs-attribute, 75 | .hljs-variable, 76 | .lisp .hljs-body, 77 | .hljs-name { 78 | color: #008080; 79 | } 80 | 81 | .hljs-regexp { 82 | color: #009926; 83 | } 84 | 85 | .hljs-symbol, 86 | .ruby .hljs-symbol .hljs-string, 87 | .lisp .hljs-keyword, 88 | .clojure .hljs-keyword, 89 | .scheme .hljs-keyword, 90 | .tex .hljs-special, 91 | .hljs-prompt { 92 | color: #990073; 93 | } 94 | 95 | .hljs-built_in { 96 | color: #0086b3; 97 | } 98 | 99 | .hljs-preprocessor, 100 | .hljs-pragma, 101 | .hljs-pi, 102 | .hljs-doctype, 103 | .hljs-shebang, 104 | .hljs-cdata { 105 | color: #999; 106 | font-weight: bold; 107 | } 108 | 109 | .hljs-deletion { 110 | background: #fdd; 111 | } 112 | 113 | .hljs-addition { 114 | background: #dfd; 115 | } 116 | 117 | .diff .hljs-change { 118 | background: #0086b3; 119 | } 120 | 121 | .hljs-chunk { 122 | color: #aaa; 123 | } 124 | -------------------------------------------------------------------------------- /src/peer_sup.erl: -------------------------------------------------------------------------------- 1 | %% -*- tab-width: 4;erlang-indent-level: 4;indent-tabs-mode: nil -*- 2 | %% ex: ft=erlang ts=4 sw=4 et 3 | %% Licensed under the Apache License, Version 2.0 (the "License"); you may not 4 | %% use this file except in compliance with the License. You may obtain a copy of 5 | %% the License at 6 | %% 7 | %% http://www.apache.org/licenses/LICENSE-2.0 8 | %% 9 | %% Unless required by applicable law or agreed to in writing, software 10 | %% distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | %% WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | %% License for the specific language governing permissions and limitations under 13 | %% the License. 14 | 15 | %% @doc Library for PPSPP over UDP, aka Swift protocol 16 | %% 17 | %% This module implements a library of functions necessary to 18 | %% handle the wire-protocol of PPSPP over UDP, including 19 | %% functions for encoding and decoding messages. 20 | %% @end 21 | 22 | -module(peer_sup). 23 | -include("swirl.hrl"). 24 | 25 | -behaviour(supervisor). 26 | 27 | %% api 28 | -export([start_link/0, 29 | start_child/1 ]). 30 | 31 | %% callbacks 32 | -export([init/1]). 33 | 34 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 35 | %% api 36 | 37 | -spec start_link() -> {ok, pid()} | ignore | {error, any()}. 38 | 39 | start_link() -> 40 | supervisor:start_link({local, ?MODULE}, ?MODULE, []). 41 | 42 | %%-spec start_child(port()) -> ok. 43 | -spec start_child([inet:port_number()]) -> 44 | {error,_} | {ok, pid()}. 45 | start_child([Port]) when is_integer(Port) -> 46 | supervisor:start_child(?MODULE, [Port]). 47 | 48 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 49 | %% callbacks 50 | 51 | -spec init([]) -> {ok,{{simple_one_for_one, 10,60}, [supervisor:child_spec()] }}. 52 | init([])-> 53 | RestartStrategy = simple_one_for_one, 54 | MaxRestarts = 10, 55 | MaxSecondsBetweenRestarts = 60, 56 | Options = {RestartStrategy, MaxRestarts, MaxSecondsBetweenRestarts}, 57 | Restart = transient, 58 | Shutdown = 1000, 59 | Type = worker, 60 | 61 | Worker = {peer_worker, {peer_worker, start_link, []}, 62 | Restart, 63 | Shutdown, 64 | Type, 65 | [peer_worker]}, 66 | 67 | {ok, {Options, [Worker]}}. 68 | -------------------------------------------------------------------------------- /test/peer_worker_SUITE.erl: -------------------------------------------------------------------------------- 1 | %% -*- tab-width: 4;erlang-indent-level: 4;indent-tabs-mode: nil -*- 2 | %% ex: ft=erlang ts=4 sw=4 et 3 | %% Licensed under the Apache License, Version 2.0 (the "License"); you may not 4 | %% use this file except in compliance with the License. You may obtain a copy of 5 | %% the License at 6 | %% 7 | %% http://www.apache.org/licenses/LICENSE-2.0 8 | %% 9 | %% Unless required by applicable law or agreed to in writing, software 10 | %% distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | %% WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | %% License for the specific language governing permissions and limitations under 13 | %% the License. 14 | 15 | %% @doc Library for PPSPP over UDP, aka Swift protocol 16 | %%

This module implements a library of functions necessary to 17 | %% handle the wire-protocol of PPSPP over UDP, including 18 | %% functions for encoding and decoding messages.

19 | %% @end 20 | 21 | -module(peer_worker_SUITE). 22 | -include("swirl.hrl"). 23 | -include_lib("common_test/include/ct.hrl"). 24 | 25 | -export([all/0]). 26 | -export([start_peer/1, 27 | stop_peer/1, 28 | start_and_stop_random_peer/1 29 | ]). 30 | 31 | -spec all() -> [atom()]. 32 | all() -> [start_peer, 33 | stop_peer, 34 | start_and_stop_random_peer 35 | ]. 36 | 37 | -spec start_peer(any()) -> true. 38 | start_peer(_Config) -> 39 | swirl:start(), 40 | Swarm_Options = ppspp_options:use_default_options(), 41 | {ok, Worker} = swirl:start_peer(?SWIRL_PORT, Swarm_Options), 42 | timer:sleep(100), 43 | true = is_process_alive(Worker). 44 | 45 | -spec stop_peer(any()) -> false. 46 | stop_peer(_Config) -> 47 | Worker = gproc:lookup_local_name({peer_worker, ?SWIRL_PORT}), 48 | true = is_process_alive(Worker), 49 | swirl:stop_peer(?SWIRL_PORT), 50 | timer:sleep(100), 51 | false = is_process_alive(Worker). 52 | 53 | -spec start_and_stop_random_peer(any()) -> true. 54 | start_and_stop_random_peer(_Config) -> 55 | Swarm_Options = ppspp_options:use_default_options("c89e"), 56 | {ok, Worker} = peer_worker:start_link(0, Swarm_Options), 57 | timer:sleep(500), 58 | true = is_process_alive(Worker), 59 | {ok, Port} = peer_worker:pid_to_port(Worker), 60 | peer_worker:stop(Port), 61 | timer:sleep(100), 62 | false = is_process_alive(Worker). 63 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/far.css: -------------------------------------------------------------------------------- 1 | /* 2 | 3 | FAR Style (c) MajestiC 4 | 5 | */ 6 | 7 | .hljs { 8 | display: block; 9 | overflow-x: auto; 10 | padding: 0.5em; 11 | background: #000080; 12 | -webkit-text-size-adjust: none; 13 | } 14 | 15 | .hljs, 16 | .hljs-subst { 17 | color: #0ff; 18 | } 19 | 20 | .hljs-string, 21 | .ruby .hljs-string, 22 | .haskell .hljs-type, 23 | .hljs-tag .hljs-value, 24 | .hljs-rule .hljs-value, 25 | .hljs-rule .hljs-value .hljs-number, 26 | .hljs-preprocessor, 27 | .hljs-pragma, 28 | .ruby .hljs-symbol, 29 | .ruby .hljs-symbol .hljs-string, 30 | .hljs-built_in, 31 | .django .hljs-template_tag, 32 | .django .hljs-variable, 33 | .smalltalk .hljs-class, 34 | .hljs-addition, 35 | .apache .hljs-tag, 36 | .apache .hljs-cbracket, 37 | .tex .hljs-command, 38 | .coffeescript .hljs-attribute { 39 | color: #ff0; 40 | } 41 | 42 | .hljs-keyword, 43 | .css .hljs-id, 44 | .hljs-title, 45 | .hljs-type, 46 | .vbscript .hljs-built_in, 47 | .rsl .hljs-built_in, 48 | .smalltalk .hljs-class, 49 | .xml .hljs-tag .hljs-title, 50 | .hljs-winutils, 51 | .hljs-flow, 52 | .hljs-change, 53 | .hljs-envvar, 54 | .bash .hljs-variable, 55 | .tex .hljs-special, 56 | .hljs-name { 57 | color: #fff; 58 | } 59 | 60 | .hljs-comment, 61 | .hljs-doctag, 62 | .hljs-annotation, 63 | .hljs-deletion, 64 | .apache .hljs-sqbracket, 65 | .tex .hljs-formula { 66 | color: #888; 67 | } 68 | 69 | .hljs-number, 70 | .hljs-date, 71 | .hljs-regexp, 72 | .hljs-literal, 73 | .smalltalk .hljs-symbol, 74 | .smalltalk .hljs-char, 75 | .clojure .hljs-attribute { 76 | color: #0f0; 77 | } 78 | 79 | .hljs-decorator, 80 | .django .hljs-filter .hljs-argument, 81 | .smalltalk .hljs-localvars, 82 | .smalltalk .hljs-array, 83 | .hljs-attr_selector, 84 | .hljs-pseudo, 85 | .xml .hljs-pi, 86 | .diff .hljs-header, 87 | .hljs-chunk, 88 | .hljs-shebang, 89 | .nginx .hljs-built_in, 90 | .hljs-prompt { 91 | color: #008080; 92 | } 93 | 94 | .hljs-keyword, 95 | .css .hljs-id, 96 | .hljs-title, 97 | .hljs-type, 98 | .vbscript .hljs-built_in, 99 | .rsl .hljs-built_in, 100 | .smalltalk .hljs-class, 101 | .hljs-winutils, 102 | .hljs-flow, 103 | .apache .hljs-tag, 104 | .nginx .hljs-built_in, 105 | .tex .hljs-command, 106 | .tex .hljs-special, 107 | .hljs-request, 108 | .hljs-status { 109 | font-weight: bold; 110 | } 111 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/foundation.css: -------------------------------------------------------------------------------- 1 | /* 2 | Description: Foundation 4 docs style for highlight.js 3 | Author: Dan Allen 4 | Website: http://foundation.zurb.com/docs/ 5 | Version: 1.0 6 | Date: 2013-04-02 7 | */ 8 | 9 | .hljs { 10 | display: block; 11 | overflow-x: auto; 12 | padding: 0.5em; 13 | background: #eee; 14 | -webkit-text-size-adjust: none; 15 | } 16 | 17 | .hljs-header, 18 | .hljs-decorator, 19 | .hljs-annotation { 20 | color: #000077; 21 | } 22 | 23 | .hljs-horizontal_rule, 24 | .hljs-link_url, 25 | .hljs-emphasis, 26 | .hljs-attribute { 27 | color: #070; 28 | } 29 | 30 | .hljs-emphasis { 31 | font-style: italic; 32 | } 33 | 34 | .hljs-link_label, 35 | .hljs-strong, 36 | .hljs-value, 37 | .hljs-string, 38 | .scss .hljs-value .hljs-string { 39 | color: #d14; 40 | } 41 | 42 | .hljs-strong { 43 | font-weight: bold; 44 | } 45 | 46 | .hljs-blockquote, 47 | .hljs-comment { 48 | color: #998; 49 | font-style: italic; 50 | } 51 | 52 | .asciidoc .hljs-title, 53 | .hljs-function .hljs-title { 54 | color: #900; 55 | } 56 | 57 | .hljs-class { 58 | color: #458; 59 | } 60 | 61 | .hljs-id, 62 | .hljs-pseudo, 63 | .hljs-constant, 64 | .hljs-hexcolor { 65 | color: teal; 66 | } 67 | 68 | .hljs-variable { 69 | color: #336699; 70 | } 71 | 72 | .hljs-bullet { 73 | color: #997700; 74 | } 75 | 76 | .hljs-pi, 77 | .hljs-doctype { 78 | color: #3344bb; 79 | } 80 | 81 | .hljs-code, 82 | .hljs-number { 83 | color: #099; 84 | } 85 | 86 | .hljs-important { 87 | color: #f00; 88 | } 89 | 90 | .smartquote, 91 | .hljs-label { 92 | color: #970; 93 | } 94 | 95 | .hljs-preprocessor, 96 | .hljs-pragma { 97 | color: #579; 98 | } 99 | 100 | .hljs-reserved, 101 | .hljs-keyword, 102 | .scss .hljs-value { 103 | color: #000; 104 | } 105 | 106 | .hljs-regexp { 107 | background-color: #fff0ff; 108 | color: #880088; 109 | } 110 | 111 | .hljs-symbol { 112 | color: #990073; 113 | } 114 | 115 | .hljs-symbol .hljs-string { 116 | color: #a60; 117 | } 118 | 119 | .hljs-tag { 120 | color: #007700; 121 | } 122 | 123 | .hljs-at_rule, 124 | .hljs-at_rule .hljs-keyword { 125 | color: #088; 126 | } 127 | 128 | .hljs-at_rule .hljs-preprocessor { 129 | color: #808; 130 | } 131 | 132 | .scss .hljs-tag, 133 | .scss .hljs-attribute { 134 | color: #339; 135 | } 136 | -------------------------------------------------------------------------------- /src/channel_sup.erl: -------------------------------------------------------------------------------- 1 | %% -*- tab-width: 4;erlang-indent-level: 4;indent-tabs-mode: nil -*- 2 | %% ex: ft=erlang ts=4 sw=4 et 3 | %% Licensed under the Apache License, Version 2.0 (the "License"); you may not 4 | %% use this file except in compliance with the License. You may obtain a copy of 5 | %% the License at 6 | %% 7 | %% http://www.apache.org/licenses/LICENSE-2.0 8 | %% 9 | %% Unless required by applicable law or agreed to in writing, software 10 | %% distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | %% WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | %% License for the specific language governing permissions and limitations under 13 | %% the License. 14 | 15 | %% @doc Library for PPSPP over UDP, aka Swift protocol 16 | %% 17 | %% This module implements a library of functions necessary to 18 | %% handle the wire-protocol of PPSPP over UDP, including 19 | %% functions for encoding and decoding messages. 20 | %% @end 21 | 22 | -module(channel_sup). 23 | -include("swirl.hrl"). 24 | 25 | -behaviour(supervisor). 26 | 27 | %% api 28 | -export([start_link/0, 29 | start_child/1]). 30 | 31 | %% callbacks 32 | -export([init/1]). 33 | 34 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 35 | %% api 36 | 37 | -spec start_link() -> {ok, pid()} | ignore | {error, any()}. 38 | start_link() -> 39 | supervisor:start_link({local, ?MODULE}, ?MODULE, []). 40 | 41 | -spec start_child([ppspp_datagram:endpoint() | 42 | ppspp_options:options()]) -> 43 | {error,_} | {ok, pid()}. 44 | start_child([Peer_endpoint, Swarm_options]) -> 45 | supervisor:start_child(?MODULE, [Peer_endpoint, Swarm_options]). 46 | 47 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 48 | %% callbacks 49 | 50 | -spec init([]) -> {ok,{{simple_one_for_one, 10,60}, [supervisor:child_spec()] }}. 51 | 52 | init([])-> 53 | RestartStrategy = simple_one_for_one, 54 | MaxRestarts = 10, 55 | MaxSecondsBetweenRestarts = 60, 56 | Options = {RestartStrategy, MaxRestarts, MaxSecondsBetweenRestarts}, 57 | Restart = transient, 58 | Shutdown = 1000, 59 | Type = worker, 60 | 61 | Worker = {channel_worker, {channel_worker, start_link, []}, 62 | Restart, 63 | Shutdown, 64 | Type, 65 | [channel_worker]}, 66 | 67 | {ok, {Options, [Worker]}}. 68 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/idea.css: -------------------------------------------------------------------------------- 1 | /* 2 | 3 | Intellij Idea-like styling (c) Vasily Polovnyov 4 | 5 | */ 6 | 7 | .hljs { 8 | display: block; 9 | overflow-x: auto; 10 | padding: 0.5em; 11 | color: #000; 12 | background: #fff; 13 | -webkit-text-size-adjust: none; 14 | } 15 | 16 | .hljs-subst, 17 | .hljs-title, 18 | .json .hljs-value { 19 | font-weight: normal; 20 | color: #000; 21 | } 22 | 23 | .hljs-comment, 24 | .diff .hljs-header { 25 | color: #808080; 26 | font-style: italic; 27 | } 28 | 29 | .hljs-annotation, 30 | .hljs-decorator, 31 | .hljs-preprocessor, 32 | .hljs-pragma, 33 | .hljs-doctype, 34 | .hljs-pi, 35 | .hljs-chunk, 36 | .hljs-shebang, 37 | .apache .hljs-cbracket, 38 | .hljs-prompt, 39 | .http .hljs-title { 40 | color: #808000; 41 | } 42 | 43 | .hljs-tag, 44 | .hljs-pi { 45 | background: #efefef; 46 | } 47 | 48 | .hljs-tag .hljs-title, 49 | .hljs-id, 50 | .hljs-attr_selector, 51 | .hljs-pseudo, 52 | .hljs-literal, 53 | .hljs-keyword, 54 | .hljs-hexcolor, 55 | .css .hljs-function, 56 | .ini .hljs-title, 57 | .css .hljs-class, 58 | .hljs-list .hljs-keyword, 59 | .nginx .hljs-title, 60 | .tex .hljs-command, 61 | .hljs-request, 62 | .hljs-status { 63 | font-weight: bold; 64 | color: #000080; 65 | } 66 | 67 | .hljs-attribute, 68 | .hljs-rule .hljs-keyword, 69 | .hljs-number, 70 | .hljs-date, 71 | .hljs-regexp, 72 | .tex .hljs-special { 73 | font-weight: bold; 74 | color: #0000ff; 75 | } 76 | 77 | .hljs-number, 78 | .hljs-regexp { 79 | font-weight: normal; 80 | } 81 | 82 | .hljs-string, 83 | .hljs-value, 84 | .hljs-filter .hljs-argument, 85 | .css .hljs-function .hljs-params, 86 | .apache .hljs-tag { 87 | color: #008000; 88 | font-weight: bold; 89 | } 90 | 91 | .hljs-symbol, 92 | .ruby .hljs-symbol .hljs-string, 93 | .hljs-char, 94 | .tex .hljs-formula { 95 | color: #000; 96 | background: #d0eded; 97 | font-style: italic; 98 | } 99 | 100 | .hljs-doctag { 101 | text-decoration: underline; 102 | } 103 | 104 | .hljs-variable, 105 | .hljs-envvar, 106 | .apache .hljs-sqbracket, 107 | .nginx .hljs-built_in, 108 | .hljs-name { 109 | color: #660e7a; 110 | } 111 | 112 | .hljs-addition { 113 | background: #baeeba; 114 | } 115 | 116 | .hljs-deletion { 117 | background: #ffc8bd; 118 | } 119 | 120 | .diff .hljs-change { 121 | background: #bccff9; 122 | } 123 | -------------------------------------------------------------------------------- /doc/overview.edoc: -------------------------------------------------------------------------------- 1 | %% -*- tab-width: 4;erlang-indent-level: 4;indent-tabs-mode: nil -*- 2 | %% ex: ft=erlang ts=4 sw=4 et 3 | %% Licensed under the Apache License, Version 2.0 (the "License"); you may not 4 | %% use this file except in compliance with the License. You may obtain a copy of 5 | %% the License at 6 | %% 7 | %% http://www.apache.org/licenses/LICENSE-2.0 8 | %% 9 | %% Unless required by applicable law or agreed to in writing, software 10 | %% distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | %% WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | %% License for the specific language governing permissions and limitations under 13 | %% the License. 14 | 15 | @copyright 2014-2038 SkunkWerks GmbH 16 | @version GITVERSION 17 | @title Swirl -- a Multi-Peer Streaming Media Platform 18 | 19 | @doc 20 | 21 | ## Overview 22 | 23 | Swirl is an implementation of the IETF [PPSP] protocol, [RFC7574] in 24 | Erlang/OTP, and released under the [ALv2] license. 25 | 26 | ## Description 27 | 28 | > The Peer-to-Peer Streaming Peer Protocol (PPSPP) is a protocol for 29 | disseminating the same content to a group of interested parties in a 30 | streaming fashion. PPSPP supports streaming of both prerecorded (on- demand) 31 | and live audio/video content. It is based on the peer-to- peer paradigm, 32 | where clients consuming the content are put on equal footing with the 33 | servers initially providing the content, to create a system where everyone 34 | can potentially provide upload bandwidth. It has been designed to provide 35 | short time-till-playback for the end user and to prevent disruption of the 36 | streams by malicious peers. PPSPP has also been designed to be flexible and 37 | extensible. It can use different mechanisms to optimize peer uploading, 38 | prevent freeriding, and work with different peer discovery schemes 39 | (centralized trackers or Distributed Hash Tables). It supports multiple 40 | methods for content integrity protection and chunk addressing. Designed as a 41 | generic protocol that can run on top of various transport protocols, it 42 | currently runs on top of UDP using Low Extra Delay Background Transport 43 | (LEDBAT) for congestion control. 44 | 45 | > -- http://www.rfc-editor.org/info/rfc7574 46 | 47 | [ALv2]: http://www.apache.org/licenses/LICENSE-2.0.html 48 | [PPSP]: https://datatracker.ietf.org/doc/rfc7574/ 49 | [RFC7574]: https://tools.ietf.org/html/rfc7574 50 | 51 | @end 52 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/zenburn.css: -------------------------------------------------------------------------------- 1 | /* 2 | 3 | Zenburn style from voldmar.ru (c) Vladimir Epifanov 4 | based on dark.css by Ivan Sagalaev 5 | 6 | */ 7 | 8 | .hljs { 9 | display: block; 10 | overflow-x: auto; 11 | padding: 0.5em; 12 | background: #3f3f3f; 13 | color: #dcdcdc; 14 | -webkit-text-size-adjust: none; 15 | } 16 | 17 | .hljs-keyword, 18 | .hljs-tag, 19 | .css .hljs-class, 20 | .css .hljs-id, 21 | .lisp .hljs-title, 22 | .nginx .hljs-title, 23 | .hljs-request, 24 | .hljs-status, 25 | .clojure .hljs-attribute { 26 | color: #e3ceab; 27 | } 28 | 29 | .django .hljs-template_tag, 30 | .django .hljs-variable, 31 | .django .hljs-filter .hljs-argument { 32 | color: #dcdcdc; 33 | } 34 | 35 | .hljs-number, 36 | .hljs-date { 37 | color: #8cd0d3; 38 | } 39 | 40 | .dos .hljs-envvar, 41 | .dos .hljs-stream, 42 | .hljs-variable, 43 | .apache .hljs-sqbracket, 44 | .hljs-name { 45 | color: #efdcbc; 46 | } 47 | 48 | .dos .hljs-flow, 49 | .diff .hljs-change, 50 | .python .exception, 51 | .python .hljs-built_in, 52 | .hljs-literal, 53 | .tex .hljs-special { 54 | color: #efefaf; 55 | } 56 | 57 | .diff .hljs-chunk, 58 | .hljs-subst { 59 | color: #8f8f8f; 60 | } 61 | 62 | .dos .hljs-keyword, 63 | .hljs-decorator, 64 | .hljs-title, 65 | .hljs-type, 66 | .diff .hljs-header, 67 | .ruby .hljs-class .hljs-parent, 68 | .apache .hljs-tag, 69 | .nginx .hljs-built_in, 70 | .tex .hljs-command, 71 | .hljs-prompt { 72 | color: #efef8f; 73 | } 74 | 75 | .dos .hljs-winutils, 76 | .ruby .hljs-symbol, 77 | .ruby .hljs-symbol .hljs-string, 78 | .ruby .hljs-string { 79 | color: #dca3a3; 80 | } 81 | 82 | .diff .hljs-deletion, 83 | .hljs-string, 84 | .hljs-tag .hljs-value, 85 | .hljs-preprocessor, 86 | .hljs-pragma, 87 | .hljs-built_in, 88 | .smalltalk .hljs-class, 89 | .smalltalk .hljs-localvars, 90 | .smalltalk .hljs-array, 91 | .css .hljs-rule .hljs-value, 92 | .hljs-attr_selector, 93 | .hljs-pseudo, 94 | .apache .hljs-cbracket, 95 | .tex .hljs-formula, 96 | .coffeescript .hljs-attribute { 97 | color: #cc9393; 98 | } 99 | 100 | .hljs-shebang, 101 | .diff .hljs-addition, 102 | .hljs-comment, 103 | .hljs-annotation, 104 | .hljs-pi, 105 | .hljs-doctype { 106 | color: #7f9f7f; 107 | } 108 | 109 | .coffeescript .javascript, 110 | .javascript .xml, 111 | .tex .hljs-formula, 112 | .xml .javascript, 113 | .xml .vbscript, 114 | .xml .css, 115 | .xml .hljs-cdata { 116 | opacity: 0.5; 117 | } 118 | 119 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/magula.css: -------------------------------------------------------------------------------- 1 | /* 2 | Description: Magula style for highligh.js 3 | Author: Ruslan Keba 4 | Website: http://rukeba.com/ 5 | Version: 1.0 6 | Date: 2009-01-03 7 | Music: Aphex Twin / Xtal 8 | */ 9 | 10 | .hljs { 11 | display: block; 12 | overflow-x: auto; 13 | padding: 0.5em; 14 | background-color: #f4f4f4; 15 | -webkit-text-size-adjust: none; 16 | } 17 | 18 | .hljs, 19 | .hljs-subst { 20 | color: black; 21 | } 22 | 23 | .hljs-string, 24 | .hljs-title, 25 | .hljs-parent, 26 | .hljs-tag .hljs-value, 27 | .hljs-rule .hljs-value, 28 | .hljs-preprocessor, 29 | .hljs-pragma, 30 | .ruby .hljs-symbol, 31 | .ruby .hljs-symbol .hljs-string, 32 | .hljs-template_tag, 33 | .django .hljs-variable, 34 | .smalltalk .hljs-class, 35 | .hljs-addition, 36 | .hljs-flow, 37 | .hljs-stream, 38 | .bash .hljs-variable, 39 | .apache .hljs-cbracket, 40 | .coffeescript .hljs-attribute { 41 | color: #050; 42 | } 43 | 44 | .hljs-comment, 45 | .hljs-annotation, 46 | .diff .hljs-header, 47 | .hljs-chunk { 48 | color: #777; 49 | } 50 | 51 | .hljs-number, 52 | .hljs-date, 53 | .hljs-regexp, 54 | .hljs-literal, 55 | .hljs-name, 56 | .smalltalk .hljs-symbol, 57 | .smalltalk .hljs-char, 58 | .hljs-change, 59 | .tex .hljs-special { 60 | color: #800; 61 | } 62 | 63 | .hljs-label, 64 | .ruby .hljs-string, 65 | .hljs-decorator, 66 | .hljs-filter .hljs-argument, 67 | .hljs-localvars, 68 | .hljs-array, 69 | .hljs-attr_selector, 70 | .hljs-pseudo, 71 | .hljs-pi, 72 | .hljs-doctype, 73 | .hljs-deletion, 74 | .hljs-envvar, 75 | .hljs-shebang, 76 | .apache .hljs-sqbracket, 77 | .nginx .hljs-built_in, 78 | .tex .hljs-formula, 79 | .hljs-prompt, 80 | .clojure .hljs-attribute { 81 | color: #00e; 82 | } 83 | 84 | .hljs-keyword, 85 | .hljs-id, 86 | .hljs-doctag, 87 | .hljs-title, 88 | .hljs-built_in, 89 | .smalltalk .hljs-class, 90 | .hljs-winutils, 91 | .bash .hljs-variable, 92 | .apache .hljs-tag, 93 | .xml .hljs-tag, 94 | .tex .hljs-command, 95 | .hljs-request, 96 | .hljs-status { 97 | font-weight: bold; 98 | color: navy; 99 | } 100 | 101 | .nginx .hljs-built_in { 102 | font-weight: normal; 103 | } 104 | 105 | .coffeescript .javascript, 106 | .javascript .xml, 107 | .tex .hljs-formula, 108 | .xml .javascript, 109 | .xml .vbscript, 110 | .xml .css, 111 | .xml .hljs-cdata { 112 | opacity: 0.5; 113 | } 114 | 115 | /* --- */ 116 | .apache .hljs-tag { 117 | font-weight: bold; 118 | color: blue; 119 | } 120 | 121 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/school_book.css: -------------------------------------------------------------------------------- 1 | /* 2 | 3 | School Book style from goldblog.com.ua (c) Zaripov Yura 4 | 5 | */ 6 | 7 | .hljs { 8 | display: block; 9 | overflow-x: auto; 10 | padding: 15px 0.5em 0.5em 30px; 11 | font-size: 11px !important; 12 | line-height:16px !important; 13 | -webkit-text-size-adjust: none; 14 | } 15 | 16 | pre{ 17 | background:#f6f6ae url(./school_book.png); 18 | border-top: solid 2px #d2e8b9; 19 | border-bottom: solid 1px #d2e8b9; 20 | } 21 | 22 | .hljs-keyword, 23 | .hljs-literal, 24 | .hljs-change, 25 | .hljs-winutils, 26 | .hljs-flow, 27 | .nginx .hljs-title, 28 | .tex .hljs-special { 29 | color:#005599; 30 | font-weight:bold; 31 | } 32 | 33 | .hljs, 34 | .hljs-subst, 35 | .hljs-tag .hljs-keyword { 36 | color: #3e5915; 37 | } 38 | 39 | .hljs-string, 40 | .hljs-title, 41 | .hljs-type, 42 | .hljs-tag .hljs-value, 43 | .css .hljs-rule .hljs-value, 44 | .hljs-preprocessor, 45 | .hljs-pragma, 46 | .ruby .hljs-symbol, 47 | .ruby .hljs-symbol .hljs-string, 48 | .ruby .hljs-class .hljs-parent, 49 | .hljs-built_in, 50 | .django .hljs-template_tag, 51 | .django .hljs-variable, 52 | .smalltalk .hljs-class, 53 | .ruby .hljs-string, 54 | .django .hljs-filter .hljs-argument, 55 | .smalltalk .hljs-localvars, 56 | .smalltalk .hljs-array, 57 | .hljs-attr_selector, 58 | .hljs-pseudo, 59 | .hljs-addition, 60 | .hljs-stream, 61 | .hljs-envvar, 62 | .apache .hljs-tag, 63 | .apache .hljs-cbracket, 64 | .nginx .hljs-built_in, 65 | .tex .hljs-command, 66 | .coffeescript .hljs-attribute, 67 | .hljs-name { 68 | color: #2c009f; 69 | } 70 | 71 | .hljs-comment, 72 | .hljs-annotation, 73 | .hljs-decorator, 74 | .hljs-pi, 75 | .hljs-doctype, 76 | .hljs-deletion, 77 | .hljs-shebang, 78 | .apache .hljs-sqbracket { 79 | color: #e60415; 80 | } 81 | 82 | .hljs-keyword, 83 | .hljs-literal, 84 | .css .hljs-id, 85 | .hljs-doctag, 86 | .hljs-title, 87 | .hljs-type, 88 | .vbscript .hljs-built_in, 89 | .rsl .hljs-built_in, 90 | .smalltalk .hljs-class, 91 | .xml .hljs-tag .hljs-title, 92 | .diff .hljs-header, 93 | .hljs-chunk, 94 | .hljs-winutils, 95 | .bash .hljs-variable, 96 | .apache .hljs-tag, 97 | .tex .hljs-command, 98 | .hljs-request, 99 | .hljs-status { 100 | font-weight: bold; 101 | } 102 | 103 | .coffeescript .javascript, 104 | .javascript .xml, 105 | .tex .hljs-formula, 106 | .xml .javascript, 107 | .xml .vbscript, 108 | .xml .css, 109 | .xml .hljs-cdata { 110 | opacity: 0.5; 111 | } 112 | -------------------------------------------------------------------------------- /doc/blog/fresh_start.md: -------------------------------------------------------------------------------- 1 | --- 2 | categories: 3 | - blog 4 | date: 2015-06-02T23:34:09+02:00 5 | tags: 6 | - update 7 | - musing 8 | title: A Fresh Start 9 | --- 10 | 11 | The last few months have been pretty well occupied with personal stuff -- 12 | a long trip back to New Zealand, and the arrival of a new baby in the 13 | family. Not surprisingly, `swirl` has been on the back burner during this 14 | time. 15 | 16 | ## Refocus 17 | 18 | The break gave me ample time to think about what I'm hoping to achieve with 19 | the project, and how best to move things along, as progress has been slower 20 | than I would like in and around life and family. 21 | 22 | Pragmatically I'm getting around 3-4 hours a day of focused work time in, and 23 | this has changed the timelines quite a bit. To that end I will be completing 24 | the design documents first and then organising some additional Erlang help 25 | to move things along. 26 | 27 | ## This Week 28 | 29 | Most of this week has been occupied with new baby related things, but in and 30 | around that, I've integrated the excellent [edown](https://github.com/uwiger/edown) 31 | documentation library into the project, and set it up to produce the very 32 | pretty [API]({{< relref "api/index.md" >}}) pages. These are generated 33 | directly from the Erlang code, and there are still quite a few rough edges 34 | in there to clean up due to missing or invalid tagging on my part. I'm 35 | really pleased with the results however, as they include both `data types` 36 | and `function docs` in a very readable fashion. 37 | 38 | ## Current State 39 | 40 | Work to date has been around the overall structure of the application, in 41 | particular what I think of now as the "Core" of swirl - the OTP processes 42 | or daemons that own and manage the state for the given peers, swarms, and 43 | the corresponding channels that weave them together. 44 | 45 | This is largely complete, although some changes will inevitably be required 46 | as the other modules are done, the overall structure should remain the same. 47 | See the [OTP supervision guide]({{< relref "supervision.md" >}}) for the 48 | full story. 49 | 50 | Unfortunately this work isn't specifically in the original NLNet grant, 51 | however doing it has really crystallised my thinking around what data and 52 | state *needs* to be managed, and what can be maintained or used within a 53 | given process. 54 | 55 | ## Next Up 56 | 57 | This and next week's focus is to take the current codebase and turn it into 58 | a design document for the other components to build off and refer to. 59 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/atelier-cave.dark.css: -------------------------------------------------------------------------------- 1 | /* Base16 Atelier Cave Dark - Theme */ 2 | /* by Bram de Haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/cave) */ 3 | /* Original Base16 color scheme by Chris Kempson (https://github.com/chriskempson/base16) */ 4 | 5 | /* Atelier-Cave Comment */ 6 | .hljs-comment { 7 | color: #7e7887; 8 | } 9 | 10 | /* Atelier-Cave Red */ 11 | .hljs-variable, 12 | .hljs-attribute, 13 | .hljs-tag, 14 | .hljs-regexp, 15 | .hljs-name, 16 | .ruby .hljs-constant, 17 | .xml .hljs-tag .hljs-title, 18 | .xml .hljs-pi, 19 | .xml .hljs-doctype, 20 | .html .hljs-doctype, 21 | .css .hljs-id, 22 | .css .hljs-class, 23 | .css .hljs-pseudo { 24 | color: #be4678; 25 | } 26 | 27 | /* Atelier-Cave Orange */ 28 | .hljs-number, 29 | .hljs-preprocessor, 30 | .hljs-built_in, 31 | .hljs-literal, 32 | .hljs-params, 33 | .hljs-constant { 34 | color: #aa573c; 35 | } 36 | 37 | /* Atelier-Cave Yellow */ 38 | .ruby .hljs-class .hljs-title, 39 | .css .hljs-rule .hljs-attribute { 40 | color: #a06e3b; 41 | } 42 | 43 | /* Atelier-Cave Green */ 44 | .hljs-string, 45 | .hljs-value, 46 | .hljs-inheritance, 47 | .hljs-header, 48 | .ruby .hljs-symbol, 49 | .xml .hljs-cdata { 50 | color: #2a9292; 51 | } 52 | 53 | /* Atelier-Cave Aqua */ 54 | .hljs-title, 55 | .css .hljs-hexcolor { 56 | color: #398bc6; 57 | } 58 | 59 | /* Atelier-Cave Blue */ 60 | .hljs-function, 61 | .python .hljs-decorator, 62 | .python .hljs-title, 63 | .ruby .hljs-function .hljs-title, 64 | .ruby .hljs-title .hljs-keyword, 65 | .perl .hljs-sub, 66 | .javascript .hljs-title, 67 | .coffeescript .hljs-title { 68 | color: #576ddb; 69 | } 70 | 71 | /* Atelier-Cave Purple */ 72 | .hljs-keyword, 73 | .javascript .hljs-function { 74 | color: #955ae7; 75 | } 76 | 77 | .diff .hljs-deletion, 78 | .diff .hljs-addition { 79 | color: #19171c; 80 | display: inline-block; 81 | width: 100%; 82 | } 83 | 84 | .diff .hljs-deletion { 85 | background-color: #be4678; 86 | } 87 | 88 | .diff .hljs-addition { 89 | background-color: #2a9292; 90 | } 91 | 92 | .diff .hljs-change { 93 | color: #576ddb; 94 | } 95 | 96 | .hljs { 97 | display: block; 98 | overflow-x: auto; 99 | background: #19171c; 100 | color: #8b8792; 101 | padding: 0.5em; 102 | -webkit-text-size-adjust: none; 103 | } 104 | 105 | .coffeescript .javascript, 106 | .javascript .xml, 107 | .tex .hljs-formula, 108 | .xml .javascript, 109 | .xml .vbscript, 110 | .xml .css, 111 | .xml .hljs-cdata { 112 | opacity: 0.5; 113 | } 114 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/atelier-cave.light.css: -------------------------------------------------------------------------------- 1 | /* Base16 Atelier Cave Light - Theme */ 2 | /* by Bram de Haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/cave) */ 3 | /* Original Base16 color scheme by Chris Kempson (https://github.com/chriskempson/base16) */ 4 | 5 | /* Atelier-Cave Comment */ 6 | .hljs-comment { 7 | color: #655f6d; 8 | } 9 | 10 | /* Atelier-Cave Red */ 11 | .hljs-variable, 12 | .hljs-attribute, 13 | .hljs-tag, 14 | .hljs-regexp, 15 | .hljs-name, 16 | .ruby .hljs-constant, 17 | .xml .hljs-tag .hljs-title, 18 | .xml .hljs-pi, 19 | .xml .hljs-doctype, 20 | .html .hljs-doctype, 21 | .css .hljs-id, 22 | .css .hljs-class, 23 | .css .hljs-pseudo { 24 | color: #be4678; 25 | } 26 | 27 | /* Atelier-Cave Orange */ 28 | .hljs-number, 29 | .hljs-preprocessor, 30 | .hljs-built_in, 31 | .hljs-literal, 32 | .hljs-params, 33 | .hljs-constant { 34 | color: #aa573c; 35 | } 36 | 37 | /* Atelier-Cave Yellow */ 38 | .ruby .hljs-class .hljs-title, 39 | .css .hljs-rule .hljs-attribute { 40 | color: #a06e3b; 41 | } 42 | 43 | /* Atelier-Cave Green */ 44 | .hljs-string, 45 | .hljs-value, 46 | .hljs-inheritance, 47 | .hljs-header, 48 | .ruby .hljs-symbol, 49 | .xml .hljs-cdata { 50 | color: #2a9292; 51 | } 52 | 53 | /* Atelier-Cave Aqua */ 54 | .hljs-title, 55 | .css .hljs-hexcolor { 56 | color: #398bc6; 57 | } 58 | 59 | /* Atelier-Cave Blue */ 60 | .hljs-function, 61 | .python .hljs-decorator, 62 | .python .hljs-title, 63 | .ruby .hljs-function .hljs-title, 64 | .ruby .hljs-title .hljs-keyword, 65 | .perl .hljs-sub, 66 | .javascript .hljs-title, 67 | .coffeescript .hljs-title { 68 | color: #576ddb; 69 | } 70 | 71 | /* Atelier-Cave Purple */ 72 | .hljs-keyword, 73 | .javascript .hljs-function { 74 | color: #955ae7; 75 | } 76 | 77 | .diff .hljs-deletion, 78 | .diff .hljs-addition { 79 | color: #19171c; 80 | display: inline-block; 81 | width: 100%; 82 | } 83 | 84 | .diff .hljs-deletion { 85 | background-color: #be4678; 86 | } 87 | 88 | .diff .hljs-addition { 89 | background-color: #2a9292; 90 | } 91 | 92 | .diff .hljs-change { 93 | color: #576ddb; 94 | } 95 | 96 | .hljs { 97 | display: block; 98 | overflow-x: auto; 99 | background: #efecf4; 100 | color: #585260; 101 | padding: 0.5em; 102 | -webkit-text-size-adjust: none; 103 | } 104 | 105 | .coffeescript .javascript, 106 | .javascript .xml, 107 | .tex .hljs-formula, 108 | .xml .javascript, 109 | .xml .vbscript, 110 | .xml .css, 111 | .xml .hljs-cdata { 112 | opacity: 0.5; 113 | } 114 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/docco.css: -------------------------------------------------------------------------------- 1 | /* 2 | Docco style used in http://jashkenas.github.com/docco/ converted by Simon Madine (@thingsinjars) 3 | */ 4 | 5 | .hljs { 6 | display: block; 7 | overflow-x: auto; 8 | padding: 0.5em; 9 | color: #000; 10 | background: #f8f8ff; 11 | -webkit-text-size-adjust: none; 12 | } 13 | 14 | .hljs-comment, 15 | .diff .hljs-header { 16 | color: #408080; 17 | font-style: italic; 18 | } 19 | 20 | .hljs-keyword, 21 | .assignment, 22 | .hljs-literal, 23 | .css .rule .hljs-keyword, 24 | .hljs-winutils, 25 | .javascript .hljs-title, 26 | .lisp .hljs-title, 27 | .hljs-subst { 28 | color: #954121; 29 | } 30 | 31 | .hljs-number, 32 | .hljs-hexcolor { 33 | color: #40a070; 34 | } 35 | 36 | .hljs-string, 37 | .hljs-tag .hljs-value, 38 | .hljs-doctag, 39 | .tex .hljs-formula, 40 | .hljs-name { 41 | color: #219161; 42 | } 43 | 44 | .hljs-title, 45 | .hljs-id { 46 | color: #19469d; 47 | } 48 | .hljs-params { 49 | color: #00f; 50 | } 51 | 52 | .javascript .hljs-title, 53 | .lisp .hljs-title, 54 | .hljs-subst { 55 | font-weight: normal; 56 | } 57 | 58 | .hljs-class .hljs-title, 59 | .haskell .hljs-label, 60 | .tex .hljs-command { 61 | color: #458; 62 | font-weight: bold; 63 | } 64 | 65 | .hljs-tag, 66 | .hljs-tag .hljs-title, 67 | .hljs-rule .hljs-property, 68 | .django .hljs-tag .hljs-keyword { 69 | color: #000080; 70 | font-weight: normal; 71 | } 72 | 73 | .hljs-attribute, 74 | .hljs-variable, 75 | .instancevar, 76 | .lisp .hljs-body { 77 | color: #008080; 78 | } 79 | 80 | .hljs-regexp { 81 | color: #b68; 82 | } 83 | 84 | .hljs-class { 85 | color: #458; 86 | font-weight: bold; 87 | } 88 | 89 | .hljs-symbol, 90 | .ruby .hljs-symbol .hljs-string, 91 | .ruby .hljs-symbol .hljs-keyword, 92 | .ruby .hljs-symbol .keymethods, 93 | .lisp .hljs-keyword, 94 | .tex .hljs-special, 95 | .input_number { 96 | color: #990073; 97 | } 98 | 99 | .builtin, 100 | .constructor, 101 | .hljs-built_in, 102 | .lisp .hljs-title { 103 | color: #0086b3; 104 | } 105 | 106 | .hljs-preprocessor, 107 | .hljs-pragma, 108 | .hljs-pi, 109 | .hljs-doctype, 110 | .hljs-shebang, 111 | .hljs-cdata { 112 | color: #999; 113 | font-weight: bold; 114 | } 115 | 116 | .hljs-deletion { 117 | background: #fdd; 118 | } 119 | 120 | .hljs-addition { 121 | background: #dfd; 122 | } 123 | 124 | .diff .hljs-change { 125 | background: #0086b3; 126 | } 127 | 128 | .hljs-chunk { 129 | color: #aaa; 130 | } 131 | 132 | .tex .hljs-formula { 133 | opacity: 0.5; 134 | } 135 | -------------------------------------------------------------------------------- /test/swirl_SUITE.erl: -------------------------------------------------------------------------------- 1 | %% -*- tab-width: 4;erlang-indent-level: 4;indent-tabs-mode: nil -*- 2 | %% ex: ft=erlang ts=4 sw=4 et 3 | %% Licensed under the Apache License, Version 2.0 (the "License"); you may not 4 | %% use this file except in compliance with the License. You may obtain a copy of 5 | %% the License at 6 | %% 7 | %% http://www.apache.org/licenses/LICENSE-2.0 8 | %% 9 | %% Unless required by applicable law or agreed to in writing, software 10 | %% distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | %% WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | %% License for the specific language governing permissions and limitations under 13 | %% the License. 14 | 15 | %% @doc Library for PPSPP over UDP, aka Swift protocol 16 | %%

This module implements a library of functions necessary to 17 | %% handle the wire-protocol of PPSPP over UDP, including 18 | %% functions for encoding and decoding messages.

19 | %% @end 20 | 21 | -module(swirl_SUITE). 22 | -include("swirl.hrl"). 23 | -include_lib("common_test/include/ct.hrl"). 24 | 25 | -export([all/0]). 26 | -export([start_swarm/1, 27 | stop_swarm/1, 28 | start_and_stop_swarm_with_random_peer/1 29 | ]). 30 | 31 | -spec all() -> [atom()]. 32 | all() -> [start_swarm, 33 | stop_swarm, 34 | start_and_stop_swarm_with_random_peer 35 | ]. 36 | 37 | -spec start_swarm(any()) -> true. 38 | start_swarm(_Config) -> 39 | swirl:start(), 40 | Swarm_Options = ppspp_options:use_default_options("c39e"), 41 | {ok, Worker} = swirl:start_swarm(Swarm_Options), 42 | timer:sleep(100), 43 | true = is_process_alive(Worker). 44 | 45 | -spec stop_swarm(any()) -> false. 46 | stop_swarm(_Config) -> 47 | Swarm_Options = ppspp_options:use_default_options("c39e"), 48 | Swarm_id = ppspp_options:get_swarm_id(Swarm_Options), 49 | {ok, Worker} = swarm_worker:where_is(Swarm_id), 50 | swirl:stop_swarm(Swarm_id), 51 | timer:sleep(100), 52 | false = is_process_alive(Worker). 53 | 54 | -spec start_and_stop_swarm_with_random_peer(any()) -> true. 55 | start_and_stop_swarm_with_random_peer(_Config) -> 56 | Hash = "c898", 57 | {ok, Swarm, Peer, Port, _URL} = swirl:start(Hash), 58 | %% wait a bit and check the peer is up 59 | timer:sleep(100), 60 | true = is_process_alive(Peer), 61 | swirl:stop_peer(Port), 62 | timer:sleep(100), 63 | false = is_process_alive(Peer), 64 | %% now the swarm 65 | true = is_process_alive(Swarm), 66 | swirl:stop_swarm(Hash), 67 | timer:sleep(100), 68 | false = is_process_alive(Swarm). 69 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/atelier-estuary.dark.css: -------------------------------------------------------------------------------- 1 | /* Base16 Atelier Estuary Dark - Theme */ 2 | /* by Bram de Haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/estuary) */ 3 | /* Original Base16 color scheme by Chris Kempson (https://github.com/chriskempson/base16) */ 4 | 5 | /* Atelier-Estuary Comment */ 6 | .hljs-comment { 7 | color: #878573; 8 | } 9 | 10 | /* Atelier-Estuary Red */ 11 | .hljs-variable, 12 | .hljs-attribute, 13 | .hljs-tag, 14 | .hljs-regexp, 15 | .hljs-name, 16 | .ruby .hljs-constant, 17 | .xml .hljs-tag .hljs-title, 18 | .xml .hljs-pi, 19 | .xml .hljs-doctype, 20 | .html .hljs-doctype, 21 | .css .hljs-id, 22 | .css .hljs-class, 23 | .css .hljs-pseudo { 24 | color: #ba6236; 25 | } 26 | 27 | /* Atelier-Estuary Orange */ 28 | .hljs-number, 29 | .hljs-preprocessor, 30 | .hljs-built_in, 31 | .hljs-literal, 32 | .hljs-params, 33 | .hljs-constant { 34 | color: #ae7313; 35 | } 36 | 37 | /* Atelier-Estuary Yellow */ 38 | .ruby .hljs-class .hljs-title, 39 | .css .hljs-rule .hljs-attribute { 40 | color: #a5980d; 41 | } 42 | 43 | /* Atelier-Estuary Green */ 44 | .hljs-string, 45 | .hljs-value, 46 | .hljs-inheritance, 47 | .hljs-header, 48 | .ruby .hljs-symbol, 49 | .xml .hljs-cdata { 50 | color: #7d9726; 51 | } 52 | 53 | /* Atelier-Estuary Aqua */ 54 | .hljs-title, 55 | .css .hljs-hexcolor { 56 | color: #5b9d48; 57 | } 58 | 59 | /* Atelier-Estuary Blue */ 60 | .hljs-function, 61 | .python .hljs-decorator, 62 | .python .hljs-title, 63 | .ruby .hljs-function .hljs-title, 64 | .ruby .hljs-title .hljs-keyword, 65 | .perl .hljs-sub, 66 | .javascript .hljs-title, 67 | .coffeescript .hljs-title { 68 | color: #36a166; 69 | } 70 | 71 | /* Atelier-Estuary Purple */ 72 | .hljs-keyword, 73 | .javascript .hljs-function { 74 | color: #5f9182; 75 | } 76 | 77 | .diff .hljs-deletion, 78 | .diff .hljs-addition { 79 | color: #22221b; 80 | display: inline-block; 81 | width: 100%; 82 | } 83 | 84 | .diff .hljs-deletion { 85 | background-color: #ba6236; 86 | } 87 | 88 | .diff .hljs-addition { 89 | background-color: #7d9726; 90 | } 91 | 92 | .diff .hljs-change { 93 | color: #36a166; 94 | } 95 | 96 | .hljs { 97 | display: block; 98 | overflow-x: auto; 99 | background: #22221b; 100 | color: #929181; 101 | padding: 0.5em; 102 | -webkit-text-size-adjust: none; 103 | } 104 | 105 | .coffeescript .javascript, 106 | .javascript .xml, 107 | .tex .hljs-formula, 108 | .xml .javascript, 109 | .xml .vbscript, 110 | .xml .css, 111 | .xml .hljs-cdata { 112 | opacity: 0.5; 113 | } 114 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/atelier-estuary.light.css: -------------------------------------------------------------------------------- 1 | /* Base16 Atelier Estuary Light - Theme */ 2 | /* by Bram de Haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/estuary) */ 3 | /* Original Base16 color scheme by Chris Kempson (https://github.com/chriskempson/base16) */ 4 | 5 | /* Atelier-Estuary Comment */ 6 | .hljs-comment { 7 | color: #6c6b5a; 8 | } 9 | 10 | /* Atelier-Estuary Red */ 11 | .hljs-variable, 12 | .hljs-attribute, 13 | .hljs-tag, 14 | .hljs-regexp, 15 | .hljs-name, 16 | .ruby .hljs-constant, 17 | .xml .hljs-tag .hljs-title, 18 | .xml .hljs-pi, 19 | .xml .hljs-doctype, 20 | .html .hljs-doctype, 21 | .css .hljs-id, 22 | .css .hljs-class, 23 | .css .hljs-pseudo { 24 | color: #ba6236; 25 | } 26 | 27 | /* Atelier-Estuary Orange */ 28 | .hljs-number, 29 | .hljs-preprocessor, 30 | .hljs-built_in, 31 | .hljs-literal, 32 | .hljs-params, 33 | .hljs-constant { 34 | color: #ae7313; 35 | } 36 | 37 | /* Atelier-Estuary Yellow */ 38 | .ruby .hljs-class .hljs-title, 39 | .css .hljs-rule .hljs-attribute { 40 | color: #a5980d; 41 | } 42 | 43 | /* Atelier-Estuary Green */ 44 | .hljs-string, 45 | .hljs-value, 46 | .hljs-inheritance, 47 | .hljs-header, 48 | .ruby .hljs-symbol, 49 | .xml .hljs-cdata { 50 | color: #7d9726; 51 | } 52 | 53 | /* Atelier-Estuary Aqua */ 54 | .hljs-title, 55 | .css .hljs-hexcolor { 56 | color: #5b9d48; 57 | } 58 | 59 | /* Atelier-Estuary Blue */ 60 | .hljs-function, 61 | .python .hljs-decorator, 62 | .python .hljs-title, 63 | .ruby .hljs-function .hljs-title, 64 | .ruby .hljs-title .hljs-keyword, 65 | .perl .hljs-sub, 66 | .javascript .hljs-title, 67 | .coffeescript .hljs-title { 68 | color: #36a166; 69 | } 70 | 71 | /* Atelier-Estuary Purple */ 72 | .hljs-keyword, 73 | .javascript .hljs-function { 74 | color: #5f9182; 75 | } 76 | 77 | .diff .hljs-deletion, 78 | .diff .hljs-addition { 79 | color: #22221b; 80 | display: inline-block; 81 | width: 100%; 82 | } 83 | 84 | .diff .hljs-deletion { 85 | background-color: #ba6236; 86 | } 87 | 88 | .diff .hljs-addition { 89 | background-color: #7d9726; 90 | } 91 | 92 | .diff .hljs-change { 93 | color: #36a166; 94 | } 95 | 96 | .hljs { 97 | display: block; 98 | overflow-x: auto; 99 | background: #f4f3ec; 100 | color: #5f5e4e; 101 | padding: 0.5em; 102 | -webkit-text-size-adjust: none; 103 | } 104 | 105 | .coffeescript .javascript, 106 | .javascript .xml, 107 | .tex .hljs-formula, 108 | .xml .javascript, 109 | .xml .vbscript, 110 | .xml .css, 111 | .xml .hljs-cdata { 112 | opacity: 0.5; 113 | } 114 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/atelier-plateau.dark.css: -------------------------------------------------------------------------------- 1 | /* Base16 Atelier Plateau Dark - Theme */ 2 | /* by Bram de Haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/plateau) */ 3 | /* Original Base16 color scheme by Chris Kempson (https://github.com/chriskempson/base16) */ 4 | 5 | /* Atelier-Plateau Comment */ 6 | .hljs-comment { 7 | color: #7e7777; 8 | } 9 | 10 | /* Atelier-Plateau Red */ 11 | .hljs-variable, 12 | .hljs-attribute, 13 | .hljs-tag, 14 | .hljs-regexp, 15 | .hljs-name, 16 | .ruby .hljs-constant, 17 | .xml .hljs-tag .hljs-title, 18 | .xml .hljs-pi, 19 | .xml .hljs-doctype, 20 | .html .hljs-doctype, 21 | .css .hljs-id, 22 | .css .hljs-class, 23 | .css .hljs-pseudo { 24 | color: #ca4949; 25 | } 26 | 27 | /* Atelier-Plateau Orange */ 28 | .hljs-number, 29 | .hljs-preprocessor, 30 | .hljs-built_in, 31 | .hljs-literal, 32 | .hljs-params, 33 | .hljs-constant { 34 | color: #b45a3c; 35 | } 36 | 37 | /* Atelier-Plateau Yellow */ 38 | .ruby .hljs-class .hljs-title, 39 | .css .hljs-rule .hljs-attribute { 40 | color: #a06e3b; 41 | } 42 | 43 | /* Atelier-Plateau Green */ 44 | .hljs-string, 45 | .hljs-value, 46 | .hljs-inheritance, 47 | .hljs-header, 48 | .ruby .hljs-symbol, 49 | .xml .hljs-cdata { 50 | color: #4b8b8b; 51 | } 52 | 53 | /* Atelier-Plateau Aqua */ 54 | .hljs-title, 55 | .css .hljs-hexcolor { 56 | color: #5485b6; 57 | } 58 | 59 | /* Atelier-Plateau Blue */ 60 | .hljs-function, 61 | .python .hljs-decorator, 62 | .python .hljs-title, 63 | .ruby .hljs-function .hljs-title, 64 | .ruby .hljs-title .hljs-keyword, 65 | .perl .hljs-sub, 66 | .javascript .hljs-title, 67 | .coffeescript .hljs-title { 68 | color: #7272ca; 69 | } 70 | 71 | /* Atelier-Plateau Purple */ 72 | .hljs-keyword, 73 | .javascript .hljs-function { 74 | color: #8464c4; 75 | } 76 | 77 | .diff .hljs-deletion, 78 | .diff .hljs-addition { 79 | color: #1b1818; 80 | display: inline-block; 81 | width: 100%; 82 | } 83 | 84 | .diff .hljs-deletion { 85 | background-color: #ca4949; 86 | } 87 | 88 | .diff .hljs-addition { 89 | background-color: #4b8b8b; 90 | } 91 | 92 | .diff .hljs-change { 93 | color: #7272ca; 94 | } 95 | 96 | .hljs { 97 | display: block; 98 | overflow-x: auto; 99 | background: #1b1818; 100 | color: #8a8585; 101 | padding: 0.5em; 102 | -webkit-text-size-adjust: none; 103 | } 104 | 105 | .coffeescript .javascript, 106 | .javascript .xml, 107 | .tex .hljs-formula, 108 | .xml .javascript, 109 | .xml .vbscript, 110 | .xml .css, 111 | .xml .hljs-cdata { 112 | opacity: 0.5; 113 | } 114 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/atelier-plateau.light.css: -------------------------------------------------------------------------------- 1 | /* Base16 Atelier Plateau Light - Theme */ 2 | /* by Bram de Haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/plateau) */ 3 | /* Original Base16 color scheme by Chris Kempson (https://github.com/chriskempson/base16) */ 4 | 5 | /* Atelier-Plateau Comment */ 6 | .hljs-comment { 7 | color: #655d5d; 8 | } 9 | 10 | /* Atelier-Plateau Red */ 11 | .hljs-variable, 12 | .hljs-attribute, 13 | .hljs-tag, 14 | .hljs-regexp, 15 | .hljs-name, 16 | .ruby .hljs-constant, 17 | .xml .hljs-tag .hljs-title, 18 | .xml .hljs-pi, 19 | .xml .hljs-doctype, 20 | .html .hljs-doctype, 21 | .css .hljs-id, 22 | .css .hljs-class, 23 | .css .hljs-pseudo { 24 | color: #ca4949; 25 | } 26 | 27 | /* Atelier-Plateau Orange */ 28 | .hljs-number, 29 | .hljs-preprocessor, 30 | .hljs-built_in, 31 | .hljs-literal, 32 | .hljs-params, 33 | .hljs-constant { 34 | color: #b45a3c; 35 | } 36 | 37 | /* Atelier-Plateau Yellow */ 38 | .ruby .hljs-class .hljs-title, 39 | .css .hljs-rule .hljs-attribute { 40 | color: #a06e3b; 41 | } 42 | 43 | /* Atelier-Plateau Green */ 44 | .hljs-string, 45 | .hljs-value, 46 | .hljs-inheritance, 47 | .hljs-header, 48 | .ruby .hljs-symbol, 49 | .xml .hljs-cdata { 50 | color: #4b8b8b; 51 | } 52 | 53 | /* Atelier-Plateau Aqua */ 54 | .hljs-title, 55 | .css .hljs-hexcolor { 56 | color: #5485b6; 57 | } 58 | 59 | /* Atelier-Plateau Blue */ 60 | .hljs-function, 61 | .python .hljs-decorator, 62 | .python .hljs-title, 63 | .ruby .hljs-function .hljs-title, 64 | .ruby .hljs-title .hljs-keyword, 65 | .perl .hljs-sub, 66 | .javascript .hljs-title, 67 | .coffeescript .hljs-title { 68 | color: #7272ca; 69 | } 70 | 71 | /* Atelier-Plateau Purple */ 72 | .hljs-keyword, 73 | .javascript .hljs-function { 74 | color: #8464c4; 75 | } 76 | 77 | .diff .hljs-deletion, 78 | .diff .hljs-addition { 79 | color: #1b1818; 80 | display: inline-block; 81 | width: 100%; 82 | } 83 | 84 | .diff .hljs-deletion { 85 | background-color: #ca4949; 86 | } 87 | 88 | .diff .hljs-addition { 89 | background-color: #4b8b8b; 90 | } 91 | 92 | .diff .hljs-change { 93 | color: #7272ca; 94 | } 95 | 96 | .hljs { 97 | display: block; 98 | overflow-x: auto; 99 | background: #f4ecec; 100 | color: #585050; 101 | padding: 0.5em; 102 | -webkit-text-size-adjust: none; 103 | } 104 | 105 | .coffeescript .javascript, 106 | .javascript .xml, 107 | .tex .hljs-formula, 108 | .xml .javascript, 109 | .xml .vbscript, 110 | .xml .css, 111 | .xml .hljs-cdata { 112 | opacity: 0.5; 113 | } 114 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/atelier-savanna.dark.css: -------------------------------------------------------------------------------- 1 | /* Base16 Atelier Savanna Dark - Theme */ 2 | /* by Bram de Haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/savanna) */ 3 | /* Original Base16 color scheme by Chris Kempson (https://github.com/chriskempson/base16) */ 4 | 5 | /* Atelier-Savanna Comment */ 6 | .hljs-comment { 7 | color: #78877d; 8 | } 9 | 10 | /* Atelier-Savanna Red */ 11 | .hljs-variable, 12 | .hljs-attribute, 13 | .hljs-tag, 14 | .hljs-regexp, 15 | .hljs-name, 16 | .ruby .hljs-constant, 17 | .xml .hljs-tag .hljs-title, 18 | .xml .hljs-pi, 19 | .xml .hljs-doctype, 20 | .html .hljs-doctype, 21 | .css .hljs-id, 22 | .css .hljs-class, 23 | .css .hljs-pseudo { 24 | color: #b16139; 25 | } 26 | 27 | /* Atelier-Savanna Orange */ 28 | .hljs-number, 29 | .hljs-preprocessor, 30 | .hljs-built_in, 31 | .hljs-literal, 32 | .hljs-params, 33 | .hljs-constant { 34 | color: #9f713c; 35 | } 36 | 37 | /* Atelier-Savanna Yellow */ 38 | .ruby .hljs-class .hljs-title, 39 | .css .hljs-rule .hljs-attribute { 40 | color: #a07e3b; 41 | } 42 | 43 | /* Atelier-Savanna Green */ 44 | .hljs-string, 45 | .hljs-value, 46 | .hljs-inheritance, 47 | .hljs-header, 48 | .ruby .hljs-symbol, 49 | .xml .hljs-cdata { 50 | color: #489963; 51 | } 52 | 53 | /* Atelier-Savanna Aqua */ 54 | .hljs-title, 55 | .css .hljs-hexcolor { 56 | color: #1c9aa0; 57 | } 58 | 59 | /* Atelier-Savanna Blue */ 60 | .hljs-function, 61 | .python .hljs-decorator, 62 | .python .hljs-title, 63 | .ruby .hljs-function .hljs-title, 64 | .ruby .hljs-title .hljs-keyword, 65 | .perl .hljs-sub, 66 | .javascript .hljs-title, 67 | .coffeescript .hljs-title { 68 | color: #478c90; 69 | } 70 | 71 | /* Atelier-Savanna Purple */ 72 | .hljs-keyword, 73 | .javascript .hljs-function { 74 | color: #55859b; 75 | } 76 | 77 | .diff .hljs-deletion, 78 | .diff .hljs-addition { 79 | color: #171c19; 80 | display: inline-block; 81 | width: 100%; 82 | } 83 | 84 | .diff .hljs-deletion { 85 | background-color: #b16139; 86 | } 87 | 88 | .diff .hljs-addition { 89 | background-color: #489963; 90 | } 91 | 92 | .diff .hljs-change { 93 | color: #478c90; 94 | } 95 | 96 | .hljs { 97 | display: block; 98 | overflow-x: auto; 99 | background: #171c19; 100 | color: #87928a; 101 | padding: 0.5em; 102 | -webkit-text-size-adjust: none; 103 | } 104 | 105 | .coffeescript .javascript, 106 | .javascript .xml, 107 | .tex .hljs-formula, 108 | .xml .javascript, 109 | .xml .vbscript, 110 | .xml .css, 111 | .xml .hljs-cdata { 112 | opacity: 0.5; 113 | } 114 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/atelier-savanna.light.css: -------------------------------------------------------------------------------- 1 | /* Base16 Atelier Savanna Light - Theme */ 2 | /* by Bram de Haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/savanna) */ 3 | /* Original Base16 color scheme by Chris Kempson (https://github.com/chriskempson/base16) */ 4 | 5 | /* Atelier-Savanna Comment */ 6 | .hljs-comment { 7 | color: #5f6d64; 8 | } 9 | 10 | /* Atelier-Savanna Red */ 11 | .hljs-variable, 12 | .hljs-attribute, 13 | .hljs-tag, 14 | .hljs-regexp, 15 | .hljs-name, 16 | .ruby .hljs-constant, 17 | .xml .hljs-tag .hljs-title, 18 | .xml .hljs-pi, 19 | .xml .hljs-doctype, 20 | .html .hljs-doctype, 21 | .css .hljs-id, 22 | .css .hljs-class, 23 | .css .hljs-pseudo { 24 | color: #b16139; 25 | } 26 | 27 | /* Atelier-Savanna Orange */ 28 | .hljs-number, 29 | .hljs-preprocessor, 30 | .hljs-built_in, 31 | .hljs-literal, 32 | .hljs-params, 33 | .hljs-constant { 34 | color: #9f713c; 35 | } 36 | 37 | /* Atelier-Savanna Yellow */ 38 | .ruby .hljs-class .hljs-title, 39 | .css .hljs-rule .hljs-attribute { 40 | color: #a07e3b; 41 | } 42 | 43 | /* Atelier-Savanna Green */ 44 | .hljs-string, 45 | .hljs-value, 46 | .hljs-inheritance, 47 | .hljs-header, 48 | .ruby .hljs-symbol, 49 | .xml .hljs-cdata { 50 | color: #489963; 51 | } 52 | 53 | /* Atelier-Savanna Aqua */ 54 | .hljs-title, 55 | .css .hljs-hexcolor { 56 | color: #1c9aa0; 57 | } 58 | 59 | /* Atelier-Savanna Blue */ 60 | .hljs-function, 61 | .python .hljs-decorator, 62 | .python .hljs-title, 63 | .ruby .hljs-function .hljs-title, 64 | .ruby .hljs-title .hljs-keyword, 65 | .perl .hljs-sub, 66 | .javascript .hljs-title, 67 | .coffeescript .hljs-title { 68 | color: #478c90; 69 | } 70 | 71 | /* Atelier-Savanna Purple */ 72 | .hljs-keyword, 73 | .javascript .hljs-function { 74 | color: #55859b; 75 | } 76 | 77 | .diff .hljs-deletion, 78 | .diff .hljs-addition { 79 | color: #171c19; 80 | display: inline-block; 81 | width: 100%; 82 | } 83 | 84 | .diff .hljs-deletion { 85 | background-color: #b16139; 86 | } 87 | 88 | .diff .hljs-addition { 89 | background-color: #489963; 90 | } 91 | 92 | .diff .hljs-change { 93 | color: #478c90; 94 | } 95 | 96 | .hljs { 97 | display: block; 98 | overflow-x: auto; 99 | background: #ecf4ee; 100 | color: #526057; 101 | padding: 0.5em; 102 | -webkit-text-size-adjust: none; 103 | } 104 | 105 | .coffeescript .javascript, 106 | .javascript .xml, 107 | .tex .hljs-formula, 108 | .xml .javascript, 109 | .xml .vbscript, 110 | .xml .css, 111 | .xml .hljs-cdata { 112 | opacity: 0.5; 113 | } 114 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/agate.css: -------------------------------------------------------------------------------- 1 | /*! 2 | * Agate by Taufik Nurrohman 3 | * ---------------------------------------------------- 4 | * 5 | * #ade5fc 6 | * #a2fca2 7 | * #c6b4f0 8 | * #d36363 9 | * #fcc28c 10 | * #fc9b9b 11 | * #ffa 12 | * #fff 13 | * #333 14 | * #62c8f3 15 | * #888 16 | * 17 | */ 18 | 19 | .hljs { 20 | display: block; 21 | overflow-x: auto; 22 | padding: .5em; 23 | background: #333; 24 | color: white; 25 | -webkit-text-size-adjust: none; 26 | } 27 | 28 | .asciidoc .hljs-title, 29 | .hljs-label, 30 | .hljs-tag .hljs-title, 31 | .hljs-prompt, 32 | .http .hljs-request { 33 | font-weight: bold; 34 | } 35 | 36 | .hljs-change, 37 | .hljs-code { 38 | font-style: italic; 39 | } 40 | 41 | .hljs-tag, 42 | .ini .hljs-title { 43 | color: #62c8f3; 44 | } 45 | 46 | .hljs-id, 47 | .hljs-cbracket, 48 | .hljs-tag .hljs-value { 49 | color: #ade5fc; 50 | } 51 | 52 | .hljs-string, 53 | .hljs-bullet { 54 | color: #a2fca2; 55 | } 56 | 57 | .hljs-type, 58 | .hljs-variable, 59 | .hljs-name, 60 | .actionscript .hljs-title, 61 | .aspectj .hljs-annotation, 62 | .aspectj .hljs-title, 63 | .hljs-attribute, 64 | .hljs-change, 65 | .hljs-blockquote, 66 | .hljs-built_in { 67 | color: #ffa; 68 | } 69 | 70 | .hljs-number, 71 | .hljs-hexcolor, 72 | .hljs-link_label, 73 | .hljs-link_reference { 74 | color: #d36363; 75 | } 76 | 77 | .hljs-keyword, 78 | .hljs-literal, 79 | .hljs-constant, 80 | .css .hljs-tag, 81 | .hljs-typename, 82 | .hljs-winutils { 83 | color: #fcc28c; 84 | } 85 | 86 | .hljs-comment, 87 | .hljs-cdata, 88 | .hljs-preprocessor, 89 | .hljs-annotation, 90 | .hljs-decorator, 91 | .hljs-doctype, 92 | .hljs-deletion, 93 | .hljs-shebang, 94 | .apache .hljs-sqbracket, 95 | .tex .hljs-formula, 96 | .hljs-header, 97 | .hljs-horizontal_rule, 98 | .hljs-code { 99 | color: #888; 100 | } 101 | 102 | .hljs-regexp, 103 | .hljs-attr_selector { 104 | color: #c6b4f0; 105 | } 106 | 107 | .hljs-important, 108 | .hljs-doctype, 109 | .hljs-pi, 110 | .hljs-chunk, 111 | .actionscript .hljs-type, 112 | .hljs-shebang, 113 | .hljs-pragma, 114 | .http .hljs-attribute { 115 | color: #fc9b9b; 116 | } 117 | 118 | .hljs-deletion { 119 | background-color: #fc9b9b; 120 | color: #333; 121 | } 122 | 123 | .hljs-addition { 124 | background-color: #a2fca2; 125 | color: #333; 126 | } 127 | 128 | .hljs a, 129 | .hljs-tag .hljs-attribute { 130 | color: inherit; 131 | } 132 | 133 | .hljs a:focus, 134 | .hljs a:hover { 135 | color: inherit; 136 | text-decoration: underline; 137 | } 138 | -------------------------------------------------------------------------------- /src/template: -------------------------------------------------------------------------------- 1 | %% -*- tab-width: 4;erlang-indent-level: 4;indent-tabs-mode: nil -*- 2 | %% ex: ft=erlang ts=4 sw=4 et 3 | %% Licensed under the Apache License, Version 2.0 (the "License"); you may not 4 | %% use this file except in compliance with the License. You may obtain a copy of 5 | %% the License at 6 | %% 7 | %% http://www.apache.org/licenses/LICENSE-2.0 8 | %% 9 | %% Unless required by applicable law or agreed to in writing, software 10 | %% distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | %% WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | %% License for the specific language governing permissions and limitations under 13 | %% the License. 14 | 15 | %% @author Dave Cottlehuber 16 | %% @copyright 2014-2038 Dave Cottlehuber 17 | %% @end 18 | 19 | %% @doc A wonderful Template Title 20 | %% 21 | %% This description line behaves nicely when used with EDoc/EDown and Hugo. 22 | %%
23 | %% ## Nota Bene 24 | %% You can of course embed [markdown] for hugo to deal with, via divs. 25 | %% [markdown]: http://daringfireball.net/projects/markdown/syntax 26 | %%
27 | %% And code samples just as easily: 28 | %%
29 | %% incr(X) ->
30 | %%   %% This should be formatted with Erlang syntax highlighting
31 | %%   X + 1.
32 | %% 
33 | %% @end 34 | 35 | -module(template). 36 | -include("swirl.hrl"). 37 | 38 | -ifdef(TEST). 39 | -include_lib("eunit/include/eunit.hrl"). 40 | -endif. 41 | 42 | %% api 43 | -export([beautiful/1]). 44 | 45 | -opaque mytype() :: {ok, binary()}. 46 | -export_type([lovely/0]). 47 | 48 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 49 | %% @doc 50 | %% A Beautiful Function. 51 | %% 52 | %% The same elements can be used for functions, too. So let's 53 | %% document a beautiful function, including: 54 | %%
    55 | %%
  • Purpose
  • 56 | %%
  • Data Structures
  • 57 | %%
  • Parameters
  • 58 | %%
  • Return Codes
  • 59 | %%
60 | %% Here is a long-form comment about our beautiful function, with JSON. 61 | %%
62 | %% {
63 | %%     "couchdb": "Welcome",
64 | %%     "uuid": "43cc0662c3dd3dbf1b7262ccc4f60af3",
65 | %%     "version": "1.6.1"
66 | %% }
67 | %% 
68 | %% @end 69 | 70 | -spec beautiful(binary()) -> term(). 71 | beautiful(Binary) when is_binary(Binary) -> 72 | %% @TODO better do this 73 | {ok, Binary}. 74 | 75 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 76 | %% test 77 | 78 | % -ifdef(TEST). 79 | % -spec _test() -> {ok, pid()}. 80 | % _test() -> 81 | % start(), 82 | % ?assertMatch({ok, _}, ). 83 | % -endif. 84 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/monokai.css: -------------------------------------------------------------------------------- 1 | /* 2 | Monokai style - ported by Luigi Maselli - http://grigio.org 3 | */ 4 | 5 | .hljs { 6 | display: block; 7 | overflow-x: auto; 8 | padding: 0.5em; 9 | background: #272822; 10 | -webkit-text-size-adjust: none; 11 | } 12 | 13 | .hljs-tag, 14 | .hljs-tag .hljs-title, 15 | .hljs-keyword, 16 | .hljs-literal, 17 | .hljs-strong, 18 | .hljs-change, 19 | .hljs-winutils, 20 | .hljs-flow, 21 | .nginx .hljs-title, 22 | .tex .hljs-special { 23 | color: #f92672; 24 | } 25 | 26 | .hljs { 27 | color: #ddd; 28 | } 29 | 30 | .hljs .hljs-constant, 31 | .asciidoc .hljs-code, 32 | .markdown .hljs-code { 33 | color: #66d9ef; 34 | } 35 | 36 | .hljs-code, 37 | .hljs-class .hljs-title, 38 | .hljs-header { 39 | color: white; 40 | } 41 | 42 | .hljs-link_label, 43 | .hljs-attribute, 44 | .hljs-symbol, 45 | .hljs-symbol .hljs-string, 46 | .hljs-value, 47 | .hljs-regexp { 48 | color: #bf79db; 49 | } 50 | 51 | .hljs-link_url, 52 | .hljs-tag .hljs-value, 53 | .hljs-string, 54 | .hljs-bullet, 55 | .hljs-subst, 56 | .hljs-title, 57 | .hljs-emphasis, 58 | .hljs-type, 59 | .hljs-preprocessor, 60 | .hljs-pragma, 61 | .ruby .hljs-class .hljs-parent, 62 | .hljs-built_in, 63 | .django .hljs-template_tag, 64 | .django .hljs-variable, 65 | .smalltalk .hljs-class, 66 | .django .hljs-filter .hljs-argument, 67 | .smalltalk .hljs-localvars, 68 | .smalltalk .hljs-array, 69 | .hljs-attr_selector, 70 | .hljs-pseudo, 71 | .hljs-addition, 72 | .hljs-stream, 73 | .hljs-envvar, 74 | .apache .hljs-tag, 75 | .apache .hljs-cbracket, 76 | .tex .hljs-command, 77 | .hljs-prompt, 78 | .hljs-name { 79 | color: #a6e22e; 80 | } 81 | 82 | .hljs-comment, 83 | .hljs-annotation, 84 | .smartquote, 85 | .hljs-blockquote, 86 | .hljs-horizontal_rule, 87 | .hljs-decorator, 88 | .hljs-pi, 89 | .hljs-doctype, 90 | .hljs-deletion, 91 | .hljs-shebang, 92 | .apache .hljs-sqbracket, 93 | .tex .hljs-formula { 94 | color: #75715e; 95 | } 96 | 97 | .hljs-keyword, 98 | .hljs-literal, 99 | .css .hljs-id, 100 | .hljs-doctag, 101 | .hljs-title, 102 | .hljs-header, 103 | .hljs-type, 104 | .vbscript .hljs-built_in, 105 | .rsl .hljs-built_in, 106 | .smalltalk .hljs-class, 107 | .diff .hljs-header, 108 | .hljs-chunk, 109 | .hljs-winutils, 110 | .bash .hljs-variable, 111 | .apache .hljs-tag, 112 | .tex .hljs-special, 113 | .hljs-request, 114 | .hljs-status { 115 | font-weight: bold; 116 | } 117 | 118 | .coffeescript .javascript, 119 | .javascript .xml, 120 | .tex .hljs-formula, 121 | .xml .javascript, 122 | .xml .vbscript, 123 | .xml .css, 124 | .xml .hljs-cdata { 125 | opacity: 0.5; 126 | } 127 | -------------------------------------------------------------------------------- /src/ppspp_have.erl: -------------------------------------------------------------------------------- 1 | %% -*- tab-width: 4;erlang-indent-level: 4;indent-tabs-mode: nil -*- 2 | %% ex: ft=erlang ts=4 sw=4 et 3 | %% Licensed under the Apache License, Version 2.0 (the "License"); you may not 4 | %% use this file except in compliance with the License. You may obtain a copy of 5 | %% the License at 6 | %% 7 | %% http://www.apache.org/licenses/LICENSE-2.0 8 | %% 9 | %% Unless required by applicable law or agreed to in writing, software 10 | %% distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | %% WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | %% License for the specific language governing permissions and limitations under 13 | %% the License. 14 | 15 | %% @doc Library for PPSPP over UDP, aka Swift protocol 16 | %% 17 | %% This module implements a library of functions necessary to 18 | %% handle the wire-protocol of PPSPP over UDP, including 19 | %% functions for encoding and decoding messages. 20 | %% @end 21 | 22 | -module(ppspp_have). 23 | -include("swirl.hrl"). 24 | 25 | %% api 26 | -export([unpack/2, 27 | pack/1, 28 | handle/1]). 29 | 30 | -opaque have() :: ppspp_chunk:spec(). 31 | -export_type([have/0]). 32 | 33 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 34 | %% api 35 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 36 | %% @doc unpack a have message 37 | %%

Deconstruct PPSPP UDP datagram into multiple erlang terms, including 38 | %% parsing any additional data within the same segment. Any parsing failure 39 | %% is fatal and will propagate back to the attempted datagram unpacking. 40 | %%

41 | %% @end 42 | 43 | -spec unpack(ppspp_chunk:addressing_method(), binary()) -> {have(), binary()}. 44 | 45 | unpack(Addressing_Method, Message) -> 46 | {Chunk_Spec, Maybe_Messages} = ppspp_chunk:unpack(Addressing_Method, Message), 47 | { Chunk_Spec, Maybe_Messages}. 48 | 49 | -spec pack(have()) -> binary(). 50 | pack(_Message) -> <<>>. 51 | 52 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 53 | %%-spec ... handle takes a tuple of {type, message_body} where body is TODO 54 | %% {error, something} or tagged tuple for the unpacked message 55 | %% {ok, reply} where reply is probably an orddict to be sent to the 56 | %% alternate peer. 57 | 58 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 59 | % The payload of the have message is a channel ID (see 60 | % Section 3.11) and a chunk specification. 61 | -spec handle(have()) -> any(). 62 | handle(Message) -> 63 | ?DEBUG("~p: handler not yet implemented ~p~n", [?MODULE, Message]), 64 | {ok, ppspp_have_handler_not_yet_implemented}. 65 | -------------------------------------------------------------------------------- /site/layouts/root/content.html: -------------------------------------------------------------------------------- 1 |
2 |
3 | 4 |
5 |
6 | 7 |
8 |
9 |

Broadcast Reliably.

10 |

Whether you're streaming a birthday or celebration from your 11 | phone, hosting the Olympics, or running a pay-per-view event, 12 | swirl has you covered. Its new, non-proprietary live streaming 13 | server & clients provide world-class reliability, 14 | using the legendary availability and low latency performance 15 | built into the Erlang/OTP 16 | platform.

17 |
18 |
19 | 20 |
21 |
22 | 23 |
24 |
25 |

Start streaming now — or later.

26 |

Be first with the news. No need to wait for a broadcast or event 27 | to end, swirl lets you stream the moment you have the first frames 28 | on camera. But if you're late to the party, don't worry, you 29 | won't have missed a thing. Swirl is ready to kick off when you 30 | are — just pick up where you left off, on any device.

31 |
32 |
33 | 34 |
35 |
36 | 37 |
38 |
39 |

Open & standard.

40 |

Unlike all those other tools, Swirl is both 41 | open source and 42 | open development, 43 | built on an open standard, with peer-to-peer scalability and 44 | fault-tolerance baked in from the beginning.

45 |

The application is based on the 46 | 47 | IETF RFC7574 Peer-to-Peer Streaming Peer Protocol, known as 48 | PPSP normally. The protocol includes innovative 49 | features for fast streaming, security and performance, and is 50 | compatible with current network infrastructure without 51 | rearchitecting or forklift upgrades. 52 |

53 |
54 |
55 | 56 |
57 |
58 | 59 | 60 | 61 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/googlecode.css: -------------------------------------------------------------------------------- 1 | /* 2 | 3 | Google Code style (c) Aahan Krish 4 | 5 | */ 6 | 7 | .hljs { 8 | display: block; 9 | overflow-x: auto; 10 | padding: 0.5em; 11 | background: white; 12 | color: black; 13 | -webkit-text-size-adjust: none; 14 | } 15 | 16 | .hljs-comment { 17 | color: #800; 18 | } 19 | 20 | .hljs-keyword, 21 | .method, 22 | .hljs-list .hljs-keyword, 23 | .nginx .hljs-title, 24 | .hljs-tag .hljs-title, 25 | .setting .hljs-value, 26 | .hljs-winutils, 27 | .tex .hljs-command, 28 | .http .hljs-title, 29 | .hljs-request, 30 | .hljs-status { 31 | color: #008; 32 | } 33 | 34 | .hljs-envvar, 35 | .tex .hljs-special { 36 | color: #660; 37 | } 38 | 39 | .hljs-string, 40 | .hljs-tag .hljs-value, 41 | .hljs-cdata, 42 | .hljs-filter .hljs-argument, 43 | .hljs-attr_selector, 44 | .apache .hljs-cbracket, 45 | .hljs-date, 46 | .hljs-regexp, 47 | .coffeescript .hljs-attribute { 48 | color: #080; 49 | } 50 | 51 | .hljs-sub .hljs-identifier, 52 | .hljs-pi, 53 | .hljs-tag, 54 | .hljs-tag .hljs-keyword, 55 | .hljs-decorator, 56 | .ini .hljs-title, 57 | .hljs-shebang, 58 | .hljs-prompt, 59 | .hljs-hexcolor, 60 | .hljs-rule .hljs-value, 61 | .hljs-literal, 62 | .hljs-symbol, 63 | .ruby .hljs-symbol .hljs-string, 64 | .hljs-number, 65 | .css .hljs-function, 66 | .clojure .hljs-attribute { 67 | color: #066; 68 | } 69 | 70 | .hljs-class .hljs-title, 71 | .smalltalk .hljs-class, 72 | .hljs-doctag, 73 | .hljs-type, 74 | .hljs-typename, 75 | .hljs-tag .hljs-attribute, 76 | .hljs-doctype, 77 | .hljs-class .hljs-id, 78 | .hljs-built_in, 79 | .setting, 80 | .hljs-params, 81 | .hljs-variable, 82 | .hljs-name { 83 | color: #606; 84 | } 85 | 86 | .css .hljs-tag, 87 | .hljs-rule .hljs-property, 88 | .hljs-pseudo, 89 | .hljs-subst { 90 | color: #000; 91 | } 92 | 93 | .css .hljs-class, 94 | .css .hljs-id { 95 | color: #9b703f; 96 | } 97 | 98 | .hljs-value .hljs-important { 99 | color: #ff7700; 100 | font-weight: bold; 101 | } 102 | 103 | .hljs-rule .hljs-keyword { 104 | color: #c5af75; 105 | } 106 | 107 | .hljs-annotation, 108 | .apache .hljs-sqbracket, 109 | .nginx .hljs-built_in { 110 | color: #9b859d; 111 | } 112 | 113 | .hljs-preprocessor, 114 | .hljs-preprocessor *, 115 | .hljs-pragma { 116 | color: #444; 117 | } 118 | 119 | .tex .hljs-formula { 120 | background-color: #eee; 121 | font-style: italic; 122 | } 123 | 124 | .diff .hljs-header, 125 | .hljs-chunk { 126 | color: #808080; 127 | font-weight: bold; 128 | } 129 | 130 | .diff .hljs-change { 131 | background-color: #bccff9; 132 | } 133 | 134 | .hljs-addition { 135 | background-color: #baeeba; 136 | } 137 | 138 | .hljs-deletion { 139 | background-color: #ffc8bd; 140 | } 141 | 142 | .hljs-comment .hljs-doctag { 143 | font-weight: bold; 144 | } 145 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/arta.css: -------------------------------------------------------------------------------- 1 | /* 2 | Date: 17.V.2011 3 | Author: pumbur 4 | */ 5 | 6 | .hljs { 7 | display: block; 8 | overflow-x: auto; 9 | padding: 0.5em; 10 | background: #222; 11 | -webkit-text-size-adjust: none; 12 | } 13 | 14 | .profile .hljs-header *, 15 | .ini .hljs-title, 16 | .nginx .hljs-title { 17 | color: #fff; 18 | } 19 | 20 | .hljs-comment, 21 | .hljs-preprocessor, 22 | .hljs-preprocessor .hljs-title, 23 | .hljs-pragma, 24 | .hljs-shebang, 25 | .profile .hljs-summary, 26 | .diff, 27 | .hljs-pi, 28 | .hljs-doctype, 29 | .hljs-tag, 30 | .css .hljs-rule, 31 | .tex .hljs-special { 32 | color: #444; 33 | } 34 | 35 | .hljs-string, 36 | .hljs-symbol, 37 | .diff .hljs-change, 38 | .hljs-regexp, 39 | .xml .hljs-attribute, 40 | .smalltalk .hljs-char, 41 | .xml .hljs-value, 42 | .ini .hljs-value, 43 | .clojure .hljs-attribute, 44 | .coffeescript .hljs-attribute { 45 | color: #ffcc33; 46 | } 47 | 48 | .hljs-number, 49 | .hljs-addition { 50 | color: #00cc66; 51 | } 52 | 53 | .hljs-built_in, 54 | .hljs-literal, 55 | .hljs-type, 56 | .hljs-typename, 57 | .go .hljs-constant, 58 | .ini .hljs-keyword, 59 | .lua .hljs-title, 60 | .perl .hljs-variable, 61 | .php .hljs-variable, 62 | .mel .hljs-variable, 63 | .django .hljs-variable, 64 | .css .funtion, 65 | .smalltalk .method, 66 | .hljs-hexcolor, 67 | .hljs-important, 68 | .hljs-flow, 69 | .hljs-inheritance, 70 | .hljs-name, 71 | .parser3 .hljs-variable { 72 | color: #32aaee; 73 | } 74 | 75 | .hljs-keyword, 76 | .hljs-tag .hljs-title, 77 | .css .hljs-tag, 78 | .css .hljs-class, 79 | .css .hljs-id, 80 | .css .hljs-pseudo, 81 | .css .hljs-attr_selector, 82 | .hljs-winutils, 83 | .tex .hljs-command, 84 | .hljs-request, 85 | .hljs-status { 86 | color: #6644aa; 87 | } 88 | 89 | .hljs-title, 90 | .ruby .hljs-constant, 91 | .vala .hljs-constant, 92 | .hljs-parent, 93 | .hljs-deletion, 94 | .hljs-template_tag, 95 | .css .hljs-keyword, 96 | .objectivec .hljs-class .hljs-id, 97 | .smalltalk .hljs-class, 98 | .lisp .hljs-keyword, 99 | .apache .hljs-tag, 100 | .nginx .hljs-variable, 101 | .hljs-envvar, 102 | .bash .hljs-variable, 103 | .go .hljs-built_in, 104 | .vbscript .hljs-built_in, 105 | .lua .hljs-built_in, 106 | .rsl .hljs-built_in, 107 | .tail, 108 | .avrasm .hljs-label, 109 | .tex .hljs-formula, 110 | .tex .hljs-formula * { 111 | color: #bb1166; 112 | } 113 | 114 | .hljs-doctag, 115 | .profile .hljs-header, 116 | .ini .hljs-title, 117 | .apache .hljs-tag, 118 | .parser3 .hljs-title { 119 | font-weight: bold; 120 | } 121 | 122 | .coffeescript .javascript, 123 | .javascript .xml, 124 | .tex .hljs-formula, 125 | .xml .javascript, 126 | .xml .vbscript, 127 | .xml .css, 128 | .xml .hljs-cdata { 129 | opacity: 0.6; 130 | } 131 | 132 | .hljs, 133 | .hljs-subst, 134 | .diff .hljs-chunk, 135 | .css .hljs-value, 136 | .css .hljs-attribute { 137 | color: #aaa; 138 | } 139 | -------------------------------------------------------------------------------- /test/ppspp_options_SUITE.erl: -------------------------------------------------------------------------------- 1 | %% -*- tab-width: 4;erlang-indent-level: 4;indent-tabs-mode: nil -*- 2 | %% ex: ft=erlang ts=4 sw=4 et 3 | %% Licensed under the Apache License, Version 2.0 (the "License"); you may not 4 | %% use this file except in compliance with the License. You may obtain a copy of 5 | %% the License at 6 | %% 7 | %% http://www.apache.org/licenses/LICENSE-2.0 8 | %% 9 | %% Unless required by applicable law or agreed to in writing, software 10 | %% distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 11 | %% WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 12 | %% License for the specific language governing permissions and limitations under 13 | %% the License. 14 | 15 | %% @doc Swirl Tests. 16 | %% @end 17 | 18 | -module(ppspp_options_SUITE). 19 | -include("swirl.hrl"). 20 | -include_lib("common_test/include/ct.hrl"). 21 | 22 | -export([all/0]). 23 | -export([defaults/1, 24 | getters/1 25 | ]). 26 | 27 | -spec all() -> [atom()]. 28 | all() -> [defaults, 29 | getters 30 | ]. 31 | 32 | -spec defaults(any()) -> true. 33 | defaults(_Config) -> 34 | % minimal options should only include the RFC7574 version 35 | Map = #{minimum_version => ?PPSPP_LOWEST_VERSION}, 36 | Map = ppspp_options:use_minimum_options(), 37 | % options must be a simple map using defaults from RFC7574 38 | Root_Hash ="c39e", 39 | Swarm_id = convert:hex_string_to_padded_binary(Root_Hash), 40 | Res = #{ 41 | chunk_addressing_method => ?PPSPP_DEFAULT_CHUNK_METHOD, 42 | chunk_size => ?PPSPP_DEFAULT_CHUNK_SIZE, 43 | content_integrity_check_method => ?PPSPP_DEFAULT_INTEGRITY_METHOD, 44 | merkle_hash_tree_function => ?PPSPP_DEFAULT_MERKLE_HASH_FUN, 45 | minimum_version => ?PPSPP_LOWEST_VERSION, 46 | supported_version => ?SWIRL_MAX_PPSPP_VERSION, 47 | swarm_id => Swarm_id}, 48 | Res = ppspp_options:use_default_options(Swarm_id). 49 | 50 | -spec getters(any()) -> true. 51 | %% @doc ensure that accessor functions return the RFC7574 defaults. 52 | %% @end 53 | getters(_Config) -> 54 | Root_Hash ="c39e", 55 | Swarm_id = convert:hex_string_to_padded_binary(Root_Hash), 56 | Options = ppspp_options:use_default_options(Swarm_id), 57 | % check returned values against header file defaults 58 | ?PPSPP_DEFAULT_CHUNK_METHOD = ppspp_options:get_chunk_addressing_method(Options), 59 | ?PPSPP_DEFAULT_INTEGRITY_METHOD = ppspp_options:get_content_integrity_check_method(Options), 60 | ?PPSPP_DEFAULT_MERKLE_HASH_FUN = ppspp_options:get_merkle_hash_tree_function(Options), 61 | % NB as above, when v2 of the PPSPP RFC is released this macro must change 62 | ?PPSPP_LOWEST_VERSION = ppspp_options:get_minimum_version(Options), 63 | ?PPSPP_DEFAULT_CHUNK_SIZE = ppspp_options:get_chunk_size(Options), 64 | Swarm_id = ppspp_options:get_swarm_id(Options), 65 | ?SWIRL_MAX_PPSPP_VERSION = ppspp_options:get_maximum_supported_version(Options), 66 | true. 67 | -------------------------------------------------------------------------------- /site/themes/hyde-x/static/css/highlight/xcode.css: -------------------------------------------------------------------------------- 1 | /* 2 | 3 | XCode style (c) Angel Garcia 4 | 5 | */ 6 | 7 | .hljs { 8 | display: block; 9 | overflow-x: auto; 10 | padding: 0.5em; 11 | background: #fff; 12 | color: black; 13 | -webkit-text-size-adjust: none; 14 | } 15 | 16 | .hljs-comment { 17 | color: #006a00; 18 | } 19 | 20 | .hljs-keyword, 21 | .hljs-literal, 22 | .nginx .hljs-title { 23 | color: #aa0d91; 24 | } 25 | .method, 26 | .hljs-list .hljs-title, 27 | .hljs-tag .hljs-title, 28 | .setting .hljs-value, 29 | .hljs-winutils, 30 | .tex .hljs-command, 31 | .http .hljs-title, 32 | .hljs-request, 33 | .hljs-status, 34 | .hljs-name { 35 | color: #008; 36 | } 37 | 38 | .hljs-envvar, 39 | .tex .hljs-special { 40 | color: #660; 41 | } 42 | 43 | .hljs-string { 44 | color: #c41a16; 45 | } 46 | .hljs-tag .hljs-value, 47 | .hljs-cdata, 48 | .hljs-filter .hljs-argument, 49 | .hljs-attr_selector, 50 | .apache .hljs-cbracket, 51 | .hljs-date, 52 | .hljs-regexp { 53 | color: #080; 54 | } 55 | 56 | .hljs-sub .hljs-identifier, 57 | .hljs-pi, 58 | .hljs-tag, 59 | .hljs-tag .hljs-keyword, 60 | .hljs-decorator, 61 | .ini .hljs-title, 62 | .hljs-shebang, 63 | .hljs-prompt, 64 | .hljs-hexcolor, 65 | .hljs-rule .hljs-value, 66 | .hljs-symbol, 67 | .hljs-symbol .hljs-string, 68 | .hljs-number, 69 | .css .hljs-function, 70 | .hljs-function .hljs-title, 71 | .coffeescript .hljs-attribute { 72 | color: #1c00cf; 73 | } 74 | 75 | .hljs-class .hljs-title, 76 | .smalltalk .hljs-class, 77 | .hljs-type, 78 | .hljs-typename, 79 | .hljs-tag .hljs-attribute, 80 | .hljs-doctype, 81 | .hljs-class .hljs-id, 82 | .hljs-built_in, 83 | .setting, 84 | .hljs-params, 85 | .clojure .hljs-attribute { 86 | color: #5c2699; 87 | } 88 | 89 | .hljs-variable { 90 | color: #3f6e74; 91 | } 92 | .css .hljs-tag, 93 | .hljs-rule .hljs-property, 94 | .hljs-pseudo, 95 | .hljs-subst { 96 | color: #000; 97 | } 98 | 99 | .css .hljs-class, 100 | .css .hljs-id { 101 | color: #9b703f; 102 | } 103 | 104 | .hljs-value .hljs-important { 105 | color: #ff7700; 106 | font-weight: bold; 107 | } 108 | 109 | .hljs-rule .hljs-keyword { 110 | color: #c5af75; 111 | } 112 | 113 | .hljs-annotation, 114 | .apache .hljs-sqbracket, 115 | .nginx .hljs-built_in { 116 | color: #9b859d; 117 | } 118 | 119 | .hljs-preprocessor, 120 | .hljs-preprocessor *, 121 | .hljs-pragma { 122 | color: #643820; 123 | } 124 | 125 | .tex .hljs-formula { 126 | background-color: #eee; 127 | font-style: italic; 128 | } 129 | 130 | .diff .hljs-header, 131 | .hljs-chunk { 132 | color: #808080; 133 | font-weight: bold; 134 | } 135 | 136 | .diff .hljs-change { 137 | background-color: #bccff9; 138 | } 139 | 140 | .hljs-addition { 141 | background-color: #baeeba; 142 | } 143 | 144 | .hljs-deletion { 145 | background-color: #ffc8bd; 146 | } 147 | 148 | .hljs-comment .hljs-doctag { 149 | font-weight: bold; 150 | } 151 | 152 | .method .hljs-id { 153 | color: #000; 154 | } 155 | --------------------------------------------------------------------------------