Skip to content

Instantly share code, notes, and snippets.

#! /bin/bash
### BEGIN INIT INFO
# Provides: riak
# Required-Start: $remote_fs $syslog
# Required-Stop: $remote_fs $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Example initscript
# Description: This file should be used to construct scripts to be
# placed in /etc/init.d.
#!/usr/bin/env python
import os
import feedparser
import pprint
import subprocess
TED_FEED = "http://feeds.feedburner.com/tedtalks_video"
def need_to_download(entries):
for entry in entries:
# copy this to ~/.bashrc
_complete_ssh_hosts () {
COMPREPLY=()
cur="${COMP_WORDS[COMP_CWORD]}"
comp_ssh_hosts=`
grep "^host " ~/.ssh/config | \
awk '{print $2}'
`
COMPREPLY=( $(compgen -W "${comp_ssh_hosts}" -- $cur))