Skip to content

Instantly share code, notes, and snippets.

def cached_result opts
puts opts
end
cached_result :for => 'bleh', :or => do 1+2 end
# Problem when executing:
#t.rb:5: syntax error, unexpected keyword_do_block
#cached_result :for => 'bleh', :or => do 1+2 end
# ^
adriano@planck:~/Projects/pubsub_test1$ python pubsub_test1.py
DEBUG Loaded Plugin (XEP-0060) Publish-Subscribe
WARNING Deprecated add_handler used for <message><x xmlns='jabber:x:data' /></message>: <bound method xep_0004.handler_message_xform of <sleekxmpp.plugins.xep_0004.xep_0004 object at 0x1007ca310>>.
DEBUG Loaded Plugin (XEP-0004) Data Forms
WARNING Deprecated add_handler used for <iq type='get' xmlns='jabber:client'><query xmlns='http://jabber.org/protocol/disco#info' /></iq>: <bound method xep_0030.info_handler of <sleekxmpp.plugins.xep_0030.xep_0030 object at 0x1007ca510>>.
WARNING Deprecated add_handler used for <iq type='get' xmlns='jabber:client'><query xmlns='http://jabber.org/protocol/disco#items' /></iq>: <bound method xep_0030.item_handler of <sleekxmpp.plugins.xep_0030.xep_0030 object at 0x1007ca510>>.
DEBUG Loaded Plugin (XEP-0030) Service Discovery
DEBUG Did not supply (address, port) to connect to and no SRV support is installed (http://www.dnspython.org). Continuing to
@tanob
tanob / rlsp.rb
Created November 12, 2009 01:46 — forked from h0rs3r4dish/rlsp.rb
#!/usr/bin/ruby
RLSP_VERSION = "1.4.2"
class Lambda
attr_accessor :args, :body
def initialize(args=[],body="")
@args = (args.class == Array) ? args : [args]
@body = body
end
(*This folder action script is designed to keep your downloads folder organised *)
property image_extension_list : {"tif", "tiff", "gif", "png", "pict", "pct", "jpg"}
property media_extension_list : {"mp3", "avi", "mov", "mpg"}
property document_extension_list : {"doc", "pdf", "ps", "mpg"}
property archive_extension_list : {"zip", "sit", "dmg", "tar", "hqx", "toast", "rar"}
property torrent_extension_list : {"torrent"}
property image_foldername : "images"