RegisterRegister    Log inLog in    SearchSearch   

Post new topic   Reply to topic
 
View previous topic :: View next topic  
Author Message
Kybber



PostPosted: Fri Mar 24, 2006 8:04 pm    Post subject: Possible to include datestamp as a parameter/variable? Reply with quote

The command line for RO-servers ends with
Quote:
-log=port%server:port%.log

Unfortunately, RO truncates the log when it restarts, so the
previous log is deleted. I'm therefore wondering if it is
possible to insert a date and time stamp into the name of
the file so that it is not overwritten upon startup?

I suppose I could use <gc:include> to fetch a URL that
contains a datestamp, but that is a very ugly hack Wink

Other tricks to preserve the log files during restarts are also
appreciated Smile
Back to top
View user's profile Send private message
adbot



PostPosted: Thu Mar 31, 2011 3:57 am 

Omar



PostPosted: Sat Mar 25, 2006 12:37 pm    Post subject: Reply with quote

Sounds like a nice idea
Back to top
View user's profile Send private message Send e-mail MSN Messenger
Andrew
Mammoth


PostPosted: Sat Mar 25, 2006 12:50 pm    Post subject: Reply with quote

Agreed - We use to have something like this pre-beta and will put something together for this feature again soon.
Back to top
View user's profile Send private message
Kybber



PostPosted: Sat Mar 25, 2006 6:15 pm    Post subject: Reply with quote

Cool, thanks! If I may expand on the suggestion a bit:
There is a potential black hole related to getting timezones
right. Additionally, different people may have different wants
and needs for the time string format. Perhaps using the
more or less standard strftime format where you produce
e.g. 25.03.2006 with "%d.%m.%Y" would be a good idea?

For all I know, this may be rather complex to implement,
and as such will take a long time. A preliminary version of
the command/variable could allow just %s, meaning epoch.
Epoch is the same regardless of timezone, which solves that
problem easily.

Just a suggestion Smile
Back to top
View user's profile Send private message
Omar



PostPosted: Sat Mar 25, 2006 6:28 pm    Post subject: Reply with quote

I cant speak for gamecreate but personally I beleive it is an excellent suggestion and very 'do able'
Back to top
View user's profile Send private message Send e-mail MSN Messenger
Andrew
Mammoth


PostPosted: Fri Mar 31, 2006 11:14 am    Post subject: Reply with quote

This is done, ive added a <gc:date> tag.

http://doc.gamecreate.com/ManualFileLanguage

Scroll down to the end of the page for syntax information.
Back to top
View user's profile Send private message
Kybber



PostPosted: Fri Mar 31, 2006 11:33 am    Post subject: Reply with quote

Awesome! Excellent work, Andrew! I've just enabled it for
RO and it works perfectly Smile

(Guess that also explains all the fishy sql-code I observed
on the command lines in the GUI about an hour ago Wink)
Back to top
View user's profile Send private message
Andrew
Mammoth


PostPosted: Fri Mar 31, 2006 4:01 pm    Post subject: Reply with quote

Just a small note to say ive updated the documentation a bit more, and also changed the format "log" type returns.

Was d.m.Y-g.i.sa, is now Y.m.d-g.i.sa - Made it go from year->month->day so the filenames are easy to find / ordered nicely.
Back to top
View user's profile Send private message
Omar



PostPosted: Fri Mar 31, 2006 7:26 pm    Post subject: Reply with quote

nicely done!

Im sure everyone will love this new feature
Back to top
View user's profile Send private message Send e-mail MSN Messenger
Display posts from previous:   
Post new topic   Reply to topic All times are GMT + 10 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Forum powered by phpBB © 2001, 2005 phpBB Group
GameCreate Service Terms | Privacy Policy | © Copyright Mammoth Media 2001-2007
GameCreate™ is a trademark of Mammoth Media Pty Ltd. GameCreate® is a registered trademark in Australia.