Skip to content

Instantly share code, notes, and snippets.

Avatar

Basti Becker bastibeckr

  • studio2010 GmbH
  • Munich, Germany
View GitHub Profile
@bastibeckr
bastibeckr / index.js
Created Feb 10, 2014
HTTP Proxy for Web Development
View index.js
var http = require('http'),
httpProxy = require('http-proxy');
var options = {
target: 'http://domain.dev/',
headers: {
host: 'domain.dev'
}
}
@bastibeckr
bastibeckr / opengeodb orte in bayern
Created Mar 23, 2014
OpenGeoDB to list towns, districts, municipalities (in a state) with hierarchy (adm. region, rural district), zipcode and population count .
View opengeodb orte in bayern
SELECT
/** Ort / Ortsteil */
ort_name.loc_id 'loc_id',
ort_name.text_val 'loc_name',
ort_level.text_val 'level',
ort_type.text_val 'typ',
/* ort_parent.text_val 'parent_id', */
ort_plz.text_val 'postleitzahl',
/* LEVEL6 */
hier.id_lvl6 'gemeinde_id',
View gist:230dc012ff0e4507d308
g++ -o bmdplay bmdplay.cpp ../../include/DeckLinkAPIDispatch.cpp `pkg-config --cflags libavcodec libavformat libswscale libavutil` -D__STDC_CONSTANT_MACROS -Wno-multichar -I ../../include -fno-rtti -g -framework CoreFoundation -DHAVE_CFSTRING `pkg-config --libs libavcodec libavformat libswscale libavutil` -lm -ldl -lpthread -framework CoreFoundation
View bmdstreamer.rb
# based on https://github.com/amiaopensource/homebrew-amiaos
require 'formula'
class Bmdtools < Formula
env :std
depends_on 'ffmpeg' => 'with-tools'
depends_on 'amiaopensource/amiaos/bmdtools' => :build
@bastibeckr
bastibeckr / stream.sh
Last active Sep 5, 2016
Capture on Mac OSX from Blackmagic Ultrastudio to FFMPEG. Generate multiple HLS streams
View stream.sh
bmdcapture -m 8 -C 0 -A 2 -V 4 -F nut -f pipe:1 | \
ffmpeg -y -i - \
-c:a libfaac -ac 2 -b:a 96k -ar 44100 -c:v libx264 -pix_fmt yuv420p -profile:v main -level 32 -b:v 1000K -f hls -hls_time 10 -hls_list_size 999 -vf "scale=1280:-1" -segment_list_flags +live 1280x720.m3u8 \
-c:a libfaac -ac 2 -b:a 96k -ar 44100 -c:v libx264 -pix_fmt yuv420p -profile:v main -level 32 -b:v 600K -f hls -hls_time 10 -hls_list_size 999 -vf "scale=720:-1" -segment_list_flags +live 720x405.m3u8
@bastibeckr
bastibeckr / check_chronosync_scheduler
Last active Mar 14, 2017
Basic nagios-check for ChronoSync Scheduler (Mac OSX)
View check_chronosync_scheduler
#!/usr/bin/env osascript -l JavaScript
ObjC.import('stdlib')
console.log = function() {
ObjC.import('Foundation');
for (argument of arguments) {
$.NSFileHandle.fileHandleWithStandardOutput.writeData($.NSString.alloc.initWithString(String(argument) + "\n").dataUsingEncoding($.NSNEXTSTEPStringEncoding));
}
}
View gist:6ceb19423b422786139de7042b7c3baf
### Keybase proof
I hereby claim:
* I am bastibeckr on github.
* I am bastibeckr (https://keybase.io/bastibeckr) on keybase.
* I have a public key ASB9dQmh0GnqfPjKvbky_FnBjwQXGaqD14XDaEPpmBXCHwo
To claim this, I am signing this object:
View gifsicle.sh
#! /bin/zsh
sizes=( "100x56" "1024x576" "150x150" "150x80" "200x125" "250x140" "256x144" "300x169" "320x180" "400x225" "600x338" "768x432" "800x450" )
filename=${1}
echo "Filename: ${filename:r:t}"
# Dirname without trailing slash
@bastibeckr
bastibeckr / README.md
Last active Dec 22, 2017
Dashing-Widget that displays a list of tweets
View README.md

Twitter-List

Description

Shows a list of tweets, basically it can show any list of comments. We use it to display our Twitter account's latest "saved search" - results.

Dependencies

@bastibeckr
bastibeckr / bmdtools.rb
Last active Feb 17, 2018
bmdtools homebrew formula
View bmdtools.rb
# based on https://github.com/amiaopensource/homebrew-amiaos
require 'formula'
class Bmdtools < Formula
homepage 'http://github.com/lu-zero/bmdtools'
head 'https://github.com/lu-zero/bmdtools.git'
env :std