Edit Rename Changes History Upload Download Back to Top

BottomFeederScripting

Bob Westergaard put together a simple scripting plugin for BottomFeeder awhile back. I've enhanced it to include SAX drivers (which makes script development a little easier). You can grab the tool this way:

Once you grab the tool, what next? Well, you can create scripts that create local rss files, and then subscribe to them in Bf. Here are some example scripts; if you end up developing any, please feel free to contribute!

Right click and save these scripts

Or, just grab a zip file with all the scripts.

Here's a simple sample script - once it produces the rss file, you can subscribe with a local file URL.

| writer content str rest out |
"creates the item"
contentBlock := [:builder :chunk |
	| stream |
	stream := ReadStream on: chunk.
	stream throughAll: 'SRC="'.
	builder link: (stream upTo: $").
	builder title: 'User Friendly For: ', Date today printString.
	builder description: '<a href="', chunk.
	builder pubDate: Timestamp now].

"main script"
out := 'userFriendly.xml' asFilename writeStream.
writer := RSS20_SAXWriter new output: out.
writer 
     prolog;
     startRSS;
     startChannel;
     title: 'User Friendly Feed';
     link: 'http://www.userfriendly.org/';
     description: 'User Friendly Feed';
     pubDate: Timestamp now;
     startItem;
     title: 'User Friendly For: ', Date today printString.
content := 'http://www.userfriendly.org/' asURI valueStream contents.
str := content readStream.
str throughAll: 'CARTOON FOR'.
str upToAll: 'href="'.
rest := str throughAll: '</A>'.
contentBlock value: writer value: rest.
writer 
     endItem;
     endChannel;
     endRSS.
out close.


Edit Rename Changes History Upload Download Back to Top