[Glass] metadata-less FileTree repository support - part I

Dale Henrichs via Glass glass at lists.gemtalksystems.com
Mon Jul 11 16:31:39 PDT 2016


Historically FileTree repositories have attempted to preserve the 
Monticello metadata: version history and method timestamps. This was 
done to make it easier for folks to take FileTree for a spin without 
losing the Monticello version history. Monticello packages could be 
moved into and out of FileTree repositories without any evidence that 
part of their lives was spent in a git repository.

As more folks have begun using FileTree repositories and GitHub and with 
packages spending their entire lives in git repositories, the Monticello 
meta data has become more of an annoyance than a useful feature.

The files where the Monticello metadata is kept in FileTree are modified 
on nearly every commit and can be the source of git merge conflicts. To 
ameliorate this problem, Thierry Goubier[1] created 
GitFileTree-MergeDriver[2] which took advantage of the git merge hooks 
and ran code in Pharo to automatically resolve the merge conflicts for 
version and method timestamps. The GitFileTree-MergeDriver works great 
on your local disk, but when merging changes on GitHub for pull requests 
the GitFileTree-MergeDriver cannot be used and it becomes impossible to 
simply press the "Merge pull request" button and you have to manually do 
the merge on your local disk -- of course GitFileTree-MergeDriver works 
there, but it is annoying to not be able to do automatic merges.

The only real solution to this problem is to stop storing Monticello 
metadata in a FileTree repository.

About 3 years ago, I added a "Cypress package feature" to Metacello[4] 
so that Monticello meta data was not needed when using a BaselineOf to 
load packages from a FileTree repository --- for those who are not 
aware, standard Metacello only loads packages with newer Monticello 
version numbers (part of the version history). The feature was a little 
bit ahead of it's time, as there were very few developers actually using 
GitHub for their Smalltalk projects.

Alon about the same time, Thierry created GitFileTree a variant of 
FileTree for Pharo that hooks into the Monticello Browser and fabricates 
the Monticello metadata from the Git meta data, making the metadata file 
obsolete. GitFileTree made it practical for Pharo developers to use 
FileTree much like tODE has made it practical to use git for 
GemStone/GsDevKit projects.

8 months or so ago, Thierry added a metadata-less option to GitFileTree 
where for GitFileTree the version history and method timestamp files 
were no longer written/updated. To control this option, Thierry added a 
"Metadata" field to the repository properties file, so that users could 
choose whether or not they wanted to preserve Monticello meta data.

About 6 months ago, during a discussion on the Pharo list[3], the 
question of Monticello meta data came up and I became aware of the 
metadata-less feature and at the time there was interest in being able 
to use the "Metacello Cypress package support" with GitFileTree 
repositories and began thinking that perhaps it was finally time to blow 
the dust off of "Metacello Cypress packages" and add a metadata-less 
feature to the GemStone FileTree implementation.

So here we are a mere 6 months later and I've finally gotten around to 
taking action with 3 pending pull requests:

   - PR #198: add a metadata-less option to GemStone FileTree 
repositories[5]
   - PR #401: official support for "Metacello Cypress packages"[6]
   - PR #12: performance improvement for creating snapshots in 
GLASS/GsDevKit

Over the next day or so, I plan to merge these pull requests into the 
master branches.

If you have any questions about these new features, now is a good time 
to ask.

Dale

[1] https://github.com/ThierryGoubier
[2] 
https://github.com/ThierryGoubier/GitFileTree-MergeDriver#gitfiletree-mergedriver
[3] http://forum.world.st/Contributing-to-Pharo-tc4871604.html#none
[4] 
https://github.com/dalehenrich/metacello-work/commits/master/repository/Metacello-Cypress.package
[5] https://github.com/dalehenrich/filetree/pull/198
[6] https://github.com/dalehenrich/metacello-work/pull/401
[7] https://github.com/glassdb/glass/pull/12


More information about the Glass mailing list