Skip to content

Instantly share code, notes, and snippets.

@munroebot
munroebot / email.txt
Created August 27, 2011 20:53
Dear Jimmy
So the problem isn't that I can't put a cache buster
on like the css and js files inside the *.html, but
rather how do I bust the cache on a bookmarked page?
I can't attach epoch time because I didn't think you
could attach a javascript object like that?
BTW, do you use a templating engine / framework or
something when building your pages? It also seems
rather clunky to do something like this:
@munroebot
munroebot / joke.txt
Created September 27, 2011 18:44
Dear Jimmy #002
"An old cowboy goes into a bar and orders a drink. As he sits there
sipping his whiskey, a young lady sits down next to him. ... She says,
'I'm a lesbian. I spend my whole day thinking about women. ...' A little
while later, a couple sits down next to the old cowboy and asks him, 'Are
you a real cowboy?' He replies, 'I always thought I was, but I just found
out I'm a lesbian.'"
@munroebot
munroebot / salt_mods.py
Created August 5, 2012 19:11
Salt Mods for Tomcat
def __catalina_home(path=None):
'''
Tomcat paths differ depending on packaging
'''
if (path == None):
locations = ['/usr/share/tomcat6', '/opt/tomcat']
else:
locations = [path,]
for location in locations:
@munroebot
munroebot / gist:3751809
Created September 19, 2012 19:47
Logo Droppers
#!/usr/bin/env python3
about_logo_droppers = """
So they have all the major t-shirt vendors
(Hanes, Gildan, etc) - since SYN Shop is a
non-profit, we might have gotten a slight
discount, but our t-shirt costs range from
$5 - $12 depending upon size and style.
@munroebot
munroebot / init.pp
Created December 4, 2012 23:02
Example Configuration
class tc-config-6036-log4j {
define new($env, $path) {
file { "/tmp/tomcat-6036-log4j.tar.gz":
ensure => present,
mode => 644,
owner => tomcat,
group => tomcat,
alias => "tomcat-6036-log4j.tgz",
pi@raspberrypi:~$ [ 4115.299888] Unable to handle kernel NULL pointer dereference at virtual address 00000000
[ 4115.314240] pgd = c0004000
[ 4115.322904] [00000000] *pgd=00000000
[ 4115.332334] Internal error: Oops: 17 [#1] PREEMPT ARM
Entering kdb (current=0xccca0320, pid 2197) Oops: (null)
due to oops @ 0xc0298260
Pid: 2197, comm: kworker/u:3
CPU: 0 Not tainted (3.6.11+ #371)
create table shopidentifyer.event_log (
event_id int NOT NULL PRIMARY KEY AUTO_INCREMENT,
badge_id int NOT NULL,
created_on TIMESTAMP DEFAULT CURRENT_TIMESTAMP,
event_type ENUM('BADGE_SWIPE','MANUAL_SWIPE','ACCESS_ATTEMPT','ACCESS_GRANT','ACCESS_DENY') DEFAULT 'BADGE_SWIPE',
event_message varchar(255)
);
@munroebot
munroebot / HelloWorld.md
Created February 24, 2015 05:18
Markdown Example

This is a markdown file

@munroebot
munroebot / gist:038cca8aca25db827109
Created April 26, 2015 14:52
File Test for assignment
#
# First make sure the datasets are available
#
if (!file.exists(file.path(getwd(),"UCI HAR Dataset/test/X2_test.txt")) |
!file.exists(file.path(getwd(),"UCI HAR Dataset/test/y_test.txt")) |
!file.exists(file.path(getwd(),"UCI HAR Dataset/test/subject_test.txt")) |
!file.exists(file.path(getwd(),"UCI HAR Dataset/train/X_train.txt")) |
!file.exists(file.path(getwd(),"UCI HAR Dataset/train/y_train.txt")) |
!file.exists(file.path(getwd(),"UCI HAR Dataset/train/subject_train.txt"))) {
@munroebot
munroebot / gist:09add51aabc095c4455a
Created April 26, 2015 14:56
File Test for assignment
#
# First make sure the datasets are available
#
if (!file.exists(file.path(getwd(),"UCI HAR Dataset/test/X2_test.txt")) |
!file.exists(file.path(getwd(),"UCI HAR Dataset/test/y_test.txt")) |
!file.exists(file.path(getwd(),"UCI HAR Dataset/test/subject_test.txt")) |
!file.exists(file.path(getwd(),"UCI HAR Dataset/train/X_train.txt")) |
!file.exists(file.path(getwd(),"UCI HAR Dataset/train/y_train.txt")) |
!file.exists(file.path(getwd(),"UCI HAR Dataset/train/subject_train.txt"))) {