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/ruby | |
# pianobar event script to create a libnotify notification when a song starts | |
# Copyright (c) 2010 | |
# Matthew M. Boedicker <matthewm@boedicker.org> | |
# Permission is hereby granted, free of charge, to any person obtaining a copy | |
# of this software and associated documentation files (the "Software"), to deal | |
# in the Software without restriction, including without limitation the rights |
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
--- notify.py.orig 2010-05-18 19:45:52.000000000 -0400 | |
+++ notify.py 2010-05-18 19:44:47.000000000 -0400 | |
@@ -29,6 +29,7 @@ | |
"icon" : "/usr/share/pixmaps/weechat.xpm", | |
"urgency" : "normal", | |
"smart_notification" : "off", | |
+ "skip_buffers" : "", # comma-separated list of buffers not to notify for | |
} | |
# Init everything |
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/ruby | |
# Apache log browser | |
require 'resolv' | |
line_re = %r{(.*?) (.*?) (.*?) \[(.*?) ([+-]\d{4})\] "(.*?) HTTP/[\d\.]+" (.*?) (.*?) "(.*?)" "(.*?)"} | |
ignore_ips = %w{ | |
} |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<fuppes_config version="0.7.2.3"> | |
<shared_objects> | |
<!--<dir>/mnt/music</dir>--> | |
<!--<itunes>/Users/.../iTunes.xml</itunes>--> | |
<dir>/home/mmb/media</dir> | |
<dir>/home/mmb/music</dir> | |
</shared_objects> | |
<network> | |
<!--empty = automatic detection--> |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<fuppes_vfolder_config version="0.2"> | |
<vfolder_layout device="default" enabled="false"> | |
<vfolder name="Genre"> | |
<vfolders property="genre"> | |
<items type="audioItem" /> | |
</vfolders> | |
</vfolder> |
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
require 'httparty' | |
class GoogleApi | |
include HTTParty | |
base_uri 'www.google.com/ig/api' | |
def self.weather(place) | |
get('', :query => { :weather => place })['xml_api_reply']['weather'] | |
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
require 'RMagick' | |
# convert image intro retro 8-bit looking image | |
# http://matthewm.boedicker.org/ | |
# find NES, SNES, etc. palette image on the web | |
palette = Magick::ImageList.new('/tmp/Palette_NTSC.png') | |
img = Magick::ImageList.new('/tmp/input.jpg') |
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 ruby | |
# tail -f /var/log/messages | ufw_block_notify.rb | |
require 'resolv' | |
rbot_remote = '/home/mmb/src/rbot/bin/rbot-remote' | |
rbot_user = '' | |
rbot_password = '' | |
channel = '' |
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
sudo apt-get install ufw | |
sudo ufw default deny | |
sudo ufw allow ssh/tcp | |
sudo ufw allow http | |
sudo ufw logging on | |
sudo ufw enable | |
sudo ufw status |
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
#++ | |
# | |
# :title: Meme generator plugin for rbot. | |
# | |
# Author:: Matthew M. Boedicker <matthewm@boedicker.org> | |
# | |
# Copyright:: (c) 2011 Matthew M. Boedicker | |
# | |
# License:: MIT | |
# |