Skip to content

Instantly share code, notes, and snippets.

View stefanschmidt's full-sized avatar

Stefan stefanschmidt

  • Hamburg, Germany
View GitHub Profile
@stefanschmidt
stefanschmidt / daily-show-downloader.sh
Last active February 21, 2017 19:46 — forked from anonymous/gist:276271
The Daily Show Downloader
#!/bin/bash
#
# This script depends on curl and rtmpdump.
# For playback I recommend mplayer.
# Suggestions are welcome.
#
RTMPDUMP="rtmpdump" # the name of the binary
set -eu
@stefanschmidt
stefanschmidt / vimeo-downlaoder.sh
Last active September 25, 2015 12:38
Vimeo Downloader
#!/bin/sh
#
# Vimeo Downloader
#
# Copyright (C) 2008, 2010 Denver Gingerich
# Copyright (C) 2009 Jori Hamalainen
#
# Permission to use, copy, modify, and/or distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# copyright notice and this permission notice appear in all copies.
@stefanschmidt
stefanschmidt / remote-management.sh
Last active October 3, 2015 08:58
Enable Remote Management on OS X
# Configure Remote Management
kickstart -configure -allowAccessFor -allUsers -privs -all
# Enable Remote Management
kickstart -activate -restart -agent
# Disable Remote Management
kickstart -deactivate -stop
@stefanschmidt
stefanschmidt / toggle-screen-sharing
Last active August 21, 2024 19:16
Enable/Disable Screen Sharing on OSX
# Enable Screen Sharing
sudo launchctl load -w /System/Library/LaunchDaemons/com.apple.screensharing.plist
# Disable Screen Sharing
sudo launchctl unload -w /System/Library/LaunchDaemons/com.apple.screensharing.plist
@stefanschmidt
stefanschmidt / mountain-lion.sh
Last active October 7, 2015 13:58 — forked from AriX/mountainlion.sh
Script to check for Mac OS X 10.8 Mountain Lion
#!/bin/bash
USER_AGENT="iMacAppStore/1.0.1 (Macintosh; U; Intel Mac OS X 10.6.7; en) AppleWebKit/533.20.25"
STORE_URL="http://itunes.apple.com/WebObjects/MZStore.woa/wa/viewMultiRoom?fcId=489264329&mt=12&s=143461"
SEARCH_STRING="mountain lion"
clear; echo -n "Waiting for Mountain Lion"
while true; do
if curl -sA "$USER_AGENT" "$STORE_URL" | grep -i "$SEARCH_STRING" > /dev/null; then
@stefanschmidt
stefanschmidt / enable_chrome_third_party
Last active December 11, 2015 00:48
Permanently enable installation of Chrome extensions from arbitrary third-party sources
defaults write com.google.Chrome ExtensionInstallSources -array '"<all_urls>"'
@stefanschmidt
stefanschmidt / osx-safari-flash-update-v1.sh
Last active September 8, 2017 13:38
Update the Flash Player on OS X via CLI
# Check here for the URL of the current release: http://get.adobe.com/de/flashplayer/
curl -O http://fpdownload.macromedia.com/get/flashplayer/current/licensing/mac/install_flash_player_12_osx.dmg
# The -nobrowse prevents the mounted image from showing up in the OS X Finder
hdiutil attach -nobrowse install_flash_player_osx.dmg
# Non-interactive installation
cd /Volumes/Flash\ Player/Install\ Adobe\ Flash\ Player.app/Contents/Resources
sudo installer -verbose -pkg Adobe\ Flash\ Player.pkg -target /
@stefanschmidt
stefanschmidt / Solarized.terminal
Last active December 14, 2015 10:39
Solarized Colors for Mountain Lion's Terminal.app
<!-- -->
<!-- See http://ethanschoonover.com/solarized -->
<!-- -->
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>ANSIBlackColor</key>
<data>
@stefanschmidt
stefanschmidt / dircolors-solarized
Created March 3, 2013 00:29
Solarized Colors for GNU dircolors
#
# Heavily customized version of Sebastian Tramp's dircolors-solarized
# https://github.com/seebi/dircolors-solarized
#
# Below, there should be one TERM entry for each termtype that is colorizable
TERM ansi
TERM color_xterm
TERM color-xterm
TERM con132x25
@stefanschmidt
stefanschmidt / reset-lsdb
Last active December 14, 2015 14:48
Reset the OS X Launch Service database to remove duplicate menu entries
lsregister -kill -r -v -all local,system,user