Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
adding fav support refactor timeline and mentions
- Loading branch information
Showing
10 changed files
with
190 additions
and
40 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,12 @@ | ||
1. A way to filter tweets that contains something | ||
|
||
|
||
3endi moshkeleh be shell.execStack , wain a7san ma7al to reset it !?!!!! | ||
3endi moshkeleh be shell.execStack , wain a7san ma7al to reset it !?!!!! | ||
|
||
|
||
Usful command to check the tcpdump: | ||
sudo tcpdump -i en1 -A -s 1024 -l | tee dump.log | grep twitter | ||
|
||
|
||
|
||
post %r{/twitter/timelines/(user_timeline|friends_timeline|mentions|retweeted_by_me|retweeted_to_me|retweets_of_me)} do |action| |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
module TwitterOAuth | ||
class Client | ||
|
||
# The favorites method defined in twitter oauth doesn't allow u | ||
# to specifiy the user using the screen_name param. So i am remaning the favorites to old_favorites | ||
# and re-writting favorites. | ||
#alias old_favorites favorites | ||
alias_method :old_favorites, :to_s | ||
|
||
|
||
def favorites(options = {}) | ||
puts "XXXXXXXXXXXXXXXXXX" | ||
puts options.inspect | ||
args = options.map{|k,v| "#{k}=#{v}"}.join('&') | ||
get("/favorites.json?#{args}") | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
module TwitterOAuth | ||
class Client | ||
# Find the mentions given the username. | ||
# This function doesn't rely on twitter mentions api because api only returns | ||
# mentions for the authenticated users. So i am using the search api get it. | ||
def public_mentions(username,options) | ||
puts "username == #{username}" | ||
search("@#{username}", options) | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters