Conky

Kembali melengkapi tutorial sebelumnya tentang mempercantik desktop Ubuntu Karmic Koala dan memenuhi permintaan salah satu komentator di postingan sebelumnya.
Berikut ini langkah langkah untuk menggunakan conky di desktop ubuntu.

1. Install Conky

sudo apt-get install conky

2. Konfigurasi Conky
konfigurasi conky akan diletakkan pada berkas .conkyrc di direktori home masing2 user.
berikut ini konfigurasi yang saya gunakan (diambil dari sumber yang campur aduk dan dikombinasikan sesuai selera)

# Use Xft?
use_xft yes
xftfont DejaVu Sans:size=8
xftalpha 0.8
text_buffer_size 2048
# Update interval in seconds
update_interval 4
# This is the number of times Conky will update before quitting.
# Set to zero to run forever.
total_run_times 0
# Create own window instead of using desktop (required in nautilus)
own_window yes
own_window_transparent yes
own_window_type override
#own_window_hints undecorated,below,sticky,skip_taskbar,skip_pager
# Use double buffering (reduces flicker, may not work for everyone)
double_buffer yes
# Minimum size of text area
minimum_size 206 0
#maximum_width 200
# 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 5
# border width
border_width 1
# Default colors and also border colors
default_color white
#default_shade_color black
#default_outline_color grey
own_window_colour white
# Text alignment, other possible values are commented
#alignment top_left
alignment top_right
#alignment bottom_left
#alignment bottom_right
#alignment middle_right
# Gap between borders of screen and text
# same thing as passing -x at command line
gap_x 35
gap_y 50
# Subtract file system buffers from used memory?
no_buffers yes
# set to yes if you want all text to be in uppercase
uppercase no
# number of cpu samples to average
# set to 1 to disable averaging
cpu_avg_samples 2
# number of net samples to average
# set to 1 to disable averaging
net_avg_samples 2
# Force UTF8? note that UTF8 support required XFT
override_utf8_locale yes
# Add spaces to keep things from moving about?  This only affects certain objects.
use_spacer none
TEXT
SYSTEM ${hr 2}
#${alignc 10}${font Vtks Revolt:size=18}DalimaN${font}
${alignc 20}${font AngelicWar:size=20}d a l i m a n${font}
${alignc}don’t worry, CRASH is a feature
Kernel:  ${alignr}${kernel}
CPU1: ${cpu cpu1}% ${alignr}${cpubar cpu1 8,70}
CPU2: ${cpu cpu2}% ${alignr}${cpubar cpu2 8,70}
Freq: ${freq}MHz  ${alignr}Temp: ${acpitemp}°C
RAM: $memperc% ${alignr}${membar 8,70}
SWAP: $swapperc% ${alignr}${swapbar 8,70}
Battery: ${battery_percent BAT0}% ${alignr}${battery_bar 8,70 BAT0}
Uptime: ${alignr}${uptime}
${alignc 10}${font Arial Black:size=12}${time %H:%M}${font}
${alignc}${time %A %d %B %Y}
HD ${hr 2}
${voffset 4}Root:
${fs_used /}/${fs_size /} ${alignr}${fs_bar 8,70 /}
${voffset 4}DATA:
${fs_used /media/DATA}/${fs_size /media/DATA} ${alignr}${fs_bar 8,70 /media/DATA}
${voffset 4}Drive Temp: ${alignr}${execi 10 hddtemp /dev/sda | cut -d ” ” -f 4}
${voffset 4}Disk I/O: ${alignr}${diskio sda}
NETWORK ${hr 2}${if_existing /proc/net/route wlan0}
Up: ${upspeed wlan0} kb/s ${alignr}${upspeedgraph wlan0 8,70 BEBEBE BEBEBE}
Down: ${downspeed wlan0} kb/s ${alignr}${downspeedgraph wlan0 8,70 BEBEBE BEBEBE}
Upload: ${alignr}${totalup wlan0}
Download: ${alignr}${totaldown wlan0}
Signal: ${wireless_link_qual wlan0}% ${alignr}${wireless_link_bar 8,70 wlan0}
Local Ip: ${alignr}${addr wlan0}
${else}${if_existing /proc/net/route eth0}
Up: ${upspeed eth0} kb/s ${alignr}${upspeedgraph eth0 8,70 789E2D A7CC5C}
Down: ${downspeed eth0} kb/s ${alignr}${downspeedgraph eth0 8,70 789E2D A7CC5C}
Upload: ${alignr}${totalup eth0}
Download: ${alignr}${totaldown eth0}
Local Ip: ${alignr}${addr eth0}
${endif}${else}${if_existing /proc/net/route eth1}
Up: ${upspeed eth1} kb/s ${alignr}${upspeedgraph eth1 8,70 789E2D A7CC5C}
Down: ${downspeed eth1} kb/s ${alignr}${downspeedgraph eth1 8,70 789E2D A7CC5C}
Upload: ${alignr}${totalup eth1}
Download: ${alignr}${totaldown eth1}
Local Ip: ${alignr}${addr eth1}
${endif}${else}
${font PizzaDude Bullets:size=14}4${font}   Network Unavailable
${endif}
PROCESSES ${hr 2}
NAME $alignr MEM    CPU
${top name 1} $alignr ${top mem 1} ${top cpu 1}
${top name 2} $alignr ${top mem 2} ${top cpu 2}
${top name 3} $alignr ${top mem 3} ${top cpu 3}
${top name 4} $alignr ${top mem 4} ${top cpu 4}
${top name 5} $alignr ${top mem 5} ${top cpu 5}
#${top name 6} $alignr ${top mem 6} ${top cpu 6}
#${top name 7} $alignr ${top mem 7} ${top cpu 7}
#${top name 8} $alignr ${top mem 8} ${top cpu 8}

3. Buat Skrip wrapper untuk memanggil conky

sepertinya conky tidak akur dengan compiz jika dijalankan di awal, Jadi kita buat script berikut untuk memanggil conky 20 detik setelah compiz berjalan (atau sesuaikan dengan kondisi anda).

#!/bin/bash

sleep 20 && conky -d

letakkan di home folder misalnya dengan nama conky-start.sh , ubah mode nya menjadi executable,

chmod +x conky-start.sh

dan masukkan di startup session gnome.
buka System – Preferences – Startup Applications, dan tambahkan entry untuk conky, pada kolom command silahkan browse ke file yang kita buat tadi.

Selanjutnya kita conky akan langsung dijalankan pada waktu kita login ke desktop kita, atau untuk menjalankan manual kita bisa buka jendela run (Alt+F2) dan ketikkan conky -d

UPDATE : 31 Oct 2011

Untuk menampilkan di gnome-shell ganti pada bagian pada bagian # spesifikasi window # menjadi seperti berikut:

own_window yes
own_window_transparent yes
#own_window_type override

own_window_class Conky
own_window_type conky

own_window_hints undecorated,below,sticky,skip_taskbar,skip_pager

About Ronald Gautama

Abnormal Miscreated

Posted on Desember 21, 2009, in karmic, Tutorsial, ubuntu and tagged , , , . Bookmark the permalink. 15 Komentar.

  1. Mas.. Kok isi blog nya tentang Linux terus tho ?? Bosen..
    Mbok sekali-kali… diisi Cara Bercocok Tanam,..
    Mbabati Suket yang baik dan benar…
    Biar rada Trendy gitu…

    • lha piyee.. arep nulis politik wedi dilenyapkan.
      arep nulis komplen wedi dituntut balik.
      arep nulis bercocok tanam wis ra duwe sawah
      arep nulis tentang ndobosi wedokan kuwi wis jatahmu

  2. mo nanya neh, kok berkas .conkyrc di direktori homeq nda ada seh, padahal dah apt-get install conky,,,
    mohon bantuannya,,,,,

  3. Nice share bro,,,thank’s a lot.. 🙂
    Keep rockin

  4. sebenernya langsung saja bisakan, daripada ribet2 conky.sh
    pada Startup Applications tulis saja command “sleep 20 && conky -d” (tanpa tanda petik ” )

    btw info yg bagus (q lom tahu yg HDD info)

  5. cara supaya bisa executable gimana ya? newbie.

  6. Buat Skrip wrapper untuk memanggil conky masih gak bisa!saya menggunakan linuxmint helena gnome.

  7. kalo teman-teman mengalami kesulitan untuk menampilkan conky d front window, kunjungi blog saya
    http://penguin-edan.blogspot.com/2010/05/install-conky-di-ubuntu-lucid-lynx_4489.html

    🙂

  8. mas setelah utak atik conky kok tombol minimalis (-) clos (X) yg biasa ada dipojok kanan atas kok ilang. mengembalikannya gmn mas

  9. keren . . . . 😀
    nice share bro, thank’s berat . . .

  10. nice info tp sayang kurang detil. masalah bagi saya yang newbie (langkah no 2). kirim ke email saya dunk langkah2 yg detil. saya pake ubutu 10.10. thanks

  11. mas..punya script conky untuk netbook ga mas..kegedean script di atas

Tinggalkan komentar