Skip to content

Instantly share code, notes, and snippets.

@enovav
enovav / denyhosts.cfg
Created September 18, 2011 13:41
Blog DenyHosts configuration
############ THESE SETTINGS ARE REQUIRED ############
########################################################################
#
# SECURE_LOG: the log file that contains sshd logging info
# if you are not sure, grep "sshd:" /var/log/*
#
# The file to process can be overridden with the --file command line
# argument
#
@enovav
enovav / httpd.conf.default
Created August 7, 2011 16:53
Default Apache conf
#
# Mac OS X / Mac OS X Server
# The <IfDefine> blocks segregate server-specific directives
# and also directives that only apply when Web Sharing or
# server Web Service (as opposed to other services that need Apache) is on.
# The launchd plist sets appropriate Define parameters.
# Generally, desktop has no vhosts and server does; server has added modules,
# custom virtual hosts are only activated when Web Service is on, and
# default document root and personal web sites at ~username are only
# activated when Web Sharing is on.
@enovav
enovav / httpd.conf
Created August 7, 2011 16:52
Blog Apache conf
#
# Mac OS X / Mac OS X Server
# The <IfDefine> blocks segregate server-specific directives
# and also directives that only apply when Web Sharing or
# server Web Service (as opposed to other services that need Apache) is on.
# The launchd plist sets appropriate Define parameters.
# Generally, desktop has no vhosts and server does; server has added modules,
# custom virtual hosts are only activated when Web Service is on, and
# default document root and personal web sites at ~username are only
# activated when Web Sharing is on.
@enovav
enovav / archive.html
Created July 19, 2011 20:16
Blog Template Selection for "Why I Switched To Jekyll"
---
layout: default
title: Henry Mercer
---
{% for post in site.posts %}
{% capture cmonth %}{{ post.date | date: "%B" }}{% endcapture %}
{% unless lmonth == cmonth %}
{% unless forloop.first %}</ul>{% endunless %}
<h3>{{ cmonth }} {{ post.date | date: "%Y" }}</h3>
<ul class="archive">
@enovav
enovav / mobile_imgs.js
Created July 9, 2011 11:49
Mobile Images
if (screen.width < 480) {
var imgs = document.getElementsByTagName("img");
for (var i = 0; i < imgs.length; i++) {
var elm = imgs[i];
if (elm.getAttribute("data-src-mobile")) {
elm.setAttribute("src", elm.getAttribute("data-src-mobile"));
}
}
}
@enovav
enovav / style.css
Created March 2, 2011 20:33
"Lengthens" footer on a short page
html, #footer { background-color: #fafafa; }