-
-
Notifications
You must be signed in to change notification settings - Fork 75
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Create mxdev sources and checkouts #903
base: 6.1
Are you sure you want to change the base?
Conversation
7e6ae90
to
f1e63a3
Compare
53e9369
to
34301ff
Compare
34301ff
to
dae4fae
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Interesting, thanks.
Have you seen the work I did on plone.releaser
the past months? For example in plone/plone.releaser#62 I added a bin/manage versions2constraints
command and recently used this on the coredev 6.1 branch.
There is code to read on the one hand a checkouts.cfg
and sources.cfg
and on the other hand a mxdev
ini file. Just the translation between the two needs to be hooked up.
And I obviously did not yet use the new include
functionality.
My preferred solution would be:
- Use the code that already is in
plone.releaser
, as this has tests. - Improve it so it can use the new
include
functionality frommxdev
. - Add a
bin/manage buildout2mxdev
(orbuildout2pip
) command that translates all Buildout versions, checkouts and sources files to pip/mxdev files.
We can consider using your code for now, as it is available and seems to be working. Later we could switch to using plone.releaser
.
Well, the tox command currently fails for me:
$ tox -c release/tox.ini -e mxdev
mxdev: commands[0] /Users/maurits/community/plone-coredev/6.1/release> python create-mxsources.py /Users/maurits/community/plone-coredev/6.1/release/../buildout.cfg /Users/maurits/community/plone-coredev/6.1/release/../sources.ini
Traceback (most recent call last):
File "/Users/maurits/community/plone-coredev/6.1/release/create-mxsources.py", line 15, in <module>
from zc.buildout import buildout
ModuleNotFoundError: No module named 'zc'
BTW, do you and @jensens indeed prefer to split the sources and checkouts in two files? I would be fine with either one or two files, but two files make it a bit easier to translate between our current buildout config and mxdev, so I would be happy with that approach. A short BTW, several commands already work on both buildout and mxdev files. If you temporarily rename or copy
|
I think having 3 files has it advantages.
This way one may use only sources with own checkouts/branches(think PLIPS) overrides. |
print("ERROR. Usage: create-mxcheckouts.py buildout.cfg checkouts.ini") | ||
sys.exit(1) | ||
config_file = sys.argv[1] | ||
config_file = os.path.realpath(config_file) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Using pathlib.Path makes it all much nicer to read 😃
Sorry on the phone ,I can provide suggestions later 😃
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, with @mauritsvanrees plone.releaser changes we are getting closer and closer to replace zc.buildout finally 😃
So this has no url, branch, etc. For an example, see plone/buildout.coredev#903
Add scripts to create mxdev compatible ini files from sources.cfg and checkouts.cfg.
This feature is useful with the mxdev
include
feature, available since mxdev 3.1.0 and done at the Kitchen Sprint 2023 in Völs. See: mxstack/mxdev#37TODO