ID |
Date |
Author |
Author Email |
Category |
Subject |
Status |
Last Revision |
34
|
Fri Feb 4 10:26:38 2011 |
Stefan Ritt | stefan.ritt@psi.ch | Other | Re: Building elog on OpenBSD | Stable | |
T. Ribbrock wrote: |
Two things are required to get elog (tested with 2.8.1) to compile on OpenBSD (tested on OpenBSD 4.8):
Step 1 - Patch Makefile:
--- Makefile~ Mon Jan 24 21:38:09 2011
+++ Makefile Mon Jan 24 21:42:57 2011
@@ -50,6 +50,10 @@
RM = /usr/bin/rm -f
endif
+ifeq ($(OSTYPE),OpenBSD)
+LIBS += -lcrypto
+endif
+
ifeq ($(OSTYPE),Darwin)
OSTYPE=darwin
endif
Step 2 - Use "gmake" instead of the standard "make" to build.
|
Thanks, I added your patch to the distribution. |
36
|
Tue Aug 23 12:07:51 2011 |
Stefan Ritt | stefan.ritt@psi.ch | Script | Re: JavaScript list auto-refresh | Stable | Tue Jul 12 12:36:16 2005 by Emiliano Gabrielli |
Emiliano Gabrielli wrote: | Here is a simple piece of JS code to accomplish a smart page reload.
We don't reload if in some kind of editing mode.
You can put the code everywhere you like in the elog html page, my suggestion is to put it in Bottom Text (or Top Text):
;auto-refresh
Bottom text = [I]<script language="JavaScript">if (null==window.location.href.match('/[0-9]+$|.*(cmd|select)=.*') ) { window.setTimeout("location.reload();", 2*60*1000); now=new Date(); document.write('<br/>Last reload at '+now.getFullYear()+'/'+(now.getMonth()+1)+'/'+now.getDate()+', '+( ((h=now.getHours())<10) ? '0'+h :h)+':'+( ((m=now.getMinutes())<10) ? '0'+m :m)+':'+( ((s=now.getSeconds())<10) ? '0'+s :s)) }</script>[/I]
the timer is a product of # of minutes, #of seconds and milliseconds... 2 minutes in the above example
Revision Tue Jul 12 12:36:16 2005 wrote: |
modified regular expression in order to not activate the auto-refresh in the signle entry view
|
|
Starting with SVN revision 2422, there is a new config option
refresh = <seconds>
which lets you do the same thing. |
41
|
Mon Jan 7 16:37:21 2013 |
Stefan Ritt | stefan.ritt@psi.ch | Script | Re: Server time offset | Stable | |
Bruce Weber wrote: |
Our server runs on local time, however, we require log entries to be in UTC (-0800hrs) - is there a command to achieve this?
Your assistance will be much appreciated
Thanks
|
Have you tried
Subst <attribute> = $utcdate
Probably you need a dedicated attribute of type "datetime" and have to play with the "Date format" options. |
155
|
Fri Dec 1 16:30:46 2023 |
Stefan Ritt | Unstefan.ritt@psi.ch | Other | Re: Fixing repeating first inline_image in email | Stable | Fri Dec 1 16:31:37 2023 by Stefan Ritt |
Unfortunately you made your changes against a pretty old version of elogd.c, so I can't see which changes you made (the diffs gives 100's of changes now). If you can apply your fix against the current elogd.cxx from the bitbucket repository, I would be happy to include the fix in the distribution.
Stefan
rami khrais wrote: |
Fixing repeating first image in email (email notification) when the user submit a new log with in_line images.
|
|
9
|
Wed Jul 7 18:19:10 2004 |
Steve Jones | steve.jones@freescale.com | Script | Generic Unix elogd init script | Stable | Wed Jul 7 18:19:38 2004 by Steve Jones |
The elogd.init script that ships in the elog distribution is Linux centric.
This script is written to work in a generic Unix environment under 'sh' -
no frills! |
Attachment 1: elogd.init
|
#!/bin/sh
# description: Start elog
# elog can have multiple instances run on the same server, pointing to different logbook areas. This start
# script should be run from the root of each different elog area.
ELOGD="/_TOOLS_/dist/gnu-elog-2.5.3/sparc-sun-solaris2.8/bin/elogd"
ELOGDIR="/proj/sysadmin/ess/www/elog"
HOSTNAME=`hostname`
# Check for the config file
if [ ! -f $ELOGDIR/elogd.cfg ]; then
exit 0
fi
# See how we were called.
case "$1" in
start)
if [ -f $ELOGDIR/elogd-$HOSTNAME.pid ] ; then
pid=`cat ./elogd-$HOSTNAME.pid`
if [ -d /proc/$pid ] ; then
echo "elogd already running"
exit 1
fi
fi
####################################
# The full path *must* be specified
echo "Starting elogd: "
$ELOGD -f $ELOGDIR/elogd-$HOSTNAME.pid -c $ELOGDIR/elogd.cfg -D > /dev/null 2>&1 &
RETVAL=$?
if [ $RETVAL -eq 0 ] ; then
echo "elog started"
else
echo "Failed to start elog"
fi
echo
;;
stop)
echo ""
if [ -f $ELOGDIR/elogd-$HOSTNAME.pid ] ; then
echo "Stopping elogd: "
kill `cat $ELOGDIR/elogd-$HOSTNAME.pid`
rm -f $ELOGDIR/elogd-$HOSTNAME.pid
echo "elog stopped"
echo
else
echo "No elogd running?"
echo "Failed to start elog"
echo
fi
;;
restart|reload)
$0 stop
$0 start
;;
*)
echo "Usage: $0 {start|stop|restart}"
exit 1
esac
exit 0
|
37
|
Tue Aug 23 19:45:16 2011 |
Stuart Wilkins | swilkins@bnl.gov | Script | ELOG Mail Parser | Alpha | |
Hi!
I have attached a small script which can process an e-mail and submit this e-mail as a log entry. This is alpha at the moment but if you have suggestions or find bugs please let me know.
The easiest way to process this is to use the ".forward" file in unix. If this file contains the line:
| "/usr/bin/python /home/tardis/elogmail/process.py --log /home/tardis/elogmail/mail.log -r -u http://localhost:8080/TARDIS -a Category=email -a Type=Log"
This will pipe the incoming mail to the e-log running on the localhost with the experiment TARDIS. Attributes can be set using the "-a" switch like in the elog command line utility. To get help with all the options please run the script with the command:
python process.py -h
which will give help.
Any questions, please don't hesitate to contact me, and I will do my best to help.
Thanks again to Stefan for a great application.
Best wishes,
Stuart
|
Attachment 1: process.py.gz
|
Attachment 2: forward.gz
|
29
|
Thu Nov 27 11:43:32 2008 |
T. Ribbrock | emgaron+elog@ribbrock.org | Script | /etc/init.d/elog script for Debian-like distros | Stable | |
The attached script was used by the Debian package (which is no longer maintained) to start/stop elogd. I have changed it based on some comments in the forum (see script) to add some more functionality. As there is no mainatined elog package for Debian anymore, I'm placing it here in the hope that it might come in handy for users who want to run elog under Debian.
This script needs to be placed in /etc/init.d and expects elogd to be installed as /usr/sbin/elogd (can be changed, of course). |
Attachment 1: elog
|
#!/bin/sh
# Init script for ELOG.
# Copyright © 2003, 2005 Recai Oktaş <roktas@omu.edu.tr>
#
# Additional changes by Thomas Ribbrock <emgaron@ribbrock.org>
# - 2008-11-27: Added better reload functionality, based on suggestion and
# code from Yoshio Imai as posted in elog forum
#
# Licensed under the GNU General Public License, version 2.
# See the file `http://www.gnu.org/copyleft/gpl.txt'.
PATH=/sbin:/bin:/usr/sbin:/usr/bin
DAEMON=/usr/sbin/elogd
NAME=elogd
DESC="ELOG daemon"
test -f $DAEMON || exit 0
set -e
# Admin should be able to lock some options.
if [ -f /etc/default/elog ]; then
. /etc/default/elog
fi
# To be in the safe side, the followings should be always defined.
PIDFILE=${PIDFILE:-/var/run/$NAME.pid}
CONFFILE=${CONFFILE:-/etc/elog.conf}
# Add the options to argument list only if defined previously. Since
# some options may also be present in the conffile, we couldn't preset
# those options which would otherwise overwrite the settings in the
# conffile. Also note that, all have reasonable compiled-in defaults.
ARGS="${PIDFILE+"-f $PIDFILE"} \
${CONFFILE+"-c $CONFFILE"} \
${LOGBOOKDIR+"-d $LOGBOOKDIR"} \
${RESOURCEDIR+"-s $RESOURCEDIR"} \
${PORT+"-p $PORT"} \
${HOST+"-n $HOST"} \
${VERBOSE+"-v"}"
# Always run as a daemon.
ARGS=`echo $ARGS -D`
case "$1" in
start)
echo -n "Starting $DESC: "
start-stop-daemon --start --quiet --pidfile $PIDFILE \
--exec $DAEMON -- $ARGS 2>&1
sleep 1
if [ -f "$PIDFILE" ] && ps h `cat "$PIDFILE"` >/dev/null; then
echo "$NAME."
else
echo "$NAME failed to start; check syslog for diagnostics."
exit 1
fi
;;
stop)
echo -n "Stopping $DESC: $NAME"
start-stop-daemon --oknodo --stop --quiet --pidfile $PIDFILE \
--exec $DAEMON -- $ARGS 2>&1
echo "."
;;
reload)
# Send HUP signal to reload config file
# (Only needed if config is edited manually and not via
# webinterface)
if [ -f $PIDFILE ]; then
echo -n "$DESC to reread config file ... "
kill -HUP `cat "$PIDFILE"`
echo "done"
else
echo "No $PIDFILE found!"
fi
;;
restart|force-reload)
$0 stop
sleep 1
$0 start
if [ "$?" != "0" ]; then
exit 1
fi
;;
*)
N=/etc/init.d/$NAME
echo "Usage: $N {start|stop|restart|reload|force-reload}" >&2
exit 1
;;
esac
exit 0
# vim:ai:sts=8:sw=8:
|
33
|
Thu Feb 3 23:51:16 2011 |
T. Ribbrock | emgaron+elog@ribbrock.org | Other | Building elog on OpenBSD | Stable | |
Two things are required to get elog (tested with 2.8.1) to compile on OpenBSD (tested on OpenBSD 4.8):
Step 1 - Patch Makefile:
--- Makefile~ Mon Jan 24 21:38:09 2011
+++ Makefile Mon Jan 24 21:42:57 2011
@@ -50,6 +50,10 @@
RM = /usr/bin/rm -f
endif
+ifeq ($(OSTYPE),OpenBSD)
+LIBS += -lcrypto
+endif
+
ifeq ($(OSTYPE),Darwin)
OSTYPE=darwin
endif
Step 2 - Use "gmake" instead of the standard "make" to build.
|
44
|
Tue Jul 8 15:43:21 2014 |
TimS | timpie_s@yahoo.com | Script | Re: Custom input forms implementation | Stable | Tue Mar 19 13:18:33 2013 by Stefan Ritt |
Stefan Ritt wrote: |
Dear ELOG users,
starting with SVN revision 2328, custom input forms are implemented. This allows application specific formats for check lists etc. In our specific case we had to implement a shift check list, which was quite long. Furthermore the check list should be optimized for an iPad, which we take in the field and record various checks and readings (in our case some gas pressure gauges at the PSI particle accelerator). Since the standard ELOG interface was too inflexible, a completely hand-written form was needed. The form can be activated by the new configuration options Custom New Form, Custom Edit Form and Custom Display Form, one for a new entry, an entry to edit and and entry to display. In our case we used the same form for all three cases. This is how the shift check list looks under the Safari Browser on a PC:
And here is how it looks on the iPad:
Each section can be collapsed and expanded (blue arrows at the left), and various internal checks are made before the check list can be submitted.
Implementing such forms is however more something for the advanced user, since you have to hand-write HTML with CSS and JavaScript code. It can then however be a powerful method for check lists. Please find in the attachments the elogd.cfg configuration for that logbook and the shiftcheck.html source code file. It is a bit complicated since the page is a static page, elogd just serves it from the file. This requires all the dynamic functions to be implemented inside the HTML file with JavaScript. To display an entry for example, the JavaScript loads the raw data with the "?cmd=Download" command and the populates the form fields. The collapsing and expanding is done by using CSS properties. The integrated style sheet was optimized for the rendering on an iPad. Rather large fonts were chosen so that the items can be checked easily with your finger tips. Various parameters are sent between the browser and the elogd program via hidden fields and cookies. So only something for experts! But if you go through the effort and hand-write the form, it can be very handy. Note that you have to upgrade to SVN revision 2328 for the three new options.
|
That's awesome!! Didn't know ELOG was still being developed!! I was looking for this ...been trying this version now with
supplied example but there's files missing which are being referenced from the html file.
Anyway it would be nice to know a little more on how to use this and how it incorporates into ELOG.
Is some more work being done on this version ?
Thankx heaps for this great enhancement although now it's still needs a lot of figuring out on how to do this.
|
3
|
Fri Jun 6 18:32:14 2003 |
Tomas Rudolf | tomas@mba.be | | ELOG Syntax highlighting in UltraEdit | | |
Maybe some of you use UltraEdit code editor (http://www.ultraedit.com/) to
create/modify your ELOGD.CFG files.
Well, in that case we hope you find useful the attached syntax highlighting
configuration file.
To intstall this file into UltraEdit :
MENU --> ADVANCED --> CONFIGURATION --> SYNTAX HIGHLIGHTING tab --> OPEN
WORDLIST
You can also download the latest version from our website :
http://public.mba.be/demo/elog/u-edit-elog-syntax.txt |
Attachment 1: u-edit-elog-syntax.txt
|
/L7"Elog" Line Comment = ; Block Comment On = /* Block Comment Off = */ String Chars = "' File Extensions = cfg
/Delimiters = ~!@%^&*()-+=|\/{}[]:;"'<> , .?
/C1"Elog Global functions"
** Logbook tabs
** SMTP host =
** Admin Password
** Admin user =
** Selection page
** Self register
** URL=
** Welcome Title
/C2"Elog Syntax"
** Attributes
** Back
** Bottom text
** Comment
** Config
** Copy to
** CSS
** Data dir
** Date format
** Delete
** Display Email recipients
** Display mode
** Download
** Edit
** edit
** Email
** Email All
** Email message body
** Email notification
** Entries per page
** Filtered browsing
** Find
** Find Menu commands
** Fixed Attributes Edit
** Fixed Attributes Reply
** full
** Group
** Guest find menu commands
** Guest menu commands
** Help
** Help URL
** IOptions
** Icon comment
** Language
** Last day
** Locked Attributes
** Logbook dir
** Logbook Tabs
** Logbook tabs
** Logfile
** Login
** Logout
** Main tab
** Menu commands
** Message Height
** Message Width
** MOptions
** Move to
** New
** Number Attachments
** on
** Options
** Page Title
** Password file =
** port
** Preset
** Quick filter
** Remove on reply
** Reply
** Required Attributes
** Resource dir
** Restrict edit
** Reverse sort
** ROptions
** Search all logbooks
** Self register
** SMTP host
** Search all logbooks
** Subdir
** Submit Page
** Subst
** Subst on reply subject
** Suppress default
** Suppress Email on edit
** Suppress Email to users
** Tab cellpadding
** Theme
** Thread display
** Thread Icon
** threaded
** Use Email From
** Use Email Subject
/C3"Elog MBA reserved attributes"
** %a %d %m %y
** %%Action
** %%BookName
** %%MessageID
** %%User
AsTo
Author
By
Categorie
Category
Contract
DateUp
DosL
DosR
Dossier
** Email AdressesEmail
** Email AsTo
** Email Partner
Email1
FollowUp
Forms
Inotifie
Inotifie
Notify
Notify
Origin
Partner
Priorite
Priority
Qualify
ShellLogFile
ShellOnSubmit0
ShellOnSubmit1
ShellParam0
ShellParam1
ShellParamVerboseType
Status
Type
|