This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
""" | |
Last.fm scrobbling for Pianobar, the command-line Pandora client. Requires Pianobar, Python, pyLast and Last.fm API credentials. | |
https://github.com/PromyLOPh/pianobar/ | |
http://code.google.com/p/pylast/ | |
http://www.last.fm/api/account | |
Installation: | |
1) Copy this script and pylast.py to the Pianobar config directory, ~/.config/pianobar/, and make sure this script is executable |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <stdlib.h> | |
#include <string.h> | |
#include <ctype.h> | |
#include <memory.h> | |
#include <errno.h> | |
#include <assert.h> | |
#include <sys/types.h> | |
#include <stdarg.h> | |
#include <fcntl.h> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Facter.add("dbservers") do | |
setcode do | |
hosts = nil | |
if File.exists?('/etc/bookings/db.conf') | |
hosts = File.readlines('/etc/bookings/db.conf').collect do |line| | |
next if ! line.match(/dbi:mysql:/) | |
match = line.match(/host=([^;]+);/) | |
match[1] if match | |
end.compact.join(',') | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
applications: | |
app::core::instance: | |
'01': | |
index: '01' | |
'02': | |
index: '02' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
set -e | |
git-update-server-info | |
# | |
# Hook to update the /etc/puppetlabs/puppet with the lastest git changes | |
# | |
# To enable this hook, rename this file to "post-receive". | |
syncuser="puppetsync" |