Skip to content

Instantly share code, notes, and snippets.

View Syd's full-sized avatar

Scott Wisely Syd

View GitHub Profile
Adopt a section!
The Sinatra Book (http://github.com/cschneid/sinatra-book/tree/master) needs a little love.
I'm proposing a few of us adopt a small section of the book each to continue to contribute and maintain, particularly for the inevitable 1.0 release.
So, how do you help?
Contribute what you can to a section as well as check spelling, grammar, relevance, and correctness (do the given code and config examples still apply to the current release?). Build it, can it be formatted better? (lets not forget the PDF!).
Also remember to check the markdown is sane.
/**
* dm_basics.sp
* Base CS:S DM admin/control functions.
* This file is part of CS:S DM, Copyright (C) 2005-2007 AlliedModders LLC
* by David "BAILOPAN" Anderson, http://www.bailopan.net/cssdm/
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
require 'rubygems'
require 'nokogiri'
require 'open-uri'
url = open("http://steamcommunity.com/id/syd/friends")
doc = Nokogiri::HTML(url)
doc.xpath('//a[@class="linkFriend_online"]').each {|x| puts x.text}
require 'open-uri'
require 'rubygems'
require 'hpricot'
require 'rss/maker'
content = RSS::Maker.make("2.0") do |feed|
feed.channel.title = "gamearena forums - enemy territory"
feed.channel.link = "http://www.gamearena.com.au"
feed.channel.description = "GA ET forums"