1 | The Twitter module implements Twitter support for BarnOwl. It also |
---|
2 | supports automatic mirroring of some subset of Zephyrs you send to |
---|
3 | Twitter. |
---|
4 | |
---|
5 | To configure it, first |
---|
6 | |
---|
7 | * Add your twitter credentials to ~/.owl/twitter as a JSON hash, e.g. |
---|
8 | {"user":"nelhage", "password":"sekrit" } |
---|
9 | * Load the module (cp Twitter.par into ~/.owl/modules and :reload-module Twitter) |
---|
10 | * Set the twitter:class, twitter:instance, and twitter:opcode |
---|
11 | variables to the destination you want messages to be mirrored |
---|
12 | from. By default, they are -c $YOUR_USERNAME -i status -O twitter |
---|
13 | Setting twitter:opcode to "" will cause "normal" (i.e. no opcode) |
---|
14 | messages to that class/instance to be mirrored. A value of '*' |
---|
15 | works as a "match-anything" wildcard for any of the fields. |
---|
16 | |
---|
17 | Twitter.par will also receive twitters and inject them into barnowl as |
---|
18 | messages of type 'twitter'. It polls for normal messages once a |
---|
19 | minute, and direct messages every other minute. To disable polling, |
---|
20 | you can unset the 'twitter:poll' variable in BarnOwl. |
---|
21 | |
---|
22 | Twitter.par now supports other Twitter-compatible microblogging |
---|
23 | services, like identi.ca. To enable this, set the 'service' parameter |
---|
24 | in your config hash to the API URL of your service. You will likely |
---|
25 | also need to set 'apihost' and 'apirealm'. See Net::Twitter or your |
---|
26 | blogging service's documentation for more information. |
---|
27 | |
---|
28 | Twitter.par also supports using multiple Twitter and Twitter-compatible |
---|
29 | microblogging accounts from the same instance. To enable this, add |
---|
30 | additional hashes to your ~/.owl/twitter file as a JSON list, e.g. |
---|
31 | ----------8<----------cut here----------8<---------- |
---|
32 | [ |
---|
33 | { |
---|
34 | "account_nickname": "twitter", |
---|
35 | "user": "nelhage", |
---|
36 | "password": "sekrit", |
---|
37 | "default": true, |
---|
38 | "publish_tweets": true |
---|
39 | }, |
---|
40 | { |
---|
41 | "account_nickname": "identica", |
---|
42 | "service": "http://identi.ca/api", |
---|
43 | "user": "nelhage", |
---|
44 | "password": "sekriter", |
---|
45 | "publish_tweets": true |
---|
46 | } |
---|
47 | { |
---|
48 | "account_nickname": "sipb", |
---|
49 | "user": "sipb", |
---|
50 | "password":"m0ars3krit", |
---|
51 | "poll_for_tweets": false, |
---|
52 | "poll_for_dms": false, |
---|
53 | } |
---|
54 | ] |
---|
55 | ----------8<----------cut here----------8<---------- |
---|
56 | |
---|
57 | Outgoing tweets sent via ":twitter" without an explicit sender, or |
---|
58 | mirrored from zephyr, go to every account with "publish_tweets" set. |
---|
59 | |
---|
60 | Outgoing direct messages and @-replies without an explicit sender come |
---|
61 | from whichever account has "default" set. If no account has "default", |
---|
62 | the first account is assumed to have "default" set. It is an error to |
---|
63 | have more than one account with "default" set to true. |
---|
64 | |
---|
65 | There are several account-specific parameters that control the |
---|
66 | behavior of Twitter.par when using multiple accounts: |
---|
67 | |
---|
68 | * account_nickname (string, required if multiple accounts are in use) |
---|
69 | Specify a short name by which you can refer to the account, eg. |
---|
70 | "identica" (eg. :twitter-direct nelhage identica would send a |
---|
71 | direct message to @nelhage on identi.ca from your account |
---|
72 | nicknamed "identica"). |
---|
73 | |
---|
74 | * default (boolean, default false) |
---|
75 | If true, @-replies or direct messages you send without specifying |
---|
76 | an account will be sent using this account. If no account has |
---|
77 | this parameter, such messages will be sent using the first account |
---|
78 | listed. |
---|
79 | |
---|
80 | * poll_for_tweets (boolean, default true) |
---|
81 | If true, tweets sent by users this account follows will be |
---|
82 | displayed in your BarnOwl message list. |
---|
83 | |
---|
84 | * poll_for_dms (boolean, default true) |
---|
85 | If true, direct messages sent to this account will be displayed in |
---|
86 | your BarnOwl message list. |
---|
87 | |
---|
88 | * publish_tweets (boolean, default false) |
---|
89 | If true, tweets you send without specifying an account (either |
---|
90 | with the :twitter command or mirrored from a zephyr class) will be |
---|
91 | published to this account. |
---|
92 | |
---|
93 | * show_mentions (boolean, default true) |
---|
94 | If true, BarnOwl will show all tweets that mention this account's |
---|
95 | username, regardless of whether or not this account is following |
---|
96 | the sender. Has no effect if poll_for_tweets is false. |
---|