usaidwat 0.1.1 → 0.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/README.textile +60 -0
- data/features/browse.feature +324 -165
- data/features/help.feature +1 -1
- data/lib/usaidwat/application.rb +2 -2
- data/lib/usaidwat/formatter.rb +6 -7
- data/lib/usaidwat/version.rb +1 -1
- data/spec/spec_helper.rb +7 -0
- data/spec/usaidwat/formatter_spec.rb +6 -5
- data/usaidwat.gemspec +7 -6
- metadata +43 -27
- data/README.md +0 -29
data/README.textile
ADDED
@@ -0,0 +1,60 @@
|
|
1
|
+
h1(#usaidwat). usaidwat
|
2
|
+
|
3
|
+
Are you a Redditor? Do you use Ruby? Do you want to view the subreddits in which a particular user commonly posts? If you answered "yes" to all three of these questions, then *usaidwat* is the gem for you!
|
4
|
+
|
5
|
+
h2(#install). Installation
|
6
|
+
|
7
|
+
*usaidwat* can be installed via RubyGems:
|
8
|
+
|
9
|
+
bc. $ gem install usaidwat
|
10
|
+
|
11
|
+
h2(#usage). Usage
|
12
|
+
|
13
|
+
A @usaidwat@ binary is installed with the gem. @usaidwat@ will analyze a user's last 100 comments and provide statistics.
|
14
|
+
|
15
|
+
To list a Redditor's comments, simply plug in a username:
|
16
|
+
|
17
|
+
bc. $ usaidwat jedberg
|
18
|
+
|
19
|
+
To list a count of subreddits in which a user has posted, pass the @--tally@ flag:
|
20
|
+
|
21
|
+
bc. $ usaidwat -t jedberg
|
22
|
+
|
23
|
+
You will see output like the following:
|
24
|
+
|
25
|
+
bc. blog 26
|
26
|
+
funny 15
|
27
|
+
unitedkingdom 12
|
28
|
+
Random_Acts_Of_Pizza 11
|
29
|
+
AskReddit 7
|
30
|
+
entertainment 4
|
31
|
+
politics 4
|
32
|
+
TheoryOfReddit 3
|
33
|
+
Frugal 3
|
34
|
+
technology 2
|
35
|
+
fffffffuuuuuuuuuuuu 2
|
36
|
+
wikipedia 2
|
37
|
+
pics 1
|
38
|
+
programming 1
|
39
|
+
sex 1
|
40
|
+
space 1
|
41
|
+
movies 1
|
42
|
+
geek 1
|
43
|
+
comics 1
|
44
|
+
videos 1
|
45
|
+
apple 1
|
46
|
+
|
47
|
+
Which indicates that jedberg has commented in @/r/funny@ 15 times (out of his last 100 comments).
|
48
|
+
|
49
|
+
To see the comments for a specific subreddit, tack on that subreddit:
|
50
|
+
|
51
|
+
bc. $ usaidwat jedberg funny
|
52
|
+
|
53
|
+
All the comments for the given subreddit will be printed.
|
54
|
+
|
55
|
+
h2(#testing). Testing
|
56
|
+
|
57
|
+
Test suites can be run with RSpec and Cucumber. Note that there is one tiny wrinkle: a testing server that mimics the Reddit web service must be run before running Cucumber tests:
|
58
|
+
|
59
|
+
bc. $ ruby features/server/reddit.rb
|
60
|
+
$ cucumber
|