Custom Query (1098 matches)
Results (28 - 30 of 1098)
Ticket | Resolution | Summary | Owner | Reporter |
---|---|---|---|---|
#68 | fixed | [patch] status command for changing status and status message | ||
Description |
A while ago, I've written a patch which adds a status command allowing user to change status and status message. Usage of the command is as simple as: The feature is quite simple and may look stupid but it is sometimes useful especialy when using transports in Jabber or connecting to bitlbee through a BNC. --- bitlbee-1.0.orig/commands.c 2005-12-24 17:17:36.000000000 +0000 +++ bitlbee-1.0/commands.c 2005-12-24 17:32:19.000000000 +0000 @@ -51,6 +51,7 @@ { "nick", 1, cmd_nick }, { "import_buddies", 1, cmd_import_buddies }, { "qlist", 0, cmd_qlist }, + { "status", 2, cmd_status }, { NULL } }; @@ -797,3 +798,42 @@ return( 0 ); } + +int cmd_status( irc_t *irc, char **cmd ) +{ + account_t *a; + + if( cmd[3] ) + { + if( ( a = account_get( irc, cmd[1] ) ) ) + { + if( a->gc ) + { + if( a->gc->prpl && a->gc->prpl->set_away ) + a->gc->prpl->set_away( a->gc, cmd[2], cmd[3] ); + } + else + { + irc_usermsg( irc, "Account offline" ); + } + } + else + { + irc_usermsg( irc, "Invalid account" ); + } + } + else + { + if ( irc->accounts ) { + for( a = irc->accounts; a; a = a->next ) + if( a->gc && a->gc->prpl && a->gc->prpl->set_away ) + a->gc->prpl->set_away( a->gc, cmd[1], cmd[2] ); + } + else + { + irc_usermsg( irc, "No accounts known. Use 'account add' to add one." ); + } + } + + return( 0 ); +} diff -Naur bitlbee-1.0.orig/commands.h bitlbee-1.0/commands.h --- bitlbee-1.0.orig/commands.h 2005-12-24 17:17:36.000000000 +0000 +++ bitlbee-1.0/commands.h 2005-12-24 17:23:15.000000000 +0000 @@ -55,7 +55,8 @@ int cmd_nick( irc_t *irc, char **cmd ); int cmd_qlist( irc_t *irc, char **cmd ); int cmd_import_buddies( irc_t *irc, char **cmd ); -int cmd_dump( irc_t *irc, char **cmd ); +/* int cmd_dump( irc_t *irc, char **cmd ); -- why is it still here? */ +int cmd_status( irc_t *irc, char **cmd ); diff -Naur bitlbee-1.0.orig/protocols/jabber/jabber.c bitlbee-1.0/protocols/jabber/jabber.c --- bitlbee-1.0.orig/protocols/jabber/jabber.c 2005-12-24 17:17:36.000000000 +0000 +++ bitlbee-1.0/protocols/jabber/jabber.c 2005-12-24 17:32:05.000000000 +0000 @@ -1896,6 +1896,13 @@ } } + if (message) { + y = xmlnode_insert_tag(x, "status"); + char *utf8 = str_to_utf8(message); + xmlnode_insert_cdata(y, utf8, -1); + g_free(utf8); + } + gjab_send(gjc, x); xmlnode_free(x); } |
|||
#70 | fixed | Away Feature? | ||
Description |
Possibly a feature so that when you go /away and a user messages you it will provide them with the away message. A user independent setting (default set off) could possibly be implemented to allow this to auto reply for you. Just an idea whish would be neat to see implemented. :) |
|||
#71 | fixed | bitlbee sets away when user has status message (for yahoo) | ||
Description |
when a user has a status message in yahoo (but isn't set as away or busy) bitlbee says the user is away with "away" as the away message example: there is a user on my Yahoo contacts list, named Bailey her status message is "don't you love to hate... yet hate how you love?" (as seen in Yahoo Messenger) on bitlbee it says "Bailey. User is away. Away" and she doesn't have voice in the main channel |