Partição do windows no conky (Resolvido)

Iniciado por Holmes, 21 de Outubro de 2010, 20:53

tópico anterior - próximo tópico

Holmes

Oi pessoal do forum,

Como posso incluir a partição onde está o windows no conky? não estou conseguindo.

vlw fwi, Viva 8)
EeePC 1008ha - Chakra Linux (Edn) - KDE 4.7.4 - Kernel 3.1.
- Meu Blog: http://holmeslinux.blogspot.com/
- Fundador do Chakra Brasil: http://chakra-linux.com.br/forum

niquelnausea

#1
repare na parte em negrito, é mais ou menos a estrutura para mostrar um disco montado. e o que esta em vermelho o ponto de montagem (/media/MEM_CEL e /media/MEM_CAM).

Citar
# Use Xft?
use_xft yes
xftfont DejaVu Sans:size=9:style=Bold
xftalpha 0.9
text_buffer_size 512
color0 000000
color1 E42727

# Update interval in seconds
update_interval 1

# 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 200 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 white
#own_window_colour white

# 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
# same thing as passing -x at command line
gap_x 10
gap_y 40

# 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

${template0 Root /}

TEXT
${color0}SISTEMA ${hr 2}
${voffset 3}${font OpenLogos:size=18}t ${font}${voffset -1} Kernel: ${alignr}${kernel}
${font StyleBats:size=14}a ${font}${voffset -1}Cpu: ${freq_g} GHz${alignr}${cpubar cpu1 8,50}
${font StyleBats:size=14}g ${font}${voffset -1}Ram: ${mem}${alignr}${membar 8,50}
${font StyleBats:size=14}j ${font}${voffset -1}Swap: ${swap}${alignr}${swapbar 8,50}
${font StyleBats:size=14}p ${font}${voffset -1}Ligado:${alignr}${uptime_short}

CPU ${hr 2}
${font StyleBats:size=14}a ${font}${voffset -1}${top name 1}${alignr}${top cpu 1}%
${font StyleBats:size=14}a ${font}${voffset -1}${top name 2}${alignr}${top cpu 2}%
${font StyleBats:size=14}a ${font}${voffset -1}${top name 3}${alignr}${top cpu 3}%
${font StyleBats:size=14}a ${font}${voffset -1}${top name 4}${alignr}${top cpu 4}%

MEMÓRIA ${hr 2}
${font StyleBats:size=14}g ${font}${voffset -1}${top_mem name 1}${alignr}${top mem 1}%
${font StyleBats:size=14}g ${font}${voffset -1}${top_mem name 2}${alignr}${top mem 2}%
${font StyleBats:size=14}g ${font}${voffset -1}${top_mem name 3}${alignr}${top mem 3}%
${font StyleBats:size=14}g ${font}${voffset -1}${top_mem name 4}${alignr}${top mem 4}%

HD ${hr 2}
${font Poky:size=12}a${font}  ${voffset -1}Sistema:
${fs_used /} / ${fs_size /}
${fs_bar 8,200 /}
${font Poky:size=12}p${font}  ${voffset -1}Home:
${fs_used /home} / ${fs_size /home}
${fs_bar 8,200 /home}
${font Poky:size=12}b${font}  ${voffset -1}Motorola EM25:
${if_mounted /media/MEM_CEL}${fs_used /media/MEM_CEL} / ${fs_size /media/MEM_CEL}${else}${alignr}Desmontado${endif}
${if_mounted /media/MEM_CEL}${fs_bar 8,200 /media/MEM_CEL}${else}${endif}
${font Poky:size=12}b${font}  ${voffset -1}SONY Cyber-shot S930:
${if_mounted /media/MEM_CAM}${fs_used /media/MEM_CAM} / ${fs_size /media/MEM_CAM}${else}${alignr}Desmontado${endif}
${if_mounted /media/MEM_CAM}${fs_bar 8,200 /media/MEM_CAM}${else}${endif}


REDE ${hr 2}
${font PizzaDude Bullets:size=12}U${font}  Down:${alignr}${downspeed eth0}
${downspeedgraph eth0 8,200}
${font PizzaDude Bullets:size=12}O${font}  Up:${alignr}${upspeed eth0}
${upspeedgraph eth0 8,200}

CALENDÁRIO ${hr 2}
${font DejaVu Sans:pixelsize=10:style=Bold}${alignc}${execi 60 date +"%B %Y" | tr "[:lower:]" "[:upper:]"}${font Snap.se:size=8 }
${font DejaVu Sans Mono:size=10:style=Bold}${execpi 60 cal | sed '1d' | sed '3d' | sed '2d' | sed '2d' | sed '2d' | sed '2d' | sed '2d' | sed 's/^/${alignc} /'}
${font DejaVu Sans Mono:size=10:style=Bold}${execpi 60 DJS=`date +%_d`; cal | sed '1d' | sed '/./!d' | sed 's/$/                    /' | fold -w 21 | sed -n '/^.\{21\}/p' | sed 's/^/${alignc} /' | sed /" $DJS "/s/" $DJS "/" "'${color1}'"$DJS"'${color0}'" "/}

Holmes

Citação de: niquelnausea online 21 de Outubro de 2010, 21:17
repare na parte em negrito, é mais ou menos a estrutura para mostrar um disco montado. e o que esta em vermelho o ponto de montagem (/media/MEM_CEL e /media/MEM_CAM).

Citar
# Use Xft?
use_xft yes
xftfont DejaVu Sans:size=9:style=Bold
xftalpha 0.9
text_buffer_size 512
color0 000000
color1 E42727

# Update interval in seconds
update_interval 1

# 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 200 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 white
#own_window_colour white

# 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
# same thing as passing -x at command line
gap_x 10
gap_y 40

# 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

${template0 Root /}

TEXT
${color0}SISTEMA ${hr 2}
${voffset 3}${font OpenLogos:size=18}t ${font}${voffset -1} Kernel: ${alignr}${kernel}
${font StyleBats:size=14}a ${font}${voffset -1}Cpu: ${freq_g} GHz${alignr}${cpubar cpu1 8,50}
${font StyleBats:size=14}g ${font}${voffset -1}Ram: ${mem}${alignr}${membar 8,50}
${font StyleBats:size=14}j ${font}${voffset -1}Swap: ${swap}${alignr}${swapbar 8,50}
${font StyleBats:size=14}p ${font}${voffset -1}Ligado:${alignr}${uptime_short}

CPU ${hr 2}
${font StyleBats:size=14}a ${font}${voffset -1}${top name 1}${alignr}${top cpu 1}%
${font StyleBats:size=14}a ${font}${voffset -1}${top name 2}${alignr}${top cpu 2}%
${font StyleBats:size=14}a ${font}${voffset -1}${top name 3}${alignr}${top cpu 3}%
${font StyleBats:size=14}a ${font}${voffset -1}${top name 4}${alignr}${top cpu 4}%

MEMÓRIA ${hr 2}
${font StyleBats:size=14}g ${font}${voffset -1}${top_mem name 1}${alignr}${top mem 1}%
${font StyleBats:size=14}g ${font}${voffset -1}${top_mem name 2}${alignr}${top mem 2}%
${font StyleBats:size=14}g ${font}${voffset -1}${top_mem name 3}${alignr}${top mem 3}%
${font StyleBats:size=14}g ${font}${voffset -1}${top_mem name 4}${alignr}${top mem 4}%

HD ${hr 2}
${font Poky:size=12}a${font}  ${voffset -1}Sistema:
${fs_used /} / ${fs_size /}
${fs_bar 8,200 /}
${font Poky:size=12}p${font}  ${voffset -1}Home:
${fs_used /home} / ${fs_size /home}
${fs_bar 8,200 /home}
${font Poky:size=12}b${font}  ${voffset -1}Motorola EM25:
${if_mounted /media/MEM_CEL}${fs_used /media/MEM_CEL} / ${fs_size /media/MEM_CEL}${else}${alignr}Desmontado${endif}
${if_mounted /media/MEM_CEL}${fs_bar 8,200 /media/MEM_CEL}${else}${endif}
${font Poky:size=12}b${font}  ${voffset -1}SONY Cyber-shot S930:
${if_mounted /media/MEM_CAM}${fs_used /media/MEM_CAM} / ${fs_size /media/MEM_CAM}${else}${alignr}Desmontado${endif}
${if_mounted /media/MEM_CAM}${fs_bar 8,200 /media/MEM_CAM}${else}${endif}


REDE ${hr 2}
${font PizzaDude Bullets:size=12}U${font}  Down:${alignr}${downspeed eth0}
${downspeedgraph eth0 8,200}
${font PizzaDude Bullets:size=12}O${font}  Up:${alignr}${upspeed eth0}
${upspeedgraph eth0 8,200}

CALENDÁRIO ${hr 2}
${font DejaVu Sans:pixelsize=10:style=Bold}${alignc}${execi 60 date +"%B %Y" | tr "[:lower:]" "[:upper:]"}${font Snap.se:size=8 }
${font DejaVu Sans Mono:size=10:style=Bold}${execpi 60 cal | sed '1d' | sed '3d' | sed '2d' | sed '2d' | sed '2d' | sed '2d' | sed '2d' | sed 's/^/${alignc} /'}
${font DejaVu Sans Mono:size=10:style=Bold}${execpi 60 DJS=`date +%_d`; cal | sed '1d' | sed '/./!d' | sed 's/$/                    /' | fold -w 21 | sed -n '/^.\{21\}/p' | sed 's/^/${alignc} /' | sed /" $DJS "/s/" $DJS "/" "'${color1}'"$DJS"'${color0}'" "/}

Oi  niquelnausea,

Olha o que fiz:

Windows: $alignr ${if_mounted /dev/sda1} ${fs_used /dev/sda1} / ${fs_size /dev/sda1}${else}${alignr}Desmontado${endif}${if_mounted /dev/sda1}
${fs_bar 4 /dev/sda1}

No conky ele aparece desmontado. Pq? Fiz algo de errado?

vlw fwi, Viva 8)
EeePC 1008ha - Chakra Linux (Edn) - KDE 4.7.4 - Kernel 3.1.
- Meu Blog: http://holmeslinux.blogspot.com/
- Fundador do Chakra Brasil: http://chakra-linux.com.br/forum

niquelnausea

ta errado, monte a partição e coloque o endereço no lugar de /media/sda1. repare que no meu esta /media/MEM_CEL (que é o ponto de montagem), a sua provavelmente sera /media/eummontedeletrasenumeros
quando montada ele vai mostrar alguns dados, quando desmontado vai mostrar a mensagem Desmontado

Holmes

Citação de: Viva online 21 de Outubro de 2010, 22:49
Citação de: niquelnausea online 21 de Outubro de 2010, 21:17
repare na parte em negrito, é mais ou menos a estrutura para mostrar um disco montado. e o que esta em vermelho o ponto de montagem (/media/MEM_CEL e /media/MEM_CAM).

Citar
# Use Xft?
use_xft yes
xftfont DejaVu Sans:size=9:style=Bold
xftalpha 0.9
text_buffer_size 512
color0 000000
color1 E42727

# Update interval in seconds
update_interval 1

# 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 200 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 white
#own_window_colour white

# 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
# same thing as passing -x at command line
gap_x 10
gap_y 40

# 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

${template0 Root /}

TEXT
${color0}SISTEMA ${hr 2}
${voffset 3}${font OpenLogos:size=18}t ${font}${voffset -1} Kernel: ${alignr}${kernel}
${font StyleBats:size=14}a ${font}${voffset -1}Cpu: ${freq_g} GHz${alignr}${cpubar cpu1 8,50}
${font StyleBats:size=14}g ${font}${voffset -1}Ram: ${mem}${alignr}${membar 8,50}
${font StyleBats:size=14}j ${font}${voffset -1}Swap: ${swap}${alignr}${swapbar 8,50}
${font StyleBats:size=14}p ${font}${voffset -1}Ligado:${alignr}${uptime_short}

CPU ${hr 2}
${font StyleBats:size=14}a ${font}${voffset -1}${top name 1}${alignr}${top cpu 1}%
${font StyleBats:size=14}a ${font}${voffset -1}${top name 2}${alignr}${top cpu 2}%
${font StyleBats:size=14}a ${font}${voffset -1}${top name 3}${alignr}${top cpu 3}%
${font StyleBats:size=14}a ${font}${voffset -1}${top name 4}${alignr}${top cpu 4}%

MEMÓRIA ${hr 2}
${font StyleBats:size=14}g ${font}${voffset -1}${top_mem name 1}${alignr}${top mem 1}%
${font StyleBats:size=14}g ${font}${voffset -1}${top_mem name 2}${alignr}${top mem 2}%
${font StyleBats:size=14}g ${font}${voffset -1}${top_mem name 3}${alignr}${top mem 3}%
${font StyleBats:size=14}g ${font}${voffset -1}${top_mem name 4}${alignr}${top mem 4}%

HD ${hr 2}
${font Poky:size=12}a${font}  ${voffset -1}Sistema:
${fs_used /} / ${fs_size /}
${fs_bar 8,200 /}
${font Poky:size=12}p${font}  ${voffset -1}Home:
${fs_used /home} / ${fs_size /home}
${fs_bar 8,200 /home}
${font Poky:size=12}b${font}  ${voffset -1}Motorola EM25:
${if_mounted /media/MEM_CEL}${fs_used /media/MEM_CEL} / ${fs_size /media/MEM_CEL}${else}${alignr}Desmontado${endif}
${if_mounted /media/MEM_CEL}${fs_bar 8,200 /media/MEM_CEL}${else}${endif}
${font Poky:size=12}b${font}  ${voffset -1}SONY Cyber-shot S930:
${if_mounted /media/MEM_CAM}${fs_used /media/MEM_CAM} / ${fs_size /media/MEM_CAM}${else}${alignr}Desmontado${endif}
${if_mounted /media/MEM_CAM}${fs_bar 8,200 /media/MEM_CAM}${else}${endif}


REDE ${hr 2}
${font PizzaDude Bullets:size=12}U${font}  Down:${alignr}${downspeed eth0}
${downspeedgraph eth0 8,200}
${font PizzaDude Bullets:size=12}O${font}  Up:${alignr}${upspeed eth0}
${upspeedgraph eth0 8,200}

CALENDÁRIO ${hr 2}
${font DejaVu Sans:pixelsize=10:style=Bold}${alignc}${execi 60 date +"%B %Y" | tr "[:lower:]" "[:upper:]"}${font Snap.se:size=8 }
${font DejaVu Sans Mono:size=10:style=Bold}${execpi 60 cal | sed '1d' | sed '3d' | sed '2d' | sed '2d' | sed '2d' | sed '2d' | sed '2d' | sed 's/^/${alignc} /'}
${font DejaVu Sans Mono:size=10:style=Bold}${execpi 60 DJS=`date +%_d`; cal | sed '1d' | sed '/./!d' | sed 's/$/                    /' | fold -w 21 | sed -n '/^.\{21\}/p' | sed 's/^/${alignc} /' | sed /" $DJS "/s/" $DJS "/" "'${color1}'"$DJS"'${color0}'" "/}

Oi  niquelnausea,

Olha o que fiz:

Windows: $alignr ${if_mounted /dev/sda1} ${fs_used /dev/sda1} / ${fs_size /dev/sda1}${else}${alignr}Desmontado${endif}${if_mounted /dev/sda1}
${fs_bar 4 /dev/sda1}

No conky ele aparece desmontado. Pq? Fiz algo de errado?

vlw fwi, Viva 8)

Oi  niquelnausea,

Fiz uma coisa errada o correto é /media/30646F05646ECD62 e não /dev/sda1.
Obrigado pela ajuda...

vlw fwi, Viva 8)
EeePC 1008ha - Chakra Linux (Edn) - KDE 4.7.4 - Kernel 3.1.
- Meu Blog: http://holmeslinux.blogspot.com/
- Fundador do Chakra Brasil: http://chakra-linux.com.br/forum