From: Johannes Schindelin Date: Sun, 05 Mar 2006 14:11:29 GMT Subject: Re: [PATCH] git-blame: Make the output human readable Message-ID: In-Reply-To: <7vbqwlgkhk.fsf@assigned-by-dhcp.cox.net> Hi, On Sun, 5 Mar 2006, Junio C Hamano wrote: > Fredrik Kuivinen writes: > > > +char* format_time(unsigned long time, const char* tz) > > +{ > > + static char time_buf[128]; > > + time_t t = time; > > + > > + strftime(time_buf, sizeof(time_buf), "%Y-%m-%d %H:%M:%S ", gmtime(&t)); > > + strcat(time_buf, tz); > > + return time_buf; > > +} > > I think this shows GMT with time offset, which is compatible > with the human readable time Johannes did to git-annotate. I do > not know what timezone CVS annotate shows its dates offhand (it > seems to only show dates). Johannes, is this an attempt to > match what CVS does? CVS only shows the date, something like strftime("%Y-%b-%d", gmtime($timestamp)); > I am wondering if we want to be in line with the date formatting > convention used for our commits and tags, that is, to show local > timestamp with timezone. The code to use would be show_date() > from date.c if we go that route. I like that approach. Sometimes imitating CVS can be overdone. Ciao, Dscho