[fpc-other] GIT versioning server on Raspberry Pi?

Giuliano Colla giuliano.colla at fastwebnet.it
Tue Jun 6 12:30:58 CEST 2017


Il 06/06/2017 10:40, Bo Berglund ha scritto:
> Relevant files compare fine
> except they are not the correct timestamp.

This is one of the down sides of GIT: it doesn't preserve timestamps.

As a workaround you may write a small script which will touch each file 
of the newly created repository with the time stamps of the original 
folders. Here enclosed a python script which I used for that purpose; 
you may see if it fits your needs.

After that, if you need to preserve timestamps, you may take advantage 
either of git-restore-time (which will change the timestamps to the 
commit time):

https://github.com/MestreLion/git-tools

or of the metastore utilities:

https://github.com/przemoc/metastore

which adds an additional metadata file, where original timestamps are 
stored, and used to properly set them at each commit, and to restore 
them at each checkout, pull, etc.

Hope that it helps,

Giuliano



-------------- next part --------------
A non-text attachment was scrubbed...
Name: touchdir.py
Type: text/x-python
Size: 733 bytes
Desc: not available
URL: <http://lists.freepascal.org/pipermail/fpc-other/attachments/20170606/6b13a20e/attachment.py>


More information about the fpc-other mailing list