Demo Discussion
Forum Config Examples Contributions Vulnerabilities
  Discussion forum about ELOG, Page 130 of 808  Not logged in ELOG logo
    icon2.gif   Re: running more then one shell command when new entries is submitted, posted by kenzo Abrahams on Wed Oct 28 11:11:27 2015 

Hi Andreas

This worked perfectly thank you.

Andreas Luedeke wrote:
As far as I know ELOG is recognising a configuration line as a comment only when it starts with a ';'.
I can assure you that ELOG does not treat the rest of the line as a comment when you use a ';' within a $shell() command: I do it a lot and it works fine. Here's a simple, generic example using the bash:

Preset Author = $shell(if [ $short_name = "Anonym" ] ;then echo $Author;else echo \"$long_name, $Author\";fi)
It adds $long_name to the Author field for non-anonymous entries.

Cheers Andreas

kenzo Abrahams wrote:

If i put the ';' into Execute the rest of the command becomes a comment thats why i was trying to use '&&' instead. If I encapulate the whole command in "" or '' then both commands are executed but the files im trying to write to gets created but no data is piped into it. When I use Execute with one command and pipe its output to a file everything works fine though.

Stefan Ritt wrote:

The command is passed to your shell, and some shells except more than one command. Most Linux shells accept commands separated by ';', which you can try yourself by entering for example: ls *.c; ls*.h

kenzo Abrahams wrote:

Hi

Im just curious is it possible to run more then one command using Execute new = <command> or will i have to run a script to run muliple commands.

I tried using '&&' to seperate more then one command but it seems that the first one only gets executed and the rest are just ignored.

Regards

Kenzo

 

 

 

 

    icon2.gif   Re: rss feed title & conditional attributes, posted by Stefan Ritt on Mon May 2 13:27:16 2005 
> When I define 2 attributes, by default and the second one has to be showed
> depending on the first one value the elog correctly handle the thing, but
> the rss feed shows an empty comma separeted field corresponding to the
> conditional attribute not filled ...

Can you send me the part of your config files with those things so that I can
reproduce it?
    icon2.gif   Re: rss feed title & conditional attributes, posted by Emiliano Gabrielli on Mon May 2 13:34:12 2005 rssbug.cfg
> > When I define 2 attributes, by default and the second one has to be showed
> > depending on the first one value the elog correctly handle the thing, but
> > the rss feed shows an empty comma separeted field corresponding to the
> > conditional attribute not filled ...
> 
> Can you send me the part of your config files with those things so that I can
> reproduce it?

it is attached
    icon2.gif   Re: rss feed title & conditional attributes, posted by Stefan Ritt on Mon May 2 14:58:27 2005 
Ok, fixed. I do however not evaluate the conditional attribute, but just remove any
empty attribute, I guess that makes more sense.
    icon14.gif   Re: rss feed title & conditional attributes, posted by Emiliano Gabrielli on Mon May 2 15:40:02 2005 
> Ok, fixed. I do however not evaluate the conditional attribute, but just remove any
> empty attribute, I guess that makes more sense.

ok, it work perfectly, tnx .. I agree with you choice of course :-)
    icon2.gif   Re: rhis logbook, posted by Stefan Ritt on Wed Jun 4 11:14:32 2003 
> I suggest to add an attributes  like  OS
> 
> MOptions OS = linux, windows2000, windowsXP¨, windows2003
> 
> to indicate on which version we are speaking

Good idea, I added a "ELOG Version" as well.
    icon12.gif   Re: rhis logbook, posted by Etienne Van Caillie on Wed Jun 4 12:57:11 2003 icons.zip
> > I suggest to add an attributes  like  OS
> > 
> > MOptions OS = linux, windows2000, windowsXP¨, windows2003
> > 
> > to indicate on which version we are speaking
> 
> Good idea, I added a "ELOG Version" as well.

I suggest MOptions - people are lazy .... :)
by the way any possibilities to have 'multiple icons' ?
    icon2.gif   Re: rhis logbook, posted by Stefan Ritt on Wed Jun 4 13:11:51 2003 
> I suggest MOptions - people are lazy .... :)

Not for the Version! I don't want to update this list on every release (:-(
Plus the list would get too long over time!

> by the way any possibilities to have 'multiple icons' ?

No, you have to use MOptions instead.
ELOG V3.1.5-3fb85fa6