JRJurman / Letteropend

A gem that exposes Letterboxd data
MIT License
5 stars 1 forks source link

Nokogiri #6

Closed JRJurman closed 10 years ago

JRJurman commented 10 years ago

There's no gem-ification, besides a few folder structure changes, but it's using nokogiri to pull in website data, and there's a formal Film.rb and List.rb which contain logic for pulling data from a given film and list, respectfully...

The examples have been modified to produce the same output with these new classes, using a hash of functions that are called in points in the class (I don't know if this is necessarily the ruby way to do this, but I think it worked out nicely).

JRJurman commented 10 years ago

@kristenmills, @nicolasmccurdy, @ethanjurman... If I could get your :+1: on this, I think this is a much cleaner way to do this code, but I won't merge until you guys have given it a quick look through...

ethanjurman commented 10 years ago

:thumbsup: The "around x movies" (especially w/o colorize) is a bit much information, that ultimately doesn't have much use being printed every other line (but besides that... most excellent)

JRJurman commented 10 years ago

@ethanjurman in the end, the example scripts are just for show... Besides, the script totally yells at you for not using colorize, so that's YOUR fault! :P

kristenmills commented 10 years ago
kristenmills commented 10 years ago

Or we should just look at the branch gem-nokogiri. I like that one.

nickserv commented 10 years ago

@JRJurman It looks good to me!

@kristenmills :+1: I agree with all of this, and I do think the gem format would help organize things further. And gem-nokogiri is just a merge of gem and nokogiri.

JRJurman commented 10 years ago

@nicolasmccurdy && @kristenmills I made it more gem-y, take a look, tell me what you think!

kristenmills commented 10 years ago

Add dependencies to the gemspec then i say :shipit:

kristenmills commented 10 years ago

colorize should be a dependency too

JRJurman commented 10 years ago

@kristenmills it's not actually used in the lib/, does that make it a dependency, if it's only in examples?

If that is the case, I might just nix the examples (or un-colorize them)

kristenmills commented 10 years ago

If the examples stay, it should be included in the dependencies. Just so the examples are runnable without any extra work. It could be a development dependency though.