TwitterAutoPoster
With this gem you can post text files to twitter.
Installation
Add this line to your application's Gemfile:
gem 'twitter_auto_poster'
And then execute:
$ bundle
Or install it yourself as:
$ gem install twitter_auto_poster
Usage
An example of using this gem to work from the command line:
user=User.new(
"consumer_key",
"consumer_secret",
"access_token",
"access_token_secret",
"login", "password")
response="work"
while response!="-exit"
puts ASKING_FOR_COMMAND
command=gets.chomp
begin
response=Parser.parse_command(command, user)
rescue Exception => ex
puts ex.
end
end
An example using this gem to work without command line:
user=User.new(
"consumer_key",
"consumer_secret",
"access_token",
"access_token_secret",
"login", "password")
user.(text) # will send single message to your twitter account
user.(file_path) # Read a file, split the data into words,
# will man the words in the message
# and send to Twitter with a specified interval (you can set interval so: user.delay=interval_value)
# Also you can set max length of messages in this way: user.message_length=max_message_length_value
Contributing
- Fork it
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Added some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create new Pull Request