Skip to content

Instantly share code, notes, and snippets.

@prebrov
prebrov / LICENSE
Created March 1, 2021 02:26 — forked from brianbruggeman/LICENSE
Convert Viscosity to Open VPN
Public Domain
@prebrov
prebrov / env.py
Created July 27, 2018 21:33 — forked from lethee/env.py
Sublime Text 3: Apply NVM environment
# Save this file
# mac - "~/Library/Application Support/Sublime Text 3/Packages/"
# linux - "~/.config/sublime-text-3/Packages/"
# NOTE!
# ~/.nvm/alias/default must contain full version name.
# $ nvm alias default v4.3.5
import os
#!/bin/bash
# Get Homebrew in the new location
git clone git@github.com:Homebrew/homebrew.git ~/Homebrew
# Move all your installed packages to the new location
mv /usr/local/Cellar ~/Homebrew/Cellar
mv /usr/local/Library ~/Homebrew/Library
# Remove "root" directory files left behind
rm -rf /usr/local/.git /usr/local/{.gitignore,.yardopts,CODEOFCONDUCT.md,CONTRIBUTING.md,LICENSE.txt,README.md,SUPPORTERS.md}
@prebrov
prebrov / craft.conf
Created September 28, 2015 04:59 — forked from kenzie/craft.conf
Nginx virtual host configuration for Craft CMS, PHP5-FPM, NGINX 1.2.1 and craft/config/general.php for friendly URLs.
server {
listen 80;
root /var/www/craft.dev/public;
index index.php index.html index.htm;
server_name craft.dev;
location / {
try_files $uri $uri/ @rewrites;
@prebrov
prebrov / button.html
Last active August 28, 2015 00:47 — forked from dmlap/button.html
Custom button HTML
<div class="vjs-playback-rate-button vjs-menu-button vjs-control" role="button" aria-live="polite" tabindex="0" aria-haspopup="true" aria-label="Playback Rate Menu">
<div class="vjs-control-content">
<span class="vjs-control-text">1x</span>
<div class="vjs-menu">
<ul class="vjs-menu-content">
<li class="vjs-menu-item" role="button" aria-live="polite" tabindex="0" aria-selected="true">0.5x</li>
<li class="vjs-menu-item vjs-selected" role="button" aria-live="polite" tabindex="0" aria-selected="true">1x</li>
<li class="vjs-menu-item" role="button" aria-live="polite" tabindex="0" aria-selected="true">1.5x</li>
<li class="vjs-menu-item" role="button" aria-live="polite" tabindex="0" aria-selected="true">2.0x</li>
</ul>
@prebrov
prebrov / dynamic-ads.js
Last active August 28, 2015 00:47 — forked from dmlap/dynamic-ads.js
Dynamically configuring the ad server URL for the Brightcove Player.
/**
* PLUGIN CODE
*/
// create a simple javascript plugin that gets the current video ID and sets up ads:
videojs.plugin('setupAds', function() {
'use strict';
var player = this,
currentVideoId = player.el().getAttribute('data-video-id');
player.ima3({
@prebrov
prebrov / bitrate-switch.html
Last active August 28, 2015 00:47 — forked from dmlap/bitrate-switch.html
An example of manual bitrate selection with videojs-contrib-hls.
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>video.js HLS Plugin Example</title>
<link href="node_modules/video.js/dist/video-js/video-js.css" rel="stylesheet">
<!-- video.js -->
<script src="node_modules/video.js/dist/video-js/video.js"></script>