1
0
mirror of https://github.com/Llewellynvdm/conky.git synced 2024-09-30 14:09:13 +00:00
Commit Graph

816 Commits

Author SHA1 Message Date
Nikolas Garofil
86b91db305 Bugfix: compilation without X11 broke after latest patches 2009-04-13 14:42:31 +02:00
Brenden Matthews
506f6ecc3b Special default & gauge fixes. 2009-04-09 20:10:08 -06:00
Brenden Matthews
38ee788da4 Added default_bar/graph/gauge_size config options (thanks wire64 for the idea) 2009-04-09 16:00:40 -06:00
Or Cohen
b6e691e8ac Minor fix for fs_used_perc, fs_free and fs_free_perc 2009-04-09 15:34:12 -06:00
Brenden Matthews
ea34b2c5e5 Fix xmms2 related compilation error? 2009-04-09 15:33:50 -06:00
Phil Sutter
7001e95186 be consistent when parsing args of cpu objects
The inconsistent naming of the cpu parameter in the docs led me to this,
so I also simplified parsing by introducing the macro SCAN_CPU(). Note
that this introduces a syntactical change to the config: the cpuN
argument now has to be passed at first position to $cpugraph.
2009-04-04 01:25:33 +02:00
Nikos Ntarmos
f91faa64b8 Add X11 display argument/conf entry (FR #2474243)
Signed-off-by: Nikos Ntarmos <ntarmos@cs.uoi.gr>
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-04-01 16:46:16 -06:00
Brenden Matthews
a301b24a8e Fix compile error. 2009-03-29 23:35:42 -06:00
Brenden Matthews
f05829ad9a Update copyright stuff, fix conky.conf weirdness. 2009-03-29 22:55:51 -06:00
Brenden Matthews
0d4f9499eb Fixed bug in template stuff. 2009-03-29 20:27:38 -06:00
Nikos Ntarmos
99a496b3ea Adding if_up support for FreeBSD.
Moved interface_up(...) from linux.{c.h} to common.{c,h} and taught it
to check for ENXIO as well to make it work on FreeBSD.

Signed-off-by: Nikos Ntarmos <ntarmos@cs.uoi.gr>
2009-03-29 01:25:57 +01:00
Nikos Ntarmos
50bac84006 Bringing FreeBSD up to date with latest commits
Several things were broken after the switch to 1.7-rc branches. This
diff fixes all compilations issues and updates some functions that were
left empty previously.

Signed-off-by: Nikos Ntarmos <ntarmos@cs.uoi.gr>
2009-03-29 01:25:51 +01:00
Nikos Ntarmos
15bd2ca5ec sysfs is a Linux-only feature.
Moving sysfs-related functions and defs out of common.h and into
linux.h, as sysfs exists only on Linux, and updating openbsd.c,
netbsd.c, and freebsd.c accordingly.

Signed-off-by: Nikos Ntarmos <ntarmos@cs.uoi.gr>
2009-03-29 01:25:48 +01:00
Nikos Ntarmos
b3a91362de Extra includes to fix compiling on FreeBSD
Signed-off-by: Nikos Ntarmos <ntarmos@cs.uoi.gr>
2009-03-29 01:25:43 +01:00
Nikos Ntarmos
b1da4bfdaa Fix a typo and teach linux code to use data
Typo: __LINUX__ was used in a conditional code block, while the rest of
      the code uses __linux__

data: free_text_objects(...) #define's 'data' to be 'obj->data' to make
	  the code more compact. The linux-specific parts of the code still
	  used obj->data, which should expand to obj->obj->data, which is
	  wrong.

Signed-off-by: Nikos Ntarmos <ntarmos@cs.uoi.gr>
2009-03-29 01:25:33 +01:00
Phil Sutter
2c3d57d841 add eval object, evaluating it's args
This object makes use of the possibility to escape dollar signs in TEXT.
Take the following example in the conkyrc:
| $${downspeed ${gw_iface}}
will be evaluated to (assuming the gw_iface is eth0):
| ${downspeed eth0}
and finally interpreted to print the gateway interface's downspeed rate.
2009-03-24 01:25:13 +01:00
Phil Sutter
12a40fd0a9 fix dollar escape in TEXT
The idea found in the code is any double dollar ($$) is being treated as
explicit dollar sign ($) instead of the start of a text object
reference. Due to missing update of the 's' variable, when creating a
text object for the text following the second dollar sign, the later was
prepended, leading to a double dollar in the output.
2009-03-24 00:40:22 +01:00
Phil Sutter
363bed34ac fix temporary printing of "(null)" for mpd vars
To minimise the chance of printing variables in an undefined state, call
free() as late as possible (i.e., right before strdup()'ing the new
value).
2009-03-23 23:46:10 +01:00
Brenden Matthews
4c77eed1c3 Couple minor fixes.
Make X11_initialise() work as it should, clarified IBM/Lenovo aka smapi
support in configure script.
2009-03-19 13:42:21 -06:00
Brenden Matthews
d399a128c9 Make print_config() stuff match configure. 2009-03-18 00:29:01 -06:00
Nikolas Garofil
37c460ed05 Fix: make sure compiling without X11 works 2009-03-17 18:36:46 +01:00
Brenden Matthews
293f6ad7e2 Fix possible mem leak with net stats. 2009-03-16 15:56:37 -06:00
Nikolas Garofil
2d524ce450 Merge branch 'master' of git.omp.am:/home/omp/git/conky 2009-03-16 21:21:11 +01:00
Nikolas Garofil
a074cb972a No limits for environment variables
Use dynamic allocated memory for skey and svalue,
allocate the length of value so that there are no limits,
but don't use the %a gnu extension to maintain compatibility
2009-03-16 21:14:22 +01:00
Brenden Matthews
613df97a6c Fix wacky net speed values on startup. 2009-03-16 14:14:18 -06:00
Brenden Matthews
c5e8f97619 Make gauge stuff look a little less funny. 2009-03-16 13:40:22 -06:00
Brenden Matthews
41b62122f5 Unbreak alias stuff.
It was broken by commit 98c64d8b3e, I did
a lowsy job of checking the patch over.
2009-03-16 13:22:22 -06:00
aner
98c64d8b3e I added Gagues to monitor variables
Signed-off-by: Brenden Matthews <brenden@rty.ca>
2009-03-15 19:36:11 -06:00
Nikos Ntarmos
e275b05242 Disk i/o support on FreeBSD patch.
Patch sf.net id #2657227 (thanks Nikos).
2009-03-15 19:11:49 -06:00
Brenden Matthews
513752626e Fix compilation errors.
I hope I didn't break the alias stuff.
2009-03-15 18:35:45 -06:00
Nikolas Garofil
8bcc287958 fix problems with negative numbers (sf.net id #2644593) (thanks Zhoushen Huang) 2009-03-15 17:09:35 +01:00
Nikolas Garofil
9c0f04bc10 bugfix: segfault when nothing x11-related is mentioned before TEXT 2009-03-15 01:17:32 +01:00
Nikolas Garofil
d1baa243a8 Added alias configfile setting
This patch is written by a anonymous author, see patch on sf.net
id #2663691 . I changed it a bit so that it can't overwrite
existing environment variables and updated the docs and syntaxfiles
2009-03-07 15:12:09 +01:00
Phil Sutter
72e217fae2 fix padding of $processes
Padding to 4 digits allows for max 9999 processes, which should really
be more than enough for systems running conky. ;)
2009-03-01 21:12:16 +01:00
Phil Sutter
e6a9c02d11 fix padding in temp_print 2009-03-01 21:03:49 +01:00
Phil Sutter
ed42437dfc introduce percent_print() for printing percentages 2009-03-01 20:53:47 +01:00
Phil Sutter
44c5a10e04 rewrite human_readable() to minimise padding
Also fix spaced_print(): when given a width of e.g. 3, output at least 3
characters, not 2 as it was before.
2009-03-01 20:24:22 +01:00
Nikolas Garofil
09ac943a3a if_updatenr added 2009-03-01 15:10:01 +01:00
Phil Sutter
a9a59e5d28 move the custom defined memrchr to the right place
And make it static, as tailhead.c is the only user of it.
2009-02-25 00:23:56 +01:00
Phil Sutter
745eec145f fix 966a05a984 2009-02-23 23:28:12 +01:00
Phil Sutter
64af164666 add help text for --print-config option
While here, fix also -C for builds with --disable-x11.
2009-02-22 19:05:53 +01:00
Phil Sutter
e3ed9c62fb whitespace cleanup 2009-02-22 19:05:52 +01:00
Phil Sutter
2c44e6dccf remove x11 dependency of fonts
Instead, we just ignore them. Less errors in output, little less
ifdef's.
2009-02-22 19:04:42 +01:00
Phil Sutter
e28f79a133 split off specials from conky.c
As a side effect, font and colour specific stuff got outsourced, too.
This is because the apropriate functions are used by conky.c as well as
specials.c, so they should be kept on their own.

In the long term I hope for positive impact on the X11 integration mess.
(Take e.g. the mass of X11 ifdefs cluttering conky.c.) Though this
commit contains no optimisations in this direction, just plain
outsourcing, to ensure minimised (intended: none) changes to conky's
interface behaviour.
2009-02-22 19:04:33 +01:00
Phil Sutter
3cd87aadf8 fix for building with --disable-x11 2009-02-22 03:08:28 +01:00
Phil Sutter
90a3e8de80 merge tail and head into a single source file
This allows having the same init-function for both objects. Code size
could be further reduced, as the print-functions share some code, too.
2009-02-22 03:00:35 +01:00
Phil Sutter
20809f3198 put tail and head code into separate files
In fact these two objects share a lot of code, so the bigger plan is to
merge them into a single file to share equal code.

This should not change anything to the code flow, besides making conky
startup a bit more robust due to less use of CRIT_ERR.
2009-02-22 03:00:26 +01:00
Phil Sutter
77c59b260d merge ibm-acpi and smapi together
Well, not really. I don't dare putting it all together into a single
source file, as that would just not make sense. Instead, this patch
eliminates the --enable-smapi configure option and all related checks,
replacing them with the equivalents from --enable-ibm.
2009-02-22 02:58:42 +01:00
Phil Sutter
d500f1005a outsource ibm-acpi stuff into it's own source file
Despite this is actually not much code and could stay inside linux.c as
well, this makes sense as I want to combine smapi and ibm-acpi
functionality. Virtually every user of a notebook made by IBM/Lenovo
will want both, so this should be a feature not a bug.

Besides making the ibm-acpi objects being built optionally, this should
not change anything to the code flow.
2009-02-22 02:58:29 +01:00
Phil Sutter
4161f90c6f rewrite linux diskio code
Instead of using a hardcoded maximum number of slots for
stats of different disks, use a linked list. Also since the algorithm to
update each device's counters is the same for updating the totals, share
equal code, which in my eyes not only saves a bunch of LoC, but also
drastically increases readability.
2009-02-22 02:57:11 +01:00