Hallo,
ich habe mich in die Welt von Conky begeben und ein Conky für mich angepasst. Im Grunde habe ich gcalcli genutzt, um eine Agenda meines Google-Kalenders einzubinden.
Erstmal die .conkyrc
# Conky Google Now style # # Conky settings # background no update_interval 1 double_buffer yes no_buffers yes # Window specifications # own_window yes own_window_type normal own_window_hints undecorated,below,sticky,skip_taskbar,skip_pager own_window_title own_window_argb_visual true own_window_argb_value 0 own_window_transparent yes maximum_width 320 # Alignment # alignment tr gap_x 20 gap_y 50 border_inner_margin 15 border_outer_margin 0 # Graphics settings # draw_shades no draw_outline no draw_borders no draw_graph_borders no max_user_text 32768 text_buffer_size 8192 # Text settings # use_xft yes xftalpha 0 xftfont Open Sans Light:size=10 override_utf8_locale yes imlib_cache_size 0 F9F9F9 # Color scheme # default_color FFFFFF color1 FFFFFF color2 FFFFFF color3 FFFFFF color4 FFFFFF color5 FFFFFF color6 FFFFFF color7 333333 TEXT #Leipzig ${execi 300 curl -s "http://weather.yahooapis.com/forecastrss?w=671072&u=c" -o ~/.cache/weather.xml}${font Open Sans Light:size=15}${execi 300 grep "yweather:location" ~/.cache/weather.xml | grep -o "city=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*"} #Temp ${font Open Sans Light:size=40}${alignr}${execi 300 grep "yweather:condition" ~/.cache/weather.xml | grep -o "temp=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*"}°${font}${voffset -35} #Regenwkt ${execi 300 cp -f ~/.conky-google-now/$(grep "yweather:condition" ~/.cache/weather.xml | grep -o "code=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*").png ~/.cache/weather.png}${image ~/.cache/weather.png -p 0,45 -s 60x60} #Bild dazu ${image ~/.conky-google-now/humidity.png -p 0,115 -s 15x15}${goto 35}${execi 300 grep "yweather:atmosphere" ~/.cache/weather.xml | grep -o "humidity=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*"}%${voffset 15} #Tage ${goto 18}${execi 300 grep "yweather:forecast" ~/.cache/weather.xml | grep -o "day=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*" | awk 'NR==1' | tr '[a-z]' '[A-Z]'}${goto 88}${execi 300 grep "yweather:forecast" ~/.cache/weather.xml | grep -o "day=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*" | awk 'NR==2' | tr '[a-z]' '[A-Z]'}${goto 158}${execi 300 grep "yweather:forecast" ~/.cache/weather.xml | grep -o "day=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*" | awk 'NR==3' | tr '[a-z]' '[A-Z]'}${goto 228}${execi 300 grep "yweather:forecast" ~/.cache/weather.xml | grep -o "day=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*" | awk 'NR==4' | tr '[a-z]' '[A-Z]'}${goto 298}${execi 300 grep "yweather:forecast" ~/.cache/weather.xml |} #Bilder ${execi 300 cp -f ~/.conky-google-now/$(grep "yweather:forecast" ~/.cache/weather.xml | grep -o "code=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*" | awk 'NR==1').png ~/.cache/weather-1.png}${image ~/.cache/weather-1.png -p 0,170 -s 30x30}${execi 300 cp -f ~/.conky-google-now/$(grep "yweather:forecast" ~/.cache/weather.xml | grep -o "code=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*" | awk 'NR==2').png ~/.cache/weather-2.png}${image ~/.cache/weather-2.png -p 70,170 -s 30x30}${execi 300 cp -f ~/.conky-google-now/$(grep "yweather:forecast" ~/.cache/weather.xml | grep -o "code=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*" | awk 'NR==3').png ~/.cache/weather-3.png}${image ~/.cache/weather-3.png -p 140,170 -s 30x30}${execi 300 cp -f ~/.conky-google-now/$(grep "yweather:forecast" ~/.cache/weather.xml | grep -o "code=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*" | awk 'NR==4').png ~/.cache/weather-4.png}${image ~/.cache/weather-4.png -p 210,170 -s 30x30}${voffset 20}${voffset 20} #Höchsttemp ${goto 20}${execi 300 grep "yweather:forecast" ~/.cache/weather.xml | grep -o "high=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*" | awk 'NR==1'}°${goto 90}${execi 300 grep "yweather:forecast" ~/.cache/weather.xml | grep -o "high=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*" | awk 'NR==2'}°${goto 160}${execi 300 grep "yweather:forecast" ~/.cache/weather.xml | grep -o "high=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*" | awk 'NR==3'}°${goto 230}${execi 300 grep "yweather:forecast" ~/.cache/weather.xml | grep -o "high=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*" | awk 'NR==4'}° #tiefsttemp ${goto 20}${execi 300 grep "yweather:forecast" ~/.cache/weather.xml | grep -o "low=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*" | awk 'NR==1'}°${goto 90}${execi 300 grep "yweather:forecast" ~/.cache/weather.xml | grep -o "low=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*" | awk 'NR==2'}°${goto 160}${execi 300 grep "yweather:forecast" ~/.cache/weather.xml | grep -o "low=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*" | awk 'NR==3'}°${goto 230}${execi 300 grep "yweather:forecast" ~/.cache/weather.xml | grep -o "low=\"[^\"]*\"" | grep -o "\"[^\"]*\"" | grep -o "[^\"]*" | awk 'NR==4'}° ${color7}${hr}${color} ${execpi 300 gcalcli --conky agenda --nocolor --calendar "UaK" --calendar "xxx@gmx.de" --calendar "Lernklinik + Labortermine" --calendar "Geburtstage" --military}
Nun meine Fragen: 1) ich würde gerne den letzten Tag beim Wetter löschen und das conky so schmaler machen. (Hier also Freitag weg) Ich habe also alle Zeilen, die zum 5.Tag gehören rausgelöscht, aber das Conky bleibt trotzdem im gleichen Format (siehe Vergleich Bild 1 und Bild2). Wie bekomme ich das hin, dass alles nach rechts rutscht? Ich finde nichts, was den Abstand hält.
2. Die Agenda funktioniert ganz gut, nur ist die Formatierung nicht so toll. Es wäre schön, wenn die Zeiten untereinander stehen und nicht, verschieden weit eingerückt. Dazu jemand eine Idee?
LG Eric