Skip to content

Instantly share code, notes, and snippets.

View Roforum's full-sized avatar

Roforum

  • Roforum.net
  • https://www.roforum.net/
View GitHub Profile
@Roforum
Roforum / detect-private-browsing.js
Created November 28, 2018 01:27 — forked from dgp/detect-private-browsing.js
Detect private browsing mode (InPrivate Browsing or Incognito).
function retry(isDone, next) {
var current_trial = 0, max_retry = 50, interval = 10, is_timeout = false;
var id = window.setInterval(
function() {
if (isDone()) {
window.clearInterval(id);
next(is_timeout);
}
if (current_trial++ > max_retry) {
window.clearInterval(id);
@Roforum
Roforum / broadcast.sh
Created January 17, 2018 14:09 — forked from BusterNeece/broadcast.sh
FunkyWayFM: The shell script used to merge the video feed and AzuraCast-powered radio feed into a single YouTube stream.
#! /bin/bash
VBR="1500k"
FPS="30"
QUAL="veryfast"
YOUTUBE_URL="rtmp://a.rtmp.youtube.com/live2"
KEY=""
VIDEO_SOURCE="/home/ubuntu/video3.mp4"