1

I'm trying to make some dzen2 stuff, but i have some hard time on one point. I want to eval color variable between conky and dzen2.

Something like that:

Colors :

#!/bin/zsh

#################################
## Colors for Dzen2 status bar ##
#################################

##
## TEST Colors
##
COLOR_TEST='#000000'

Conkyrc :

#################################
## Conky for Dzen2 Status Bar  ##
#################################

background no
out_to_console yes
out_to_x no
override_utf8_locale yes
update_interval 1
total_run_times 0

TEXT
##
##  TEST
##
  ^fg($$COLOR_TEST)

Script:

#!/bin/zsh

. ./colors
conky -c conkyrc | dzen2 -p

I tried eval/echo on conky, but nothing sucessfull. If somebody have an idea, it will be really nice.

Thanks anyway

Have a good day


EDIT:

If we can't find a solution about the main question, what's the best idea?

  • Lua/Conky (I think it's not bad)
  • Shell/Dzen2 (Performance are not amazing last time i tried that)
  • A full program in C++ (A little overkill, and conky is generic)
Mathieu Van Nevel
  • 1,428
  • 1
  • 10
  • 26

3 Answers3

1

i dont know about dzen, and i dont use zsh, but i use lemonbar, and i use this, to pass some special UTF-8 chars, to my lemonbar through conky :

${exec /bin/bash -c 'echo -en "%{T3}\\uf012%{T-}"'}

maybe this, gives you an idea, how to parse-out, variables, from inside a script.

kapad
  • 52
  • 7
1

How about to use ${execp my-dzen-help.sh getcolors }, in conky ?

#my-dzen-help.sh

getcolors(){
printf '^fg($$COLOR_TEST)'; # or what ....
}
kapad
  • 52
  • 7
  • I think you're right, but the description of execp seem to be : something which allow us to do something not possible with conky, but take a lot of resources. So that's confirm that there is no way to do it properly, but you're solution seems to be functional at least :) Thanks – Mathieu Van Nevel May 17 '16 at 20:35
  • It depends, i dont think echo some color values, will take some much proccess time. I;m using bebian8, on a P4 with 1GB ram, openbox/lxpanel/lemonbar, everything running smooth, now i'm writing here using dwb browser, i have geany editor open, no more than 170MB i need. The point with the modern desktop enviroments, is themselves ! – kapad May 17 '16 at 20:45
  • https://www.facebook.com/photo.php?fbid=979920965448668&set=pb.100002923223110.-2207520000.1463518410.&type=3&size=1360%2C768 – kapad May 17 '16 at 20:53
  • Nice :) I need to make a new full config this summer. So i'll return to xorg a little, and check dwb (firefox takes near 500MB for a classic use...). Then dzen2 and conky will be back thanks to you ^^ – Mathieu Van Nevel May 17 '16 at 21:32
0

After some thinking i come to a conclusion : create some tools like conky/dzen2 from scratch. Like this i'll have something ready for wayland and more easy to use.

So i'll try to get some time to make it, the most important part will be "dzen2" with glfw/opengl.

-

But if somebody find an answer for the original question, i'm still curious !

Mathieu Van Nevel
  • 1,428
  • 1
  • 10
  • 26