Skip to content

Instantly share code, notes, and snippets.

View mythmon's full-sized avatar

Michael Cooper mythmon

View GitHub Profile
Puppet mail getting sent to spam, per relay
spam | not | total
hemlock 0 | 900 | 900
0% | 100%|
whitealder 140 | 785 | 925
15% | 85% |
fraxinus 775 | 395 | 1170
Puppet mail getting sent to spam, per relay
spam | not | total
hemlock 0 | 180 | 180
0% | 100%|
whitealder 28 | 157 | 185
15% | 85% |
fraxinus 155 | 79 | 234
" puppet syntax file
" Filename: puppet.vim
" Language: puppet configuration file
" Maintainer: Luke Kanies <luke@madstop.com>
" URL:
" Last Change:
" Version:
"
" Copied from the cfengine, ruby, and perl syntax files
define vim::config ($home) {
file { "$name-vimrc":
path => "${home}/.vimrc",
ensure => present,
content => template("vim/vimrc.erb"),
}
}
@mythmon
mythmon / config.pp
Created January 27, 2012 05:03
vim::config - Why doesn't it work?
# $name is the name of the user this config should exist for
define vim::config ($home) {
file { "$name-vimrc":
path => "${home}/.vimrc",
ensure => present,
content => template("vim/vimrc.erb"),
}
}
# Maintainer: Mike Cooper <mythmon[at]gmail.com>
# Contributor: Danny Tatom <dannytatom[at]gmail.com>
# Contributor: Chris Wanstrath <chris[at]ozmm.org>
# Contributor: Felix Rohrbach <fxrh@gmx.de>
pkgname=hub
pkgver=1.8.1
pkgrel=1
pkgdesc="Introduces git to GitHub"
arch=('any')
@mythmon
mythmon / gist:2027641
Created March 13, 2012 08:46
Kevin's hooks are weird
Traceback (most recent call last):
File "/home/mythmon/src/wok/scripts/wok", line 4, in <module>
Engine()
File "/home/mythmon/src/wok/wok/engine.py", line 96, in __init__
self.generate_site()
File "/home/mythmon/src/wok/wok/engine.py", line 134, in generate_site
self.render_site()
File "/home/mythmon/src/wok/wok/engine.py", line 348, in render_site
new_pages = p.render(templ_vars)
File "/home/mythmon/src/wok/wok/page.py", line 352, in render
@mythmon
mythmon / post-receive
Created March 27, 2012 06:07
The post-receive hook that allows to selectively run git hooks.
#!/bin/bash
# wrapper script for post-recieve
enabled_hooks="$(git config hooks.enabled)"
hooks_path="/usr/local/share/git/hooks/"
if [ -n "${enabled_hooks}" ] ; then
# change separate to comma
OLDIFS="$IFS"
IFS=","
##### modules/foo/manifests/init.pp
class foo {
if $operatingsystem == "Fedora" {
include repos::rpmfusion
} else {
include repos::foo
}
package { "foo":
#!/bin/bash
# wrapper script for post-recieve
enabled_hooks="$(git config hooks.enabled)"
hooks_path="/usr/local/share/git/hooks/"
if [ -n "${enabled_hooks}" ] ; then
read input
# change separate to comma
OLDIFS="$IFS"