Please login or register.

Login with username, password and session length
Advanced search  


Visit our home page for VL info. For support and documentation, visit the Vector Linux Knowledge Center or search the Knowledge Center and this Forum using the search box above.

Author Topic: HOWTO: xmms/audacious autochange gaim status  (Read 2186 times)


  • Packager
  • Vectorite
  • ****
  • Posts: 369
HOWTO: xmms/audacious autochange gaim status
« on: January 21, 2007, 08:28:09 am »

xmms/audacious has a nice plugin, song_change which executes a script everytime the song changes. This can be used to for example to update your gaim status with the current song. Note: This requires gaim2.0.0beta and dbus to work.

1. Make a script with the following. 'mousepad'
Code: [Select]

#get params

#get status from gaim
CURR_STATUS_INDEX=$(expr match "$(gaim-send GaimSavedstatusGetCurrent)" '.*int32 \([0-9]*\)')
CURR_STATUS=$(expr match "$(gaim-send GaimSavedstatusGetMessage int32:$CURR_STATUS_INDEX)" '.*string "\(.*\)"')
STATUS=$(expr match "$CURR_STATUS" "\-\[\(.*\)\]\-")

#set status
gaim-send GaimSavedstatusSetMessage int32:$CURR_STATUS_INDEX string:"-[$STATUS]- $SONG"
gaim-send GaimSavedstatusActivate int32:$CURR_STATUS_INDEX

2. Make it executable, 'chmod a+x'
3. In xmms/audacious, enable the songchange plugin and in the command box put
Code: [Select]
<path to script>/ "%s"4. In gaim, go to tools->plugins and enable dbus example
5. In gaim, put your status inside -[  ]- ex.
-[ using xmms-songchange ]- SimCity 4 - Rush Hour
6. Enjoy :D

Note: It is possible to change the delimiter(in case your song titles  have ']-') or move some stuff around accdg to your preference.
There's no place like ~.
VL 5.8 PentiumD 2.8Ghz Registered Linux User #432836