Open LinqLover opened 4 years ago
Can't something like this be done in a postLoad
method?
AFAIK this can be done with a specifc subclass in metacello. There are such things for filetree+git, http+monicello, files+monitcello etc; The filetree/cypress variant also works with cuis (https://github.com/CampSmalltalk/cuis-cypress).
There might be too many ways to do that and potentially none of the really feasible 🤪
Can't something like this be done in a
postLoad
method?
Hypothetically, yes, but 1) I would consider it more convenient if Metacello could handle all the required connection and filein logic, and 2) I would need to check in my postLoad whether the requiring package has actually been loaded. Imagine a third package in the baseline above, spec package: 'MyGreatPackage'
which does not require 'ShoutAttribute'
, so the changeset should also not be installed when only loading 'MyGreatPackage'
.
AFAIK this can be done with a specifc subclass in metacello.
But maybe with the difference that git, Monticello, etc. all specify some amount of version information? Just asking, I am not familiar with the source at all. :-)
Le mer. 7 oct. 2020 à 13:28, Christoph Thiede notifications@github.com a écrit :
Can't something like this be done in a postLoad method?
Hypothetically, yes, but 1) I would consider it more convenient if Metacello could handle all the required connection and filein logic, and 2) I would need to check in my postLoad whether the requiring package has actually been loaded. Imagine a third package in the baseline above, spec package: 'MyGreatPackage' which does not require 'ShoutAttribute', so the changeset should also not be installed when only loading 'MyGreatPackage'.
AFAIK this can be done with a specifc subclass in metacello.
But maybe with the difference that git, Monticello, etc. all specify some amount of version information? Just asking, I am not familiar with the source at all. :-)
The version information only matters if you have multiple change sets to choose from; a solution used by FileTree is to say that everything is version 1 (i.e. no version handling).
One could also add a Monticello repository subclass to designate folders where the changesets are kept (and the change in Metacello to have a changeset url handling). This would also allow integration in the Monticello GUI tools.
FYIO, a naive solution for my original desire exists in https://github.com/LinqLover/TelegramSmalltalkBot/blob/2ea661dd88d23084f40e2865d2379570c72d0140/src/BaselineOfTelegramSmalltalkBot.package/BaselineOfTelegramSmalltalkBot.class/instance/installPreviewDependencies.st (also copied with slight variations to https://github.com/LinqLover/TelegramBot and https://github.com/LinqLover/SimulationStudio), which is based on postLoad scripts.
I'm still not very happy with this (see also https://github.com/LinqLover/TelegramSmalltalkBot/issues/15) because it does not use any meta information at all, but if you need a fast solution, you might want to copy this :)
Hi,
not sure whether this is the right place for such a question/feature request, but in my BaselineOfMyWonderfulProject, I'd like to specify the requirement of a package to a changeset file that is available via an HTTP(S) server. Does Metacello support this? Is there any list of the supported repository formats?
Pseudocode would be something like this:
Or is this generally impossible because changesets do not provide any necessary metadata?