While working, I make lots of revisions. Whenever the code is in reasonable shape, I like to commit. But not all of those commits are interesting. So I make these commits to the local disk or a private server. It looks something like this:
Foo
in the morning, so it's version is FamousSmalltalkGuy.14
.Foo
locally is up to DanielLyons.17
.FamousSmalltalkGuy.15
with what I have in my image, producing DanielLyons.18
.Now I want to push DanielLyons.18
up to Smalltalkhub. What's the right thing to do?
Copy the version (clicking the Copy button in the Monticello UI).
This feels wrong because there will be a discontinuity from FamousSmalltalkGuy.15
and DanielLyons.18
.
Commit a new version in the Smalltalkhub repository, manually writing DanielLyons.15
in the box.
This feels wrong, because it seems to confuse my local image. After all, it's seen a DanielLyons.15
before, and this isn't it.
I feel sure that there's a right thing to do here, but I don't know what it is. If anyone can shed some light on the right Monticello workflow for simultaneous collaborative development, I'd greatly appreciate it. Thanks!
You should copy all your versions to remote repository, otherwise you will loose valuable history. Curently because of how Monticello is implemented it produces a lot of broken links to ancestors, as people forget to copy intermediate versions from their local storage. And yes, version numbers are stupid. You cannot have sequential version numbers in distributed versioning, so I prefer to leave commit names as they are and just copy everything to the remote repository
Monticello has a so-called backport changes feature, that lets you apply changes you accumulated over several commits plant onto an older version. It is seldom used, tho.
Another process would be to locally make a branch and only at the end make a merge with the version you want to commit on.
A Monticello branch is done by appending -branchname
to the package name:
Foo-DanielLyons.18
becomes Foo-mybranch-DanielLyons.18
If Monticello refuses to merge, you can say “adopt as ancestor” and specify, that your new version has both your branch and the original commit as ancestors.
The process then goes like this:
Foo-FamousSmalltalkGuy.14
Foo-myImportantTopic-DanielLyons.15
Foo-myImportantTopic-DanielLyons.16
Foo-myImportantTopic-DanielLyons.17
Foo-FamousSmalltalkGuy.14
Foo-DanielLyons.15
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With