Changeset 92cb8c4
- Timestamp:
- 2010-06-06T23:47:46Z (15 years ago)
- Branches:
- master
- Children:
- 36562b0
- Parents:
- 16834a5
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
doc/user-guide/commands.xml
r16834a5 r92cb8c4 1114 1114 1115 1115 <bitlbee-command name="identify"> 1116 <syntax>identify <password></syntax>1116 <syntax>identify [-noload|-force] <password></syntax> 1117 1117 <short-description>Identify yourself with your password</short-description> 1118 1118 … … 1124 1124 <para> 1125 1125 Once you're registered, you can change your password using <emphasis>set password <password></emphasis>. 1126 </para> 1127 1128 <para> 1129 The <emphasis>-noload</emphasis> and <emphasis>-force</emphasis> flags can be used to identify when you're logged into some IM accounts already. <emphasis>-force</emphasis> will let you identify yourself and load all saved accounts (and keep the accounts you're logged into already). 1130 </para> 1131 1132 <para> 1133 <emphasis>-noload</emphasis> will log you in but not load any accounts and settings saved under your current nickname. These will be overwritten once you save your settings (i.e. when you disconnect). 1126 1134 </para> 1127 1135 </description> -
doc/user-guide/misc.xml
r16834a5 r92cb8c4 117 117 </sect1> 118 118 119 <sect1 id="nick_changes"> 120 <title>Changing your nickname</title> 121 122 <para> 123 BitlBee now allows you to change your nickname. So far this was not possible because it made managing saved accounts more complicated. 124 </para> 125 126 <para> 127 The restriction no longer exists now though. When you change your nick (just using the <emphasis>/nick</emphasis> command), your logged-in status will be reset, which means any changes made to your settings/accounts will not be saved. 128 </para> 129 130 <para> 131 To restore your logged-in status, you need to either use the <emphasis>register</emphasis> command to create an account under the new nickname, or use <emphasis>identify -noload</emphasis> to re-identify yourself under the new nickname. The <emphasis>-noload</emphasis> flag tells the command to verify your password and log you in, but not load any new settings. See <emphasis>help identify</emphasis> for more information. 132 </para> 133 134 </sect1> 135 119 136 </chapter> -
irc_commands.c
r16834a5 r92cb8c4 89 89 irc->status &= ~USTATUS_IDENTIFIED; 90 90 irc_umode_set( irc, "-R", 1 ); 91 irc_usermsg( irc, "Changing nicks resets your identify status. " 92 "Re-identify or register a new account if you want " 93 "your configuration to be saved. See \x02help " 94 "nick_changes\x02." ); 91 95 } 92 96 -
root_commands.c
r16834a5 r92cb8c4 105 105 static void cmd_identify( irc_t *irc, char **cmd ) 106 106 { 107 storage_status_t status = storage_load( irc, cmd[1] );107 storage_status_t status; 108 108 char *account_on[] = { "account", "on", NULL }; 109 110 if( strchr( irc->umode, 'R' ) != NULL ) 109 gboolean load = TRUE; 110 char *password = cmd[1]; 111 112 if( irc->status & USTATUS_IDENTIFIED ) 111 113 { 112 114 irc_usermsg( irc, "You're already logged in." ); 113 115 return; 114 116 } 117 118 if( strncmp( cmd[1], "-no", 3 ) == 0 ) 119 { 120 load = FALSE; 121 password = cmd[2]; 122 } 123 else if( strncmp( cmd[1], "-force", 6 ) == 0 ) 124 { 125 password = cmd[2]; 126 } 127 else if( irc->b->accounts != NULL ) 128 { 129 irc_usermsg( irc, 130 "You're trying to identify yourself, but already have " 131 "at least one IM account set up. " 132 "Use \x02identify -noload\x02 or \x02identify -force\x02 " 133 "instead (see \x02help identify\x02)." ); 134 return; 135 } 136 137 if( password == NULL ) 138 { 139 MIN_ARGS( 2 ); 140 } 141 142 if( load ) 143 status = storage_load( irc, password ); 144 else 145 status = storage_check_pass( irc->user->nick, password ); 115 146 116 147 switch (status) { … … 122 153 break; 123 154 case STORAGE_OK: 124 irc_usermsg( irc, "Password accepted, settings and accounts loaded" ); 125 irc_setpass( irc, cmd[1] ); 155 irc_usermsg( irc, "Password accepted%s", 156 load ? ", settings and accounts loaded" : "" ); 157 irc_setpass( irc, password ); 126 158 irc->status |= USTATUS_IDENTIFIED; 127 159 irc_umode_set( irc, "+R", 1 ); 128 if( set_getbool( &irc->b->set, "auto_connect" ) )160 if( load && set_getbool( &irc->b->set, "auto_connect" ) ) 129 161 cmd_account( irc, account_on ); 130 162 break;
Note: See TracChangeset
for help on using the changeset viewer.