markpasc.org

Stapler: Code

Code

Footbridge
Kit
POT.py
Stapler

Stapler, a web site to news feed tool for Radio UserLand by Mark Paschal <stapler@markpasc.org>

Download Stapler 2.2.2 (11 October 2002, zip)

Screenshot of a single Stapler feed's page Screenshot of Stapler Feeds page

Stapler is an RSS extractor tool for Radio UserLand: it creates syndication feeds from web sites and other content. These feeds can be used with Radio UserLand's News Aggregator or other XML syndication software. General scripts for extracting feeds with CSS-like selectors and regular expressions are included as well as several special purpose scripts, and Stapler is expandable with your own scripts written in Radio's UserTalk language. Stapler features a full tool website for browser-based configuration and documentation. Stapler is published under a BSD license.

You may also be interested in eVectors RssDistiller.

XML Get news about Stapler in RSS.

If you enjoy Stapler and wish to help continue its development and the development of nifty software like it, see the "Shareware" file in the Stapler archive.

Stapler 2.2.2 is for Radio UserLand 8. Stapler 1.2.0 is still available for Radio UserLand 7.

Installing Stapler

  1. Unzip Stapler.root to your Radio Tools directory.

  2. Open Radio's Tools page. If Stapler is disabled, enable it.

Upgrading Stapler

NOTE: If you have a version of Stapler before 1.7.3 or 1.7.4, upgrade to 1.7.4 before upgrading to 2.2.2, or remove Stapler and install afresh.

  1. Close Radio.

  2. Unzip Stapler.root from the archive over the one in your Radio Tools directory.

  3. Start Radio.

If you have trouble with the install, find a bug, or have any other comments or questions, email me at stapler@markpasc.org with your problem.

Using Stapler

Open the Stapler web site with the Tools->Stapler->"View in browser" menu option (or by going to http://127.0.0.1:5335/Stapler/ in your browser). Click the Help option for instructions on using Stapler.

Version history

2.2.2, 11 October 2002: Added RSS 1.0 format. Apostrophes in scanner and format data fields are no longer incorrectly encoded to "&apos;". Checkbox options are correctly updated when unchecked.

2.2.1, 12 August 2002: Feed descriptions are correctly written to disk. Feeds with no items no longer cause Stapler to write badly formed XML. Added radioComments scanner to provide a feed informing you of new comments to your Radio weblog. The blogHeadlines scanner ignores titles of "Untitled," abbreviating the item content instead. The beforeAndAfter scanner has an "Include Before and After strings" option. Scanner options shown in textareas are now properly escaped. Using the "Subscribe" button only writes the feed to disk if the file didn't already exist. Added StaplerSuite.tools.newItem (feed) script for use by scanner authors.

2.2.0, 23 July 2002: Feeds can be exported to and imported from XML files. The beforeAndAfter scanner, which makes items from whatever is between specified strings, is available. Regex scanner now uses patterns of backreferences (eg \1: \2) instead of groups for item data. Stapler provides an option to disable upstreaming in its publishing directory. Scanners' scanner-specific data can be presented in textareas, not just text fields.

2.1.0, 12 July 2002: Weather Underground scanner is fixed. The selector scanner can be called by other scanners without passing a feed. Pages in Stapler's HTTP cache more than a week old, such as those for feeds with date variables in their URLs, are deleted. The HTTP user-agent string Stapler users is settable in preferences.

2.0.3, 23 May 2002: Recursion problems attempting to upgrading the data file are fixed. Whether it's time to scan is calculated more safely with respect to bad input data.

2.0.1, 23 May 2002: The "Subscribe" button didn't work. Stapler would only automatically upgrade its data table before a scan; now it also does so when viewing Stapler's web page.

2.0.0, 21 May 2002: Stapler no longer uses the concept of sources that are grouped into feeds; there are only feeds, some of which aggregate the items of other feeds. This is a big internal change.

1.7.4, 5 May 2002: The blogHeadlines scraper honors posts' titles, if present. The "upgradeData" script is run automatically during the hourly scan if it needs running. Problem conditions discovered by the upgradeData script were displayed in dialog boxes that were sometimes too small for their messages; these errors are now written to the Radio Events Log, with appropriate dialog box. Interim release before Stapler 2.0, if all goes according to plan.

1.2.0, 29 September 2001: Feeds can be published in RSS 0.91, RSS 0.92, or any document formats you add; feeds have "View Feed" pages; Weather Underground scraper; feed "never scanned" bug fixed; more control options for scraping sources.

More version history