stevencorona / ruby-twitpic Goto Github PK
View Code? Open in Web Editor NEWClient library for accessing the TwitPic API with the Ruby language.
Home Page: http://meltingice.github.com/ruby-twitpic
License: BSD 3-Clause "New" or "Revised" License
Client library for accessing the TwitPic API with the Ruby language.
Home Page: http://meltingice.github.com/ruby-twitpic
License: BSD 3-Clause "New" or "Revised" License
Hello,
Please, make a gem from this library.
Hey,
I'm trying to implement your library but I got some issues.
First I've installed necessary gems:
carlo@hd:~/public_html/hdr3dev$ gem install twitpic
Fetching: highline-1.6.5.gem (100%)
Fetching: oauth-0.4.5.gem (100%)
Fetching: rubytter-1.4.2.gem (100%)
Fetching: twitpic-0.3.1.gem (100%)
Successfully installed highline-1.6.5
Successfully installed oauth-0.4.5
Successfully installed rubytter-1.4.2
Successfully installed twitpic-0.3.1
4 gems installed
carlo@hd:~/public_html/hdr3dev$ gem install twitpic-full
Fetching: nestful-0.0.7.gem (100%)
Fetching: json-1.6.1.gem (100%)
Building native extensions. This could take a while...
Fetching: roauth-0.0.8.gem (100%)
Fetching: twitpic-full-1.0.0.gem (100%)
Fetching: multi_json-1.0.3.gem (100%)
Successfully installed nestful-0.0.7
Successfully installed json-1.6.1
Successfully installed roauth-0.0.8
Successfully installed twitpic-full-1.0.0
Successfully installed multi_json-1.0.3
5 gems installed
I edited environment.rb as following:
config.gem 'twitpic-full', :require => 'twitpic'
Then I've edited my code as below:
class PhotosController < ApplicationController
def posttwitpic
@photo = Photo.find(7)
twitpic = TwitPic::Client.new
# This part is optional and only required if you are calling
# write enabled methods against the TwitPic API.
twitpic.configure do |conf|
conf.api_key = "..."
conf.consumer_key = "..."
conf.consumer_secret = "..."
conf.oauth_token = "..."
conf.oauth_secret = "..."
end
media = twitpic.upload("#{@photo.cloudfront_url(:medium)}", "TwitPic test #photography")
end
end
This is the error I got:
uninitialized constant PhotosController::TwitPic
Can you help me with this?
Hi,
Does this gem also offer an option like this? On twitpic Web page one can set this. Would be nice!
thank you
m.
Hi meltingice,
I noticed that on rubygems we have version 1.0.1 of ruby-twitpic (twitpic-full) but on github we do have version 1.0.0. Is there a reason for that? Which is the more recent gem now, the one here or the one on rubygems.
thank you
p
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.