Flirting with Python – A pastebin.com plugin for xchat

Here’s the first version of an xchat plugin some friends from Venezuela and I wrote.

This is one of our first attempts to code something useful in python that’ll we hope gets to be used by someone on the opensource community who often uses pastebin.com to show their code and collaborate when they need help.

The idea is to issue /pastebin <filepath> and the plugin posts the file automatically in pastebin.com, adding your current nickname and autoselecting the programming language based on the extension of the file. Once published, it sends a message to the channel saying you just posted something, and places a link for everyone to check your code in http://pastebin.com/post_id

Download xchat pastebin.com plugin

Licensed under the GPL.

Instructions:
Save the file to your ~/.xchat2/ folder and next time you open xchat the plugin will be loaded automatically, then at any time just type /pastebin {path_to_file} and the file will be uploaded to pastebin.com and it will tell the URL where others can see your post.

Leave a Reply

Your email address will not be published. Required fields are marked *