To create new wiki account, please join us on #znc at freenode and ask admins to create a wiki account for you. You can say thanks to spambots for this inconvenience.

Difference between revisions of "Twitter"

From ZNC
Jump to: navigation, search
(restored from archive.org)
 
(One intermediate revision by one other user not shown)
Line 1: Line 1:
{{External Module}}
+
This page is outdated, lacking source code and only supported versions of ZNC below 1.0, it is pending deletion from a moderator.
 
 
This module implements a [http://twitter.com Twitter] client. It can post new tweets to your account and monitor searches, users, your timeline and your @mentions. You can stream those feeds into the *twitter query window only for you or to channels of your choice.
 
 
 
== Installing ==
 
The code for this module can be found [http://znc-msvc.googlecode.com/svn/trunk/flakes/twitter.cpp here]. Follow the [[Compiling modules]] page to compile it.
 
 
 
'''This module does not compile under ZNC version 1'''
 
 
 
'''Please note you need ZNC 0.072 or newer!'''
 
 
 
A further note, it seems like Twitter has changed their API, all the modules calls return a 404 error, and the twitter functionality is broken. (--[[User:FlyveHest|FlyveHest]] ([[User talk:FlyveHest|talk]]) 14:15, 13 November 2012 (UTC))
 
 
 
== Usage ==
 
{{Module arguments}}
 
 
 
=== Configuration ===
 
It's easy to configure. Here's the module's help output:
 
+---------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+
 
| Command                                                                              | Description                                                                                                          |
 
+---------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+
 
| LOGIN                                                                                | Use this command to initially set up the client.                                                                      |
 
| TWEET <message>                                                                      | Posts a tweet to Twitter! You can also use /me <message> in this window.                                              |
 
| STATUS                                                                                | Shows basic info about the logged in user.                                                                            |
 
| WATCH (timeline|mentions|user <screenname>|search) [#channel|nick]                    | Creates a feed to watch. user + search do not need a login. No target = this window. See also: CHANGE.                |
 
| WATCH                                                                                | Lists all active feeds.                                                                                              |
 
| CHANGE <id> (prefix|target|query|colors) <new val>                                    | Changes a feed's settings, <id> is the number from the WATCH list. Colors = (on|off). Query only applies to searches. |
 
| STYLE (user|@user|hashtag|link|timestamp|text) ([bold] [underline] [fore[,back]]|off) | Sets color and text style. Example: 'STYLE hashtag underline 4' would make all #hashtags red & underlined.            |
 
| STYLE                                                                                | Shows active styles.                                                                                                  |
 
| DELETE <id>                                                                          | Deletes the feed with the number <id> from the WATCH list.                                                            |
 
| HELP                                                                                  | This help.                                                                                                            |
 
+---------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------+
 
 
 
Example: "WATCH timeline" will allow you to watch all the tweets you are registered to on your twitter account in the "*twitter" window of your irc client. Add a channel or a user name after "WATCH timeline" to show it in a dedicated window of your irc client.
 
 
 
== Note ==
 
Contact flakes on #znc/EFNet for bug reports and suggestions.
 
 
 
=== ToDo ===
 
* Shorten URLs.
 
* <@SilverLeo> if twitter target can be *tw, why not *status or some other putmodule?
 
* would be nice to be able to disable the [time] by conf
 
* <@SHiZNO> would be nice to be able to filter search results by language
 
* <Znuff> if I'm following a person - and if I watch both Mentions and Timeline in the same window - when that person mentions me, I get the message twice in my window
 
 
 
 
 
== mIRC Helper Script ==
 
A small script to double-click enable nicks (for fast tweet replyes) and #hashtags (opens a search in your browser of choice) in the *twitter channel.
 
 
 
Currently only monitors the *twitter window
 
 
 
<pre>
 
; ZNC *twitter helper
 
; Done in 2010 by FlyveHest
 
 
 
; Variables needed
 
ON 1:START: {
 
  ; To match nicks
 
  set -e %twitterNickMatch *:
 
 
 
  ; To match hashtags
 
  set -e %twitterHashMatch #*
 
}
 
 
 
; Nick matching
 
ON ^1:HOTLINK:%twitterNickMatch:*twitter: {
 
  ; All nicks: from *twitter should be clickable
 
 
 
  return
 
}
 
 
 
ON 1:HOTLINK:%twitterNickMatch:*twitter {
 
  ; Insert "TWEET" reply in editbox
 
  /editbox -fp TWEET @ $+ $remove($1,:)
 
}
 
 
 
; Hashtag matching
 
ON ^1:HOTLINK:%twitterHashMatch:*twitter: {
 
  ; All #hashtags from *twitter should be clickable
 
 
 
  return
 
}
 
 
 
ON 1:HOTLINK:%twitterHashMatch:*twitter: {
 
  ; Doubleclicks on hashtags opens a twitter search on the clicked tag
 
  run $+(http://search.twitter.com/search?q=%23, $remove($1,$chr(35)))
 
}
 
 
 
</pre>
 
 
 
Information about loading mIRC scripts can be found [http://chanops.org/faqs/clients/how-to-load-an-mirc-script-into-your-main-mirc-program.html here].
 

Latest revision as of 21:03, 3 April 2017

This page is outdated, lacking source code and only supported versions of ZNC below 1.0, it is pending deletion from a moderator.