SEARCH

Enter your search query in the box above ^, or use the forum search tool.

You are not logged in.

#1 Re: Tips, Tricks & Scripts » weather in conky (LUA scripts) updated 12/26/13! » 2012-03-09 04:41:56

OK I fixed that username error and the conky weather script works!!!!!!!!!!!!! smile

now I finally got everything working. I started over wiht a new default conkyrc file and it works. I just need to get my formatting all done again.

thanks everyone!

#2 Re: Tips, Tricks & Scripts » weather in conky (LUA scripts) updated 12/26/13! » 2012-03-09 04:26:51

mrpeachy wrote:

@setherd

one question that needs to be answered, have you tried and been able to run any other lua scripts through conky?

I initially though no lua scripts would run but I downloaded the conky_colors files and installed them and their lua scripts work.

I thought I would start from scratch because that other thread with my same problem said he downloaded everything new and started over and it worked.
So I downloaded the latest v9000 files from the dropbox link in the first post of the thread.
I extracted them and tried to run the conky_weather script via the following

conky -c ~/v9000/conky_weather

eth@icarus:~$ conky -c ~/v9000/conky_weather
Conky: llua_load: /home/seth/v9000/v9000.lua:8: attempt to concatenate local 'username' (a nil value)
Conky: desktop window (160015d) is subwindow of root window (14c)
Conky: window type - normal
Conky: drawing to created window (0x2c00002)
Conky: drawing to double buffer
Conky: llua_do_call: function conky_weather execution failed: attempt to call a nil value
Conky: llua_do_call: function conky_weather execution failed: attempt to call a nil value

EDIT.................see next post

#3 Re: Tips, Tricks & Scripts » weather in conky (LUA scripts) updated 12/26/13! » 2012-03-08 04:47:11

mrpeachy wrote:

i wonder if it is the global function commands

try this

in the template change

_G.weather_script = function()--#### DO NOT EDIT THIS LINE ##############

to

function weather_script()--#### DO NOT EDIT THIS LINE ##############

and in v9000.lua, line 972 make it this

if processall==0 or testing==1 then
weather_script()
end

made the changes. here is what I get

seth@icarus:~$ conky
Conky: llua_load: /home/seth/v9000/v9000.lua:973: '=' expected near 'local'
Conky: forked to background, pid is 17878
seth@icarus:~$ 
Conky: desktop window (160012f) is subwindow of root window (14c)
Conky: window type - normal
Conky: drawing to created window (0x3000002)
Conky: drawing to double buffer
Conky: llua_do_call: function conky_weather execution failed: attempt to call a nil value
Conky: llua_do_call: function conky_weather execution failed: attempt to call a nil value

my v9000.lua must be different because line 972 was not where I found what needed to be replaced.

#4 Re: Tips, Tricks & Scripts » weather in conky (LUA scripts) updated 12/26/13! » 2012-03-08 04:39:30

Do these exist?

/usr/lib/libgobject-2.0.so.0
/usr/lib/libgmodule-2.0.so.0
/usr/lib/libgthread-2.0.so.0


I don't have them sad at least not there.

#5 Re: Tips, Tricks & Scripts » weather in conky (LUA scripts) updated 12/26/13! » 2012-03-07 04:37:45

I'm following that other thread as well.
could someone trying running a lua script from the command line?

here is what happens to me.

seth@icarus:~/v9000$ lua  v9000.lua
[LuaGnome] Can't load dynamic library /usr/lib/libgobject-2.0.so.0
[LuaGnome] Can't load dynamic library /usr/lib/libgmodule-2.0.so.0
[LuaGnome] Can't load dynamic library /usr/lib/libgthread-2.0.so.0
[LuaGnome] symbol g_assertion_message not found in dynamic library.
[LuaGnome] symbol g_boxed_type_register_static not found in dynamic library.
[LuaGnome] symbol g_enum_get_value not found in dynamic library.
[LuaGnome] symbol g_flags_get_first_value not found in dynamic library.
[LuaGnome] symbol g_free not found in dynamic library.
[LuaGnome] symbol g_malloc not found in dynamic library.
[LuaGnome] symbol g_strdup not found in dynamic library.
[LuaGnome] symbol g_mem_gc_friendly not found in dynamic library.
[LuaGnome] symbol g_mem_profile not found in dynamic library.
[LuaGnome] symbol g_mem_set_vtable not found in dynamic library.
[LuaGnome] symbol g_object_is_floating not found in dynamic library.
[LuaGnome] symbol g_object_ref_sink not found in dynamic library.
[LuaGnome] symbol g_realloc not found in dynamic library.
[LuaGnome] symbol g_slice_alloc not found in dynamic library.
[LuaGnome] symbol g_slice_alloc0 not found in dynamic library.
[LuaGnome] symbol g_slice_free1 not found in dynamic library.
[LuaGnome] symbol g_slice_set_config not found in dynamic library.
[LuaGnome] symbol g_type_check_value not found in dynamic library.
[LuaGnome] symbol g_type_class_peek not found in dynamic library.
[LuaGnome] symbol g_type_class_ref not found in dynamic library.
[LuaGnome] symbol g_type_class_unref not found in dynamic library.
[LuaGnome] symbol g_type_from_name not found in dynamic library.
[LuaGnome] symbol g_type_fundamental not found in dynamic library.
[LuaGnome] symbol g_type_init not found in dynamic library.
[LuaGnome] symbol g_type_interface_peek not found in dynamic library.
[LuaGnome] symbol g_type_interfaces not found in dynamic library.
[LuaGnome] symbol g_type_is_a not found in dynamic library.
[LuaGnome] symbol g_type_name not found in dynamic library.
[LuaGnome] symbol g_type_parent not found in dynamic library.
[LuaGnome] symbol g_value_init not found in dynamic library.
[LuaGnome] symbol g_value_unset not found in dynamic library.
[LuaGnome] symbol g_log_set_default_handler not found in dynamic library.
[LuaGnome] symbol glib_mem_profiler_table not found in dynamic library.
[LuaGnome] ERROR - an unavailable function was called.

just wondering what others get.

#6 Re: Tips, Tricks & Scripts » weather in conky (LUA scripts) updated 12/26/13! » 2012-03-06 22:30:53

Sector11 wrote:
setherd wrote:

new here and having a problem with my lua setup.
i was running linux mint 12 and it was fine. I switched to lubuntu.
now lua wont work.

Could you post:

  • the conky file

  • the LUA script &

  • the template if you use one

conky

####
## continuing the work strted ny grae
##

####
## begin setup config
#  general startup settings

background yes
update_interval 2.0
text_buffer_size 640
total_run_times 0

## screen setup:
#  placement, sizing, font and color info

alignment top_right
gap_x 34 
gap_y 10
minimum_size 220 800
maximum_width 220
own_window yes
own_window_hints below,skip_pager,skip_taskbar,undecorated,sticky
# transparency:
own_window_argb_visual yes
own_window_argb_value 64
# font defaults:
use_xft yes
xftfont UbuntuSans:size=8
xftalpha 0.1
override_utf8_locale yes

## NOTE: Other fonts can be called up during the TEXT formatting
#  these fonts are found through the normal path, or ~/.fonts
#  OpenLogos

## images, buffering, shading
imlib_cache_size 0
double_buffer yes
draw_shades yes
default_shade_color 080808

## misc text formatting
short_units yes
pad_percents 0
border_inner_margin 4
uppercase no
use_spacer right

## outlines and borders
draw_outline no
draw_borders no
draw_graph_borders yes
border_width 1

## stdout/console printing
out_to_ncurses no
out_to_console no

## process settings
top_name_width 12
no_buffers yes

## Colors
color0 White
color1 Gray
color2 Red
color3 Salmon
color4 Yellow
color5 LightSeaGreen
color6 Green
color7 DarkGreen
color8 DarkCyan
color9 Blue

#### end config

#### Lua scripting
## call external lua scripts here
#  MrPeachy v9000 weather scripts
lua_load ~/v9000/v9000.lua
lua_draw_hook_pre weather
#lua_load ~/v9000/weather_script.lua

#### Begin display information
## everything below 'TEXT' is drawn on screen

TEXT
####
#  Logo and time
####
${voffset 8}${font OpenLogos:size=42}${color7}u${font UbuntuTitleBold:18} ${voffset -48}${pre_exec cat /etc/*release | grep 'RELEASE' | awk -F'=' '{print $2}'}${font}${goto 115}${voffset -4}${font RadioSpace:size=20}${color6}${if_match ${time %l}<=9}${alignc 7}${time %l:%M%p}${else}${if_match ${time %l}>=10}${alignc -1}${time %l:%M%p}${endif}${endif}${font}
${goto 115}${font StyleBats:size=10}${color4}q${font DroidSans:size=8}${color1}${offset 5}Uptime: ${font DroidSans:size=8}${uptime_short}${font}
####
#  Calendar
####
${font}
${voffset 2}${color6}${font}${alignc}CALENDAR${font}
${color7}${voffset -8}${hr 1}${font}
${voffset 4}${font Ubuntu:size=8}${color6}${alignc 60}${time %A}${font}
${voffset 0}${font Ubuntu:bold:size=18}${if_match ${time %e}<=9}${color6}${alignc 65}${time %e}${font}${else}${if_match ${time %e}>=10}${color4}${alignc 60}${time %e}${endif}${endif}${font}
${voffset -2}${font Ubuntu:size=7.55}${color6}${alignc 60}${time %B}${font}
${voffset 0}${font Ubuntu:size=7.6}${color6}${alignc 60}${time %Y}${font}
${voffset -73}${font CutOutsFor3DFX:size=62}${color5}${alignc 96}2${font}
${voffset -65}${offset 85}${font DroidSans:size=8}${color6}${execpi 60 VinDSL_Cal_9=`date +%-d`; cal -h | sed -e 's/\r//g' -e 's/^/ /g' -e '1d' -e 's/\<'"$VinDSL_Cal_9"'\>/${color4}&${color6}/'}
####
#  CPU Load
####
${voffset -2}${goto 90}${color6}${cpugraph cpu1 20,100}${font}
${voffset -22}${font StyleBats:size=8}${color1}k${font DroidSansFallback:size=8}${color6}${offset 4}CPU${offset 6}${color3}${font DroidSans:size=8}${cpu cpu1}%
CPU TEMP:${GOTO 70}${execi 10 sensors | grep -n 'temp1' | sed -n 2p | awk -F'+' '{print $2}' | awk -F'.' '{print $1}'} ºC
${GOTO 120}HDD TEMP: ${hddtemp /dev/sda}ºC
####
#  TOP processes
####
${color6}${voffset 2}${alignc}TOP${font}
${color7}${voffset -8}${hr 1}${font}
${color8}${top_mem pid 1}${goto 60}${top_mem name 1}${alignr}${top_mem mem 1}%${font}
${color8}${top_mem pid 2}${goto 60}${top_mem name 2}${alignr}${top_mem mem 2}%${font}
${color8}${top_mem pid 3}${goto 60}${top_mem name 3}${alignr}${top_mem mem 3}%${font}
${color8}${top_mem pid 4}${goto 60}${top_mem name 4}${alignr}${top_mem mem 4}%${font}
${color8}${top_mem pid 5}${goto 60}${top_mem name 5}${alignr}${top_mem mem 5}%

####
#  Network
####
${color6}${font}${alignc}NETWORK${font}
${color7}${voffset -8}${hr 1}${font}
${color6}Net ID:  ${wireless_essid eth1}${alignr}Signal Strength: ${wireless_link_qual_perc eth1}%${font}
${color5}Down: ${downspeed eth1}${color2}${alignr}${color3}Up:${upspeed eth1} ${font}
${color6}${downspeedgraph eth1 16,64}${alignr}${color4}${upspeedgraph eth1 16,64}
${voffset 0}${font PizzaDudeBullets:size=9.5}${color6}a${font DroidSans:size=8.65}${color3}${offset 0}Public${offset 0}IP${goto 100}${font DroidSansFallback:size=8.5}WAN${alignr}${font DroidSans:size=8}${execi 1800 wget -q -O - checkip.dyndns.org | sed -e 's/[^[:digit:]\|.]//g'}
${font PizzaDudeBullets:size=9.5}${color6}a${font DroidSans:size=8.65}${color3} Local IP: ${addr eth1}
#  Weather
####
${font}
${color6}${voffset -2}${font}${alignc}WEATHER${font}
${color7}${voffset -2}${hr 1}${font}

the forums doesn;t like my lua scripts so I am using pastebin.
weather_script lua
http://pastebin.com/wPEmPgvM

v9000 lua
http://pastebin.com/56BC4MqD

I somehow think lua is broken or I am missing some dependency but I don't know what

thanks,
Seth

#7 Re: Tips, Tricks & Scripts » weather in conky (LUA scripts) updated 12/26/13! » 2012-03-05 19:35:56

new here and having a problem with my lua setup.
i was running linux mint 12 and it was fine. I switched to lubuntu.
now lua wont work.

 
seth@icarus:~$ conky 
Conky: forked to background, pid is 3099
seth@icarus:~$ 
Conky: desktop window (140012f) is subwindow of root window (14c)
Conky: window type - normal
Conky: drawing to created window (0x2e00002)
Conky: drawing to double buffer
gathering data with curl
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 68530  100 68530    0     0   124k      0 --:--:-- --:--:-- --:--:--  207k
you have no weather alerts
processing complete
Conky: llua_do_call: function conky_weather execution failed: /home/seth/v9000/v9000.lua:921: attempt to call field '?' (a nil value)
Conky: llua_do_call: function conky_weather execution failed: /home/seth/v9000/v9000.lua:921: attempt to call field '?' (a nil value)

again this all worked fine before.
I just can't figure out what's up with lua.

here's my conky -v output

seth@icarus:~$ conky -v
Conky 1.8.1 compiled Fri Dec 16 17:59:40 UTC 2011 for Linux 2.6.24-29-server (i686)

Compiled in features:

System config file: /etc/conky/conky.conf
Package library path: /usr/lib/conky

 X11:
  * Xdamage extension
  * XDBE (double buffer extension)
  * Xft
  * ARGB visual

 Music detection:
  * Audacious
  * MPD
  * MOC
  * XMMS2

 General:
  * math
  * hddtemp
  * portmon
  * Curl
  * RSS
  * Weather (METAR)
  * Weather (XOAP)
  * wireless
  * support for IBM/Lenovo notebooks
  * nvidia
  * eve-online
  * config-output
  * Imlib2
  * apcupsd
  * iostats
  * ncurses
  * Lua

  Lua bindings:
   * Cairo
   * Imlib2
seth@icarus:~$ 

any help is appreciated.

Board footer

Powered by FluxBB

Copyright © 2012 CrunchBang Linux.
Proudly powered by Debian. Hosted by Linode.
Debian is a registered trademark of Software in the Public Interest, Inc.

Debian Logo