no way to compare when less than two revisions
Differences
This shows you the differences between two versions of the page.
Previous revisionNext revision | |||
— | third_party_apps:conky [2010/01/23 05:09] – external edit 127.0.0.1 | ||
---|---|---|---|
Line 1: | Line 1: | ||
+ | ======Conky : how to show gmusicbrowser playing information====== | ||
+ | This How-To has been conceived after the experiments on Ubuntu (Feisty Fawn - 7.04), a debian-based distribution, | ||
+ | |||
+ | |||
+ | |||
+ | |||
+ | ======What is conky ?====== | ||
+ | |||
+ | Conky is "a light-weight system monitor", | ||
+ | |||
+ | Conky can also display music playing information from a few music players / jukebox like bmp, audacious, mpd. | ||
+ | |||
+ | |||
+ | |||
+ | ======Without the patch====== | ||
+ | loomsen has posted on the ubuntu forum a method to display the info in conky without patching it. | ||
+ | see [[http:// | ||
+ | |||
+ | The advantage of this method is that it works with the current conky versions (1.6 and future versions) | ||
+ | |||
+ | The disadvantage is that it needs to run a small program for each update, so it's a bit less cpu-friendly. | ||
+ | |||
+ | |||
+ | ======With the patch====== | ||
+ | Quentin Sculo has developed a patch for conky (version for conky-1.5.1 is available [[http:// | ||
+ | |||
+ | //Sadly, this patch requires a lot of modification for using it with conky version 1.6 and higher. So currently you'll have to use the method above without the patch.// | ||
+ | |||
+ | =====Download and patch conky===== | ||
+ | |||
+ | After downloading the patch, create the conkypatch directory into your /home : | ||
+ | < | ||
+ | and move the patch you have just downloaded into it : | ||
+ | < | ||
+ | to make the future operations easier. | ||
+ | |||
+ | For this, go to the conky project homepage on sourceforge.net (http:// | ||
+ | |||
+ | Move the tar archive into the conkypatch directory : < | ||
+ | |||
+ | Move into the conkypatch directory : | ||
+ | < | ||
+ | |||
+ | Untar the conky-1.5.1.tar.bz2 archive : | ||
+ | < | ||
+ | |||
+ | Go into the conky-1.5.1 directory (created with the untar) : < | ||
+ | |||
+ | Apply the patch : | ||
+ | < | ||
+ | |||
+ | =====Compile conky===== | ||
+ | |||
+ | First, check you have these packages installed on your system : gcc, make, automake1.9, | ||
+ | < | ||
+ | |||
+ | Then in the / | ||
+ | |||
+ | The terminal is quite informative ; if there are some errors or warnings, the messages it sends enable you to install the right packages. Personally, on Ubuntu Feisty Fawn, I had a conflict with several " | ||
+ | |||
+ | Once the autogen is done, it's time to achieve the compilation of conky. You can personalize this process (the " | ||
+ | |||
+ | Thus, I have launched this command :< | ||
+ | |||
+ | Whatever the options you choose, don't forget to add the option " | ||
+ | |||
+ | For this too, the terminal gives you much information which enables you to install the proper packages ; do keep in mind the -dev packages. | ||
+ | |||
+ | Once the " | ||
+ | < | ||
+ | |||
+ | I prefer using " | ||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
+ | =====Configure conky==== | ||
+ | |||
+ | For those who have just discovered conky, you must know that configuring conky means editing the conky configuration file which is a hidden file in your /home ; to edit that file, in a terminal, do : < | ||
+ | |||
+ | The patch we have just applied enables these next variables : $gmb_artist, | ||
+ | |||
+ | Here is an example of conky configuration and the corresponding capture (under Ubuntu Gutsy) : {{gallery> | ||
+ | < | ||
+ | # set to yes if you want Conky to be forked in the background | ||
+ | background no | ||
+ | |||
+ | cpu_avg_samples 2 | ||
+ | net_avg_samples 2 | ||
+ | |||
+ | out_to_console no | ||
+ | |||
+ | override_utf8_locale yes | ||
+ | |||
+ | # X font when Xft is disabled, you can pick one with program xfontsel | ||
+ | #font 8x10 | ||
+ | #font 7x13 | ||
+ | #font 8x13 | ||
+ | #font 7x12 | ||
+ | #font *mintsmild.se* | ||
+ | #font -*-*-*-*-*-*-34-*-*-*-*-*-*-* | ||
+ | #font -artwiz-snap-normal-r-normal-*-*-100-*-*-p-*-iso8859-1 | ||
+ | #font -*-luxi sans-medium-r-normal-*-13-*-*-*-*-*-iso8859-2 | ||
+ | #font -*-helvetica-medium-r-normal-*-12-*-100-100-*-*-iso8859-2 | ||
+ | #font -*-lucidatypewriter-medium-r-*-*-14-*-100-100-*-*-iso8895-2 | ||
+ | #font -*-courier-medium-r-normal-*-14-*-100-100-*-*-iso8859-2 | ||
+ | #font -*-lucida-medium-r-normal-*-13-*-*-*-*-*-iso8859-2 | ||
+ | |||
+ | # Use Xft? | ||
+ | use_xft yes | ||
+ | |||
+ | # Xft font when Xft is enabled | ||
+ | #xftfont monospace-8 | ||
+ | xftfont Sans -8.5 | ||
+ | |||
+ | |||
+ | |||
+ | # Text alpha when using Xft | ||
+ | xftalpha 0.8 | ||
+ | |||
+ | |||
+ | # mail spool | ||
+ | mail_spool $MAIL | ||
+ | |||
+ | # Update interval in seconds | ||
+ | update_interval 1 | ||
+ | |||
+ | # Create own window instead of using desktop (required in nautilus) | ||
+ | own_window_hints undecorated, | ||
+ | own_window_transparent yes | ||
+ | # | ||
+ | own_window yes | ||
+ | own_window_type override | ||
+ | |||
+ | # Use double buffering (reduces flicker, may not work for everyone) | ||
+ | double_buffer yes | ||
+ | |||
+ | # Minimum size of text area | ||
+ | minimum_size 5 | ||
+ | maximum_width 220 | ||
+ | |||
+ | # Draw shades? | ||
+ | draw_shades no | ||
+ | |||
+ | # Draw outlines? | ||
+ | draw_outline no | ||
+ | |||
+ | # Draw borders around text | ||
+ | draw_borders no | ||
+ | |||
+ | # Stippled borders? | ||
+ | stippled_borders 0 | ||
+ | |||
+ | # border margins | ||
+ | border_margin 0 | ||
+ | |||
+ | # border width | ||
+ | border_width 0 | ||
+ | |||
+ | # drawn 1 pixel border around graphs or not | ||
+ | draw_graph_borders yes | ||
+ | |||
+ | # Default colors and also border colors | ||
+ | default_color black | ||
+ | default_shade_color black | ||
+ | default_outline_color black | ||
+ | |||
+ | # Text alignment, other possible values are commented | ||
+ | #alignment top_left | ||
+ | #alignment top_right | ||
+ | #alignment bottom_left | ||
+ | alignment bottom_right | ||
+ | |||
+ | # Gap between borders of screen and text | ||
+ | |||
+ | gap_x 0 | ||
+ | gap_y 5 #margines gorny | ||
+ | |||
+ | # Add spaces to keep things from moving about? | ||
+ | use_spacer yes | ||
+ | |||
+ | # Subtract file system buffers from used memory? | ||
+ | no_buffers yes | ||
+ | |||
+ | # set to yes if you want all text to be in uppercase | ||
+ | uppercase no | ||
+ | |||
+ | # boinc (seti) dir | ||
+ | # seti_dir /opt/seti | ||
+ | |||
+ | # Possible variables to be used: | ||
+ | # | ||
+ | # Variable | ||
+ | # acpiacadapter | ||
+ | # acpifan | ||
+ | # acpitemp | ||
+ | # adt746xcpu | ||
+ | # adt746xfan | ||
+ | # battery | ||
+ | # battery. ACPI battery number can be | ||
+ | # given as argument (default is BAT0). | ||
+ | # buffers | ||
+ | # cached | ||
+ | # color | ||
+ | # cpu CPU usage in percents | ||
+ | # cpubar | ||
+ | # bar's height in pixels | ||
+ | # downspeed | ||
+ | # downspeedf | ||
+ | # decimal | ||
+ | # exec shell command | ||
+ | # the output in torsmo. warning: this | ||
+ | # takes a lot more resources than other | ||
+ | # variables. I'd recommend coding wanted | ||
+ | # behaviour in C and posting a patch : | ||
+ | # execi | ||
+ | # command | ||
+ | # update_interval in configuration. | ||
+ | # fs_bar | ||
+ | # a file system. height is the height in | ||
+ | # pixels. fs is any file on that file | ||
+ | # system. | ||
+ | # fs_free | ||
+ | # for users. | ||
+ | # fs_free_perc | ||
+ | # system available for users. | ||
+ | # fs_size | ||
+ | # fs_used | ||
+ | # hr (height) | ||
+ | # pixels | ||
+ | # i2c | ||
+ | # may be omitted if you have only one I2C | ||
+ | # device. type is either in (or vol) | ||
+ | # meaning voltage, fan meaning fan or temp | ||
+ | # meaning temperature. n is number of the | ||
+ | # sensor. See / | ||
+ | # your local computer. | ||
+ | # kernel | ||
+ | # loadavg | ||
+ | # minute, 2 for past 5 minutes and 3 for | ||
+ | # past 15 minutes. | ||
+ | # machine | ||
+ | # mails Mail count in mail spool. You can use | ||
+ | # program like fetchmail to get mails from | ||
+ | # some server using your favourite | ||
+ | # protocol. See also new_mails. | ||
+ | # mem | ||
+ | # membar | ||
+ | # memmax | ||
+ | # memperc | ||
+ | # new_mails | ||
+ | # nodename | ||
+ | # outlinecolor | ||
+ | # pre_exec | ||
+ | # torsmo displays anything and puts output | ||
+ | # as text. | ||
+ | # processes | ||
+ | # running_processes | ||
+ | # requires Linux 2.6 | ||
+ | # shadecolor | ||
+ | # stippled_hr | ||
+ | # (height) | ||
+ | # swapbar | ||
+ | # swap Amount of swap in use | ||
+ | # swapmax | ||
+ | # swapperc | ||
+ | # sysname | ||
+ | # time (format) | ||
+ | # information about format | ||
+ | # totaldown | ||
+ | # Linux with 32-bit arch and there doesn' | ||
+ | # seem to be a way to know how many times | ||
+ | # it has already done that before torsmo | ||
+ | # has started. | ||
+ | # totalup | ||
+ | # updates | ||
+ | # upspeed | ||
+ | # upspeedf | ||
+ | # decimal | ||
+ | # uptime | ||
+ | # uptime_short | ||
+ | # | ||
+ | # seti_prog | ||
+ | # seti_progbar | ||
+ | # seti_credit | ||
+ | |||
+ | |||
+ | # variable is given either in format $variable or in ${variable}. Latter | ||
+ | # allows characters right after the variable and must be used in network | ||
+ | # stuff because of an argument | ||
+ | #${font Dungeon: | ||
+ | #${font Verdana: | ||
+ | #${font Perry: | ||
+ | #${font Luxi Mono: | ||
+ | # stuff after ' | ||
+ | |||
+ | TEXT | ||
+ | ${font Verdana: | ||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
+ | ${color # | ||
+ | ${color # | ||
+ | ${color # | ||
+ | ${color # | ||
+ | ${color # | ||
+ | |||
+ | ${color # | ||
+ | ${color # | ||
+ | |||
+ | ${color # | ||
+ | ${color # | ||
+ | ${color #DBAA82}ram : ${color # | ||
+ | ${color # | ||
+ | |||
+ | ${color #FFFB00}.: ${top name 1} | ||
+ | ${color # | ||
+ | ${color #565868}.: ${top name 2} | ||
+ | ${color # | ||
+ | ${color #565868}.: ${top name 3} | ||
+ | ${color # | ||
+ | |||
+ | ${color # | ||
+ | ${color #DBAA82}/ : ${color # | ||
+ | ${color # | ||
+ | ${color # | ||
+ | ${color # | ||
+ | ${color # | ||
+ | ${color # | ||
+ | |||
+ | ${color # | ||
+ | ${color # | ||
+ | ${color # | ||
+ | |||
+ | ${color # | ||
+ | ${color # | ||
+ | ${color # | ||
+ | ${color # | ||
+ | ${color # | ||
+ | </ | ||
+ | |||
+ | You can also have something like that : | ||
+ | < | ||
+ | ${if_existing / | ||
+ | ${gmb_artist} | ||
+ | ${gmb_album} | ||
+ | ${color # | ||
+ | $alignc${voffset -21}${gmb_elapsed}/ | ||
+ | ${mpd_artist} | ||
+ | ${mpd_album} | ||
+ | ${color # | ||
+ | $alignc${voffset -21}${mpd_elapsed}/ | ||
+ | </ | ||
+ | but in this case, you have to be careful to the location of the gmusicbrowser.fifo on your computer. In Ubuntu (Gutsy) you find this file here : ~/ | ||
+ | |||
+ | For some other examples and tips and tricks you can visit [[http:// |