ayadn 1.4.6 → 1.5.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +0 -1
- data/CHANGELOG.md +14 -1
- data/README.md +38 -13
- data/ayadn.gemspec +2 -2
- data/doc/01-index.md +38 -0
- data/doc/02-install.md +24 -0
- data/doc/03-first-steps.md +161 -0
- data/doc/04-options.md +13 -0
- data/doc/05-streams.md +288 -0
- data/doc/06-post.md +109 -0
- data/doc/07-actions.md +115 -0
- data/doc/08-listings.md +85 -0
- data/doc/09-accounts.md +33 -0
- data/doc/10-nicerank.md +58 -0
- data/doc/11-blacklist.md +85 -0
- data/doc/12-alias.md +57 -0
- data/doc/13-bookmark.md +51 -0
- data/doc/14-set.md +139 -0
- data/doc/15-nowplaying.md +23 -0
- data/doc/16-contact.md +29 -0
- data/doc/17-shortcuts.md +8 -0
- data/doc/18-examples.md +43 -0
- data/lib/ayadn/action.rb +147 -88
- data/lib/ayadn/api.rb +19 -37
- data/lib/ayadn/app.rb +4 -5
- data/lib/ayadn/databases.rb +0 -6
- data/lib/ayadn/debug.rb +6 -0
- data/lib/ayadn/endpoints.rb +5 -1
- data/lib/ayadn/mark.rb +2 -2
- data/lib/ayadn/nicerank.rb +34 -10
- data/lib/ayadn/post.rb +20 -0
- data/lib/ayadn/set.rb +0 -37
- data/lib/ayadn/settings.rb +32 -20
- data/lib/ayadn/version.rb +1 -1
- data/lib/ayadn/view.rb +52 -32
- data/lib/ayadn/workers.rb +54 -15
- data/spec/unit/api_spec.rb +0 -27
- data/spec/unit/view_spec.rb +11 -11
- data/spec/unit/workers_spec.rb +46 -47
- metadata +23 -5
data/doc/06-post.md
ADDED
@@ -0,0 +1,109 @@
|
|
1
|
+
# POST
|
2
|
+
|
3
|
+
Simple and fast way to post a short sentence/word to App.net.
|
4
|
+
|
5
|
+
`ayadn post Hello from Ayadn`
|
6
|
+
|
7
|
+
`ayadn -P Hello from Ayadn`
|
8
|
+
|
9
|
+
`ayadn -P @ericd hello Eric`
|
10
|
+
|
11
|
+
You have to put your text between single quotes if you're using punctuation:
|
12
|
+
|
13
|
+
`ayadn -P 'Hello from Ayadn, guys!'`
|
14
|
+
|
15
|
+
But remember you can't then use any `'` character!
|
16
|
+
|
17
|
+
**So you should rather use either the _write_ or the _auto_ method for posting.**
|
18
|
+
|
19
|
+
# WRITE
|
20
|
+
|
21
|
+
Multi-line post to App.net.
|
22
|
+
|
23
|
+
This is the recommended way to post elaborate text to ADN:
|
24
|
+
|
25
|
+
`ayadn write`
|
26
|
+
|
27
|
+
`ayadn -W`
|
28
|
+
|
29
|
+
It will show you a prompt where you can type anything, including special characters and Markdown links.
|
30
|
+
|
31
|
+
Hit ENTER to create line breaks and paragraphs.
|
32
|
+
|
33
|
+
Cancel your post with CTRC-C or send it with CTRL-D.
|
34
|
+
|
35
|
+
Just type a @username at the beginning of your post if you want to mention a specific user, as you would in any other App.net client.
|
36
|
+
|
37
|
+
# AUTO POST
|
38
|
+
|
39
|
+
Auto post every line of input.
|
40
|
+
|
41
|
+
The is the funniest way to post to ADN! :)
|
42
|
+
|
43
|
+
`ayadn auto`
|
44
|
+
|
45
|
+
In this mode, each line you type (each time you hit ENTER!) is automatically posted to ADN.
|
46
|
+
|
47
|
+
You can type anything, including special characters and Markdown links, and of course mention anyone: the only thing you can't do from this mode is _replying_ to a post in a thread.
|
48
|
+
|
49
|
+
Hit CTRL+C to exit this mode at any moment.
|
50
|
+
|
51
|
+
# REPLY
|
52
|
+
|
53
|
+
Reply to a specific post.
|
54
|
+
|
55
|
+
- You can reply by specifying the post id:
|
56
|
+
|
57
|
+
`ayadn reply 23362460`
|
58
|
+
|
59
|
+
`ayadn -R 23362460`
|
60
|
+
|
61
|
+
Ayadn will then show you the *write* prompt.
|
62
|
+
|
63
|
+
If you reply to a post containing multiple mentions, your text will be inserted between the leading mention and the other ones.
|
64
|
+
|
65
|
+
- You can also reply to the *index* of the post instead of its *id* _if you used the '--index' or '-i' option_ when previously viewing a stream:
|
66
|
+
|
67
|
+
`ayadn -R 3`
|
68
|
+
|
69
|
+
# PM (PRIVATE MESSAGE)
|
70
|
+
|
71
|
+
Send a private message to a specific user.
|
72
|
+
|
73
|
+
`ayadn pm @ericd`
|
74
|
+
|
75
|
+
Ayadn will then show you the *write* prompt.
|
76
|
+
|
77
|
+
# SEND
|
78
|
+
|
79
|
+
Send a message to an App.net CHANNEL.
|
80
|
+
|
81
|
+
`ayadn send 46217`
|
82
|
+
|
83
|
+
`ayadn -C 46217`
|
84
|
+
|
85
|
+
Ayadn will then show you the *write* prompt.
|
86
|
+
|
87
|
+
If you've already created an [alias](#alias) for the channel, you can post to it with:
|
88
|
+
|
89
|
+
`ayadn send mychannelalias`
|
90
|
+
|
91
|
+
`ayadn -C mychannelalias`
|
92
|
+
|
93
|
+
# EMBED PICTURES
|
94
|
+
|
95
|
+
You can embed one or several pictures in a post (with `post`, `write`, `reply` and `pm`).
|
96
|
+
|
97
|
+
Just add the `-e` (or `--embed`) option **at the end** of the command line, followed by one or several file paths separated by spaces.
|
98
|
+
|
99
|
+
Accepted file formats are `jpg`, `png` and `gif`.
|
100
|
+
|
101
|
+
Examples:
|
102
|
+
|
103
|
+
```
|
104
|
+
ayadn -P Meet my cat -e lolcat.jpg
|
105
|
+
ayadn -P "@ericd Hey, meet my pets" -e ~/lolcat.jpg ./doge.jpeg
|
106
|
+
ayadn -W -e ~/lolcat.png
|
107
|
+
ayadn -R 23362460 -e "Desktop/dancing lolcat.gif"
|
108
|
+
ayadn pm @ericd -e /users/dad/lol\'cat.JPG /users/mom/my\ doge.PNG
|
109
|
+
```
|
data/doc/07-actions.md
ADDED
@@ -0,0 +1,115 @@
|
|
1
|
+
# DELETE
|
2
|
+
|
3
|
+
Delete a post.
|
4
|
+
|
5
|
+
`ayadn delete 23365251`
|
6
|
+
|
7
|
+
`ayadn -D 23365251`
|
8
|
+
|
9
|
+
# DELETE MESSAGE
|
10
|
+
|
11
|
+
Delete a message.
|
12
|
+
|
13
|
+
You have to specify channel id (or alias) then message number.
|
14
|
+
|
15
|
+
`ayadn delete_m 42666 3365251`
|
16
|
+
|
17
|
+
`ayadn -DM 42666 3365251`
|
18
|
+
|
19
|
+
`ayadn -DM my_alias 3365251`
|
20
|
+
|
21
|
+
# REPOST
|
22
|
+
|
23
|
+
Repost a post.
|
24
|
+
|
25
|
+
`ayadn repost 23365251`
|
26
|
+
|
27
|
+
`ayadn -O 23365251`
|
28
|
+
|
29
|
+
# UNREPOST
|
30
|
+
|
31
|
+
Unrepost a post.
|
32
|
+
|
33
|
+
`ayadn unrepost 23365251`
|
34
|
+
|
35
|
+
`ayadn -UR 23365251`
|
36
|
+
|
37
|
+
# STAR
|
38
|
+
|
39
|
+
Star a post.
|
40
|
+
|
41
|
+
`ayadn star 23365251`
|
42
|
+
|
43
|
+
`ayadn -ST 23365251`
|
44
|
+
|
45
|
+
# UNSTAR
|
46
|
+
|
47
|
+
Unstar a post.
|
48
|
+
|
49
|
+
`ayadn unstar 23365251`
|
50
|
+
|
51
|
+
`ayadn -US 23365251`
|
52
|
+
|
53
|
+
# FOLLOW
|
54
|
+
|
55
|
+
Follow a user.
|
56
|
+
|
57
|
+
`ayadn follow @ericd`
|
58
|
+
|
59
|
+
`ayadn -FO @ericd`
|
60
|
+
|
61
|
+
# UNFOLLOW
|
62
|
+
|
63
|
+
Unfollow a user.
|
64
|
+
|
65
|
+
`ayadn unfollow @ericd`
|
66
|
+
|
67
|
+
`ayadn -UF @ericd`
|
68
|
+
|
69
|
+
# MUTE
|
70
|
+
|
71
|
+
Mute a user.
|
72
|
+
|
73
|
+
`ayadn mute @spammer`
|
74
|
+
|
75
|
+
`ayadn -MU @spammer`
|
76
|
+
|
77
|
+
# UNMUTE
|
78
|
+
|
79
|
+
Unmute a user.
|
80
|
+
|
81
|
+
`ayadn unmute @spammer`
|
82
|
+
|
83
|
+
`ayadn -UM @spammer`
|
84
|
+
|
85
|
+
# BLOCK
|
86
|
+
|
87
|
+
Block a user (same as mute but also prevents the blocked user to follow you).
|
88
|
+
|
89
|
+
`ayadn block @spammer`
|
90
|
+
|
91
|
+
`ayadn -BL @spammer`
|
92
|
+
|
93
|
+
# UNBLOCK
|
94
|
+
|
95
|
+
Unblock a user.
|
96
|
+
|
97
|
+
`ayadn unblock @spammer`
|
98
|
+
|
99
|
+
`ayadn -UB @spammer`
|
100
|
+
|
101
|
+
# DOWNLOAD
|
102
|
+
|
103
|
+
Download a file from your App.net storage (any file posted with other ADN clients).
|
104
|
+
|
105
|
+
`ayadn download 23344556`
|
106
|
+
|
107
|
+
`ayadn -df 23344556`
|
108
|
+
|
109
|
+
# PIN
|
110
|
+
|
111
|
+
Export a post's link and text, with tags, to your Pinboard account.
|
112
|
+
|
113
|
+
`ayadn pin 22790201 Ayadn gem update`
|
114
|
+
|
115
|
+
`ayadn pin 26874913 duel swords france`
|
data/doc/08-listings.md
ADDED
@@ -0,0 +1,85 @@
|
|
1
|
+
# FOLLOWERS
|
2
|
+
|
3
|
+
List followers of a user.
|
4
|
+
|
5
|
+
`ayadn followers @ericd`
|
6
|
+
|
7
|
+
`ayadn -fwr @ericd`
|
8
|
+
|
9
|
+
You can see your own list by using *me* instead of *@username*:
|
10
|
+
|
11
|
+
`ayadn -fwr me`
|
12
|
+
|
13
|
+
# FOLLOWINGS
|
14
|
+
|
15
|
+
List the users a user is following.
|
16
|
+
|
17
|
+
`ayadn followings @ericd`
|
18
|
+
|
19
|
+
`ayadn -fwg @ericd`
|
20
|
+
|
21
|
+
You can see your own list by using *me* instead of *@username*:
|
22
|
+
|
23
|
+
`ayadn -fwg me`
|
24
|
+
|
25
|
+
# CHANNELS
|
26
|
+
|
27
|
+
List your active App.net channels.
|
28
|
+
|
29
|
+
`ayadn channels`
|
30
|
+
|
31
|
+
`ayadn -ch`
|
32
|
+
|
33
|
+
# INTERACTIONS
|
34
|
+
|
35
|
+
Shows a short reminder of your recent App.net activity.
|
36
|
+
|
37
|
+
`ayadn interactions`
|
38
|
+
|
39
|
+
`ayadn -int`
|
40
|
+
|
41
|
+
# WHOREPOSTED
|
42
|
+
|
43
|
+
List users who reposted a post.
|
44
|
+
|
45
|
+
`ayadn whoreposted 22790201`
|
46
|
+
|
47
|
+
`ayadn -wor 22790201`
|
48
|
+
|
49
|
+
# MUTED
|
50
|
+
|
51
|
+
List the users you muted.
|
52
|
+
|
53
|
+
`ayadn muted`
|
54
|
+
|
55
|
+
`ayadn -mtd`
|
56
|
+
|
57
|
+
# BLOCKED
|
58
|
+
|
59
|
+
List the users you blocked.
|
60
|
+
|
61
|
+
`ayadn blocked`
|
62
|
+
|
63
|
+
`ayadn -bkd`
|
64
|
+
|
65
|
+
# SETTINGS
|
66
|
+
|
67
|
+
List current Ayadn settings.
|
68
|
+
|
69
|
+
`ayadn settings`
|
70
|
+
|
71
|
+
`ayadn -sg`
|
72
|
+
|
73
|
+
# FILES
|
74
|
+
|
75
|
+
List the files in your App.net storage.
|
76
|
+
|
77
|
+
`ayadn files`
|
78
|
+
|
79
|
+
`ayadn -fl`
|
80
|
+
|
81
|
+
List them all:
|
82
|
+
|
83
|
+
`ayadn files -a`
|
84
|
+
|
85
|
+
`ayadn -fl -a`
|
data/doc/09-accounts.md
ADDED
@@ -0,0 +1,33 @@
|
|
1
|
+
# AUTHORIZE
|
2
|
+
|
3
|
+
Authorize Ayadn for a specific user account.
|
4
|
+
|
5
|
+
`ayadn authorize`
|
6
|
+
|
7
|
+
`ayadn -auth`
|
8
|
+
|
9
|
+
Ayadn will give you a link leading to the official App.net registration page.
|
10
|
+
|
11
|
+
After your successful login, you will be redirected to the Ayadn authorization page.
|
12
|
+
|
13
|
+
Copy the code (token) you will find there and paste it into Ayadn: a new user will be created and automatically logged in.
|
14
|
+
|
15
|
+
# SWITCH
|
16
|
+
|
17
|
+
Switch between your authorized accounts.
|
18
|
+
|
19
|
+
`ayadn switch @ericd`
|
20
|
+
|
21
|
+
`ayadn switch @otheraccount`
|
22
|
+
|
23
|
+
Alternative syntax:
|
24
|
+
|
25
|
+
`ayadn -@ ericd`
|
26
|
+
|
27
|
+
`ayadn -@ otheraccount`
|
28
|
+
|
29
|
+
List your authorized accounts:
|
30
|
+
|
31
|
+
`ayadn switch -l`
|
32
|
+
|
33
|
+
`ayadn -@ -l`
|
data/doc/10-nicerank.md
ADDED
@@ -0,0 +1,58 @@
|
|
1
|
+
# NiceRank
|
2
|
+
|
3
|
+
[NiceRank](http://jasonirwin.ca/2014/05/14/thinking-about-nicerank/) is a filter provided by Jason Irwin.
|
4
|
+
|
5
|
+
Thanks to this algorithm, you will be able to filter the spammers out of the Global stream!
|
6
|
+
|
7
|
+
It provides a whole new experience of ADN, and brings you back the pleasure of discovering new people to follow.
|
8
|
+
|
9
|
+
Ayadn is compatible with NiceRank since version 1.2.
|
10
|
+
|
11
|
+
*NiceRank only works with the Global stream.*
|
12
|
+
|
13
|
+
## The scale
|
14
|
+
|
15
|
+
NiceRank analyzes App.net users, applies filters then attributes the users a score from 0 to 5.
|
16
|
+
|
17
|
+
*This is not a 'Klout' for ADN: NiceRank's only purpose is to differentiate spammers from regular users.*
|
18
|
+
|
19
|
+
An idea of the scale:
|
20
|
+
|
21
|
+
- A spammer's rank is always < 1
|
22
|
+
|
23
|
+
- A user posting a lot of automated links without being active otherwise will be < 2
|
24
|
+
|
25
|
+
- A new ADN user will typically start with 2
|
26
|
+
|
27
|
+
- A regular user will always be > 2
|
28
|
+
|
29
|
+
- Active regular users will be > 3
|
30
|
+
|
31
|
+
- Very 'social' users can be > 4
|
32
|
+
|
33
|
+
*Again, this is not a popularity ratio: far from it. It only serves as a filter for bots and spam.*
|
34
|
+
|
35
|
+
|
36
|
+
## Activate NiceRank
|
37
|
+
|
38
|
+
NiceRank is disabled by default.
|
39
|
+
|
40
|
+
Enable it with:
|
41
|
+
|
42
|
+
`ayadn set nicerank filter true`
|
43
|
+
|
44
|
+
My advice is to also filter out the few users that NiceRank haven't analyzed yet, as most of them are bots:
|
45
|
+
|
46
|
+
`ayadn set nicerank filter_unranked true`
|
47
|
+
|
48
|
+
## Threshold
|
49
|
+
|
50
|
+
Set the NiceRank threshold.
|
51
|
+
|
52
|
+
Any user with a NiceRank smaller than this value will be ignored.
|
53
|
+
|
54
|
+
`ayadn set nicerank threshold 2`
|
55
|
+
|
56
|
+
## Deactivate NiceRank
|
57
|
+
|
58
|
+
It's the same as above, with *false* instead of *true*.
|
data/doc/11-blacklist.md
ADDED
@@ -0,0 +1,85 @@
|
|
1
|
+
# BLACKLIST
|
2
|
+
|
3
|
+
The blacklist is a list of users, clients and hashtags that you don't want to ever be displayed.
|
4
|
+
|
5
|
+
Available subcommands: add, remove, import, list.
|
6
|
+
|
7
|
+
This is different from the 'mute a user' feature of the App.net API: blacklist works locally and is specific to each account.
|
8
|
+
|
9
|
+
Blacklist a client (example: IFTTT) and posts that are posted with this client won't appear in the streams.
|
10
|
+
|
11
|
+
This is a way of creating "bot-free" streams: the more bots you add to this list, the more humans you see.
|
12
|
+
|
13
|
+
Blacklist a hashtag and you will free yourself from this annoying trend you can't stand.
|
14
|
+
|
15
|
+
Blacklist a user and you won't even see posts by other users mentioning the user you blacklisted!
|
16
|
+
|
17
|
+
Oh, and you can import blacklist databases from other accounts, too.
|
18
|
+
|
19
|
+
## ADD
|
20
|
+
|
21
|
+
Adds an item to your blacklist.
|
22
|
+
|
23
|
+
Available items: client, hashtag, mention.
|
24
|
+
|
25
|
+
`ayadn blacklist add mention @shmuck`
|
26
|
+
|
27
|
+
Add a mention:
|
28
|
+
|
29
|
+
`ayadn -K add mention @shmuck`
|
30
|
+
|
31
|
+
Add a client:
|
32
|
+
|
33
|
+
`ayadn -K add client IFTTT`
|
34
|
+
|
35
|
+
Add a hashtag:
|
36
|
+
|
37
|
+
`ayadn -K add hashtag twitter`
|
38
|
+
|
39
|
+
## REMOVE
|
40
|
+
|
41
|
+
Removes an item from your blacklist.
|
42
|
+
|
43
|
+
Available items: client, hashtag, mention.
|
44
|
+
|
45
|
+
`ayadn blacklist remove mention @shmuck`
|
46
|
+
|
47
|
+
Remove a mention:
|
48
|
+
|
49
|
+
`ayadn -K remove mention @shmuck`
|
50
|
+
|
51
|
+
Remove a client:
|
52
|
+
|
53
|
+
`ayadn -K remove client IFTTT`
|
54
|
+
|
55
|
+
Remove a hashtag:
|
56
|
+
|
57
|
+
`ayadn -K remove hashtag twitter`
|
58
|
+
|
59
|
+
## LIST
|
60
|
+
|
61
|
+
List all items in your blacklist.
|
62
|
+
|
63
|
+
`ayadn blacklist list`
|
64
|
+
|
65
|
+
`ayadn -K list`
|
66
|
+
|
67
|
+
## IMPORT
|
68
|
+
|
69
|
+
Import a blacklist database in the current account.
|
70
|
+
|
71
|
+
`ayadn blacklist import '/Users/blah/backups/blacklist.db'`
|
72
|
+
|
73
|
+
`ayadn -K import '/Users/blah/backups/blacklist.db'`
|
74
|
+
|
75
|
+
## MULTIPLE TARGETS
|
76
|
+
|
77
|
+
You can add/remove several elements to/from the blacklist at once.
|
78
|
+
|
79
|
+
(For usernames, '@' prefix will automatically be added if missing.)
|
80
|
+
|
81
|
+
`ayadn -K add mention shmuck jerk mrspammer`
|
82
|
+
|
83
|
+
`ayadn -K add client ifttt pourover twitterfeed`
|
84
|
+
|
85
|
+
`ayadn -K add hashtag twitter facebook instagram`
|