Class: Twpipe
- Inherits:
-
Object
- Object
- Twpipe
- Defined in:
- lib/twpipe.rb,
lib/twpipe/version.rb
Overview
Twpipe
Defined Under Namespace
Classes: ConfigError
Constant Summary collapse
- VERSION =
'0.0.1'
Class Attribute Summary collapse
-
.config_path ⇒ Object
- config_path
-
the file path to configuration file.
Instance Attribute Summary collapse
-
#client ⇒ Object
readonly
- client
-
twitter client that authenticated by oAuth (Twitter::Base).
Instance Method Summary collapse
-
#initialize ⇒ Twpipe
constructor
A new instance of Twpipe.
-
#tweet(message) ⇒ Object
tweet your message.
Constructor Details
#initialize ⇒ Twpipe
Returns a new instance of Twpipe.
22 23 24 25 |
# File 'lib/twpipe.rb', line 22 def initialize setup_config setup_client end |
Class Attribute Details
.config_path ⇒ Object
- config_path
-
the file path to configuration file
12 13 14 |
# File 'lib/twpipe.rb', line 12 def config_path @config_path end |
Instance Attribute Details
#client ⇒ Object (readonly)
- client
-
twitter client that authenticated by oAuth (Twitter::Base)
20 21 22 |
# File 'lib/twpipe.rb', line 20 def client @client end |
Instance Method Details
#tweet(message) ⇒ Object
tweet your message
message: string variable that you would tweet
31 32 33 |
# File 'lib/twpipe.rb', line 31 def tweet() @client.update() end |