Add Create a backend add-on section in the Developer guide with GenericSetup#1757
Add Create a backend add-on section in the Developer guide with GenericSetup#1757stevepiercy wants to merge 28 commits into6.0from
GenericSetup#1757Conversation
- Add term reference for Buildout
GenericSetup
|
I'm ready to close this issue as won't fix. Does anyone on @plone/classicui-team care about the topic of how to add or create a backend add-on section in the Developer guide with GenericSetup? If so, speak up, and let's get this finished. |
|
@stevepiercy will have a look at this. |
|
I've created a basic "addon creation documentation" and moved the old docs for GenericSetup here. I've also removed several outdated parts/link and tried to update the XML examples. Not finished yet though. I would recommend to place these docs all inside "Backend" and make a link from "Developer guide / Develop backend add-ons" -> "Backend / Add-ons" (like its done for Volto add-ons) Further we can add references for several What do you think? |
|
what's also missing is something like "Installing backend Add-on" ... at least I didn't find it... would also make sense to add it to "Backend / Add-ons" chapter. EDIT: I mean adding a pypi package or source checkout to cookieplone/buildout project ... |
Was this what you couldn't find? https://6.docs.plone.org/admin-guide/add-ons.html The plan is to merge the Admin section into Develop section so that people don't have to think of what role they're in versus the task they want to perform. See #1997. |
Co-authored-by: Mikel Larreategi <mlarreategi@codesyntax.com>
@petschki I don't see a commit to remove the outdated bits. Did you forget to push it? Please let me know. Thank you! |
|
I would use plonecli for all, after @erral did the final release in the comming days. example: uv tool install plonecli
plonecli create addon collective.myaddon
cd collective.myaddon
plonecli add content_type
...
We could even create a full cookieplone project with plonecli. plonecli create volto-projector plonecli create cookieplone-projector plonecli create plone-projectit doesn't matter and we are flexible to replace part under it, with the next cool tool, someone creates, without destroing exiting docs and api's. my 50cent... |
|
@MrTango I had documente the I think, due to the fact that the whole plone installation and theme development documentation uses cookieplone, we should at least use it for the inital addon package creation too ... when adding further features inside the addon, we can document this with using |
|
@petschki @MrTango sorry for the mess... with plonecli right now we can create an add-on calling I haven't checked to do the same for volto addon, project, etc, but could be done, and it is not that hard. If we do that we can document everything to use plonecli indeed, and But we also have documentation to create Volto projects using |
|
cookieplone is the framework with utils to full manage a Plone project while plonecli is a client that implements the frameworks (past and present). |
|
What are the use cases that we're trying to solve with this page of documentation? Maybe that answer will help us give a direction. Would y'all agree there are essentially two scenarios?
Neither Cookieplone nor plonecli are going away anytime soon. If we have two or more ways of doing the same thing, that's fine, too, provided we give sufficient information for the reader to choose which tool is best for them. For an example of that, see Choose a user interface. It's also OK if we use one tool to do one part, such as using Cookieplone to create a monorepo with all the things, and another tool to do another part, such as add new features to the backend add-on. Does this help at all? |
davisagli
left a comment
There was a problem hiding this comment.
Let's see if we can get this over the finish line.
There was a problem hiding this comment.
I just skimmed through to check that this is still accurate/relevant information. It is and we should prioritize getting this merged. It does need some editing to match current doc styles.
|
I have just released new versions for mr.bob, plonecli and bobtemplates removing all pkg_resources style namespaces. I tested the three of them together and it works as expected. I will review this PR tomorrow to check that everything is Ok. |
erral
left a comment
There was a problem hiding this comment.
I have checked the output of uvx plonecli and it is a bit different than the previous version.
|
|
||
| --> Package description [An add-on for Plone]: | ||
|
|
||
| --> Plone version [6.0.0]: | ||
|
|
||
| --> Python version for virtualenv [python3]: | ||
|
|
||
| --> Do you want me to activate VS Code support? (y/n) [y]: | ||
|
|
||
|
|
||
|
|
||
| isort-apply: successful: | ||
| isort-apply: install_deps> python -I -m pip install isort -c constraints.txt | ||
| isort-apply: commands[0]> isort /Users/<username>/Development/collective.addon/src | ||
| /Users/<username>/Development/collective.addon/setup.py | ||
| Fixing /Users/<username>/Development/collective.addon/src/collective/addon/testing.py | ||
| Fixing /Users/<username>/Development/collective.addon/src/collective/addon/tests/test_setup.py | ||
| isort-apply: OK (2.57=setup[1.94]+cmd[0.63] seconds) | ||
| congratulations :) (2.59 seconds) | ||
|
|
||
|
|
||
| Identified `/` as project root containing a file system root. | ||
| Sources to be formatted: "Users/<username>/Development/collective.addon/src", | ||
| "Users/<username>/Development/collective.addon/setup.py" | ||
| src/collective/__init__.py wasn't modified on disk since last run. | ||
| src/collective/addon/browser/__init__.py wasn't modified on disk since last run. | ||
| src/collective/addon/locales/__init__.py wasn't modified on disk since last run. | ||
| src/collective/addon/tests/__init__.py wasn't modified on disk since last run. | ||
| src/collective/addon/interfaces.py already well formatted, good job. | ||
| reformatted src/collective/addon/__init__.py | ||
| reformatted src/collective/addon/setuphandlers.py | ||
| reformatted src/collective/addon/testing.py | ||
| reformatted setup.py | ||
| reformatted src/collective/addon/locales/update.py | ||
| reformatted src/collective/addon/tests/test_setup.py | ||
|
|
||
| All done! ✨ 🍰 ✨ | ||
| 6 files reformatted, 5 files left unchanged. | ||
|
|
||
| black-enforce: successful: | ||
| black-enforce: install_deps> python -I -m pip install black -c constraints.txt | ||
| black-enforce: commands[0]> black -v src setup.py | ||
| black-enforce: OK (2.60=setup[2.12]+cmd[0.48] seconds) | ||
| congratulations :) (2.61 seconds) | ||
|
|
||
|
|
||
| git init is disabled! | ||
| Generated file structure at /Users/<username>/Development/collective.addon/collective.addon | ||
| ``` |
There was a problem hiding this comment.
| --> Package description [An add-on for Plone]: | |
| --> Plone version [6.0.0]: | |
| --> Python version for virtualenv [python3]: | |
| --> Do you want me to activate VS Code support? (y/n) [y]: | |
| isort-apply: successful: | |
| isort-apply: install_deps> python -I -m pip install isort -c constraints.txt | |
| isort-apply: commands[0]> isort /Users/<username>/Development/collective.addon/src | |
| /Users/<username>/Development/collective.addon/setup.py | |
| Fixing /Users/<username>/Development/collective.addon/src/collective/addon/testing.py | |
| Fixing /Users/<username>/Development/collective.addon/src/collective/addon/tests/test_setup.py | |
| isort-apply: OK (2.57=setup[1.94]+cmd[0.63] seconds) | |
| congratulations :) (2.59 seconds) | |
| Identified `/` as project root containing a file system root. | |
| Sources to be formatted: "Users/<username>/Development/collective.addon/src", | |
| "Users/<username>/Development/collective.addon/setup.py" | |
| src/collective/__init__.py wasn't modified on disk since last run. | |
| src/collective/addon/browser/__init__.py wasn't modified on disk since last run. | |
| src/collective/addon/locales/__init__.py wasn't modified on disk since last run. | |
| src/collective/addon/tests/__init__.py wasn't modified on disk since last run. | |
| src/collective/addon/interfaces.py already well formatted, good job. | |
| reformatted src/collective/addon/__init__.py | |
| reformatted src/collective/addon/setuphandlers.py | |
| reformatted src/collective/addon/testing.py | |
| reformatted setup.py | |
| reformatted src/collective/addon/locales/update.py | |
| reformatted src/collective/addon/tests/test_setup.py | |
| All done! ✨ 🍰 ✨ | |
| 6 files reformatted, 5 files left unchanged. | |
| black-enforce: successful: | |
| black-enforce: install_deps> python -I -m pip install black -c constraints.txt | |
| black-enforce: commands[0]> black -v src setup.py | |
| black-enforce: OK (2.60=setup[2.12]+cmd[0.48] seconds) | |
| congratulations :) (2.61 seconds) | |
| git init is disabled! | |
| Generated file structure at /Users/<username>/Development/collective.addon/collective.addon | |
| ``` | |
| ```suggestion | |
| --> Author's name [John Doe]: | |
| --> Author's email [johndoe@plone.org]: | |
| --> Author's GitHub username: | |
| --> Package description [An add-on for Plone]: | |
| --> Do you want me to initialize a GIT repository in your new package? (y/n) [y]: | |
| --> Plone version [6.0.0]: | |
| --> Python version for virtualenv [python3]: | |
| --> Do you want me to activate VS Code support? (y/n) [y]: | |
| ╭────────────────────────────────────────────────────────────────── cookieplone ──────────────────────────────────────────────────────────────────╮ | |
| │ │ | |
| │ ******* │ | |
| │ *************** │ | |
| │ *** *** ********* *** *** │ | |
| │ *** *** *** *********** *** * R * │ | |
| │ *** ***** *** *** *** *** *** │ | |
| │ *** *** *** *** *** *** **** *** *** **** │ | |
| │ *** *** *** *** *** *** ******** ********* ******** │ | |
| │ *** ***** *** *********** *** *** *** **** *** *** *** │ | |
| │ *** *** *** *** ********* *** *** *** *** *** ********** │ | |
| │ *** ***** *** *** *** *** *** *** *** ********* │ | |
| │ *** *** *** *** **** *** *** *** *** *** ... │ | |
| │ *** *** *** ***** ******** *** *** ******** │ | |
| │ *************** *** *** **** *** *** **** │ | |
| │ ******* │ | |
| │ │ | |
| ╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ | |
| ╭────────────────────────────────────────────────────────────────── Plone Addon ──────────────────────────────────────────────────────────────────╮ | |
| │ │ | |
| │ Creating a new Plone Addon │ | |
| │ │ | |
| │ Sanity check results: │ | |
| │ │ | |
| │ - Cookieplone: ✓ │ | |
| │ - uv: ✓ │ | |
| │ - git: ✓ │ | |
| │ │ | |
| ╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ | |
| -> Remove files used in classic UI setup | |
| -> Create namespace packages | |
| -> Format code | |
| -> Initialize Git repository | |
| -> Generate documentation scaffold | |
| -> Setup VSCode configuration | |
| -> Setup GitHub CI | |
| ╭──────────────────────────────────────────────────────────── New addon was generated ────────────────────────────────────────────────────────────╮ | |
| │ │ | |
| │ collective.addon │ | |
| │ │ | |
| │ Now, enter the repository, start coding, and push to your organization. │ | |
| │ │ | |
| │ Sorry for the convenience, │ | |
| │ The Plone Community. │ | |
| │ │ | |
| │ https://plone.org/ │ | |
| ╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ | |
| Done | |
| Generated file structure at /tmp/collective.addon |
See #1748 (comment)
Closes #1754.
Ping @petschki to take it from here.
📚 Documentation preview 📚: https://plone6--1757.org.readthedocs.build/