plonecli 2.4__tar.gz → 3.0b1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (49) hide show
  1. {plonecli-2.4 → plonecli-3.0b1}/CHANGES.rst +16 -0
  2. {plonecli-2.4 → plonecli-3.0b1}/PKG-INFO +44 -20
  3. {plonecli-2.4 → plonecli-3.0b1}/README.rst +4 -9
  4. {plonecli-2.4 → plonecli-3.0b1}/docs/Makefile +1 -1
  5. {plonecli-2.4 → plonecli-3.0b1}/plonecli/__init__.py +2 -2
  6. {plonecli-2.4 → plonecli-3.0b1}/plonecli/cli.py +32 -11
  7. {plonecli-2.4 → plonecli-3.0b1}/plonecli/configure_mrbob.py +12 -9
  8. {plonecli-2.4 → plonecli-3.0b1}/plonecli/registry.py +3 -3
  9. {plonecli-2.4 → plonecli-3.0b1}/plonecli.egg-info/PKG-INFO +44 -20
  10. {plonecli-2.4 → plonecli-3.0b1}/plonecli.egg-info/SOURCES.txt +1 -0
  11. {plonecli-2.4 → plonecli-3.0b1}/plonecli.egg-info/entry_points.txt +0 -1
  12. {plonecli-2.4 → plonecli-3.0b1}/plonecli.egg-info/requires.txt +1 -1
  13. plonecli-3.0b1/requirements.txt +2 -0
  14. {plonecli-2.4 → plonecli-3.0b1}/setup.cfg +8 -7
  15. {plonecli-2.4 → plonecli-3.0b1}/setup.py +1 -1
  16. plonecli-3.0b1/tests/conftest.py +11 -0
  17. {plonecli-2.4 → plonecli-3.0b1}/tests/test_plonecli.py +15 -39
  18. {plonecli-2.4 → plonecli-3.0b1}/tests/test_registry.py +22 -27
  19. {plonecli-2.4 → plonecli-3.0b1}/tox.ini +27 -19
  20. plonecli-2.4/tests/conftest.py +0 -13
  21. {plonecli-2.4 → plonecli-3.0b1}/AUTHORS.rst +0 -0
  22. {plonecli-2.4 → plonecli-3.0b1}/CONTRIBUTING.rst +0 -0
  23. {plonecli-2.4 → plonecli-3.0b1}/LICENSE +0 -0
  24. {plonecli-2.4 → plonecli-3.0b1}/MANIFEST.in +0 -0
  25. {plonecli-2.4 → plonecli-3.0b1}/docs/authors.rst +0 -0
  26. {plonecli-2.4 → plonecli-3.0b1}/docs/conf.py +0 -0
  27. {plonecli-2.4 → plonecli-3.0b1}/docs/contributing.rst +0 -0
  28. {plonecli-2.4 → plonecli-3.0b1}/docs/history.rst +0 -0
  29. {plonecli-2.4 → plonecli-3.0b1}/docs/index.rst +0 -0
  30. {plonecli-2.4 → plonecli-3.0b1}/docs/installation.rst +0 -0
  31. {plonecli-2.4 → plonecli-3.0b1}/docs/make.bat +0 -0
  32. {plonecli-2.4 → plonecli-3.0b1}/docs/plone_cli_logo.png +0 -0
  33. {plonecli-2.4 → plonecli-3.0b1}/docs/plone_cli_logo.svg +0 -0
  34. {plonecli-2.4 → plonecli-3.0b1}/docs/plonecli_add_content_type_optimized.gif +0 -0
  35. {plonecli-2.4 → plonecli-3.0b1}/docs/plonecli_add_theme_optimized.gif +0 -0
  36. {plonecli-2.4 → plonecli-3.0b1}/docs/plonecli_add_vocabulary_optimized.gif +0 -0
  37. {plonecli-2.4 → plonecli-3.0b1}/docs/plonecli_build_optimized.gif +0 -0
  38. {plonecli-2.4 → plonecli-3.0b1}/docs/plonecli_create_addon_optimized.gif +0 -0
  39. {plonecli-2.4 → plonecli-3.0b1}/docs/plonecli_serve_optimized.gif +0 -0
  40. {plonecli-2.4 → plonecli-3.0b1}/docs/readme.rst +0 -0
  41. {plonecli-2.4 → plonecli-3.0b1}/plonecli/configure_mrbob/.mrbob.ini +0 -0
  42. {plonecli-2.4 → plonecli-3.0b1}/plonecli/exceptions.py +0 -0
  43. {plonecli-2.4 → plonecli-3.0b1}/plonecli.egg-info/dependency_links.txt +0 -0
  44. {plonecli-2.4 → plonecli-3.0b1}/plonecli.egg-info/not-zip-safe +0 -0
  45. {plonecli-2.4 → plonecli-3.0b1}/plonecli.egg-info/top_level.txt +0 -0
  46. {plonecli-2.4 → plonecli-3.0b1}/plonecli.rst +0 -0
  47. {plonecli-2.4 → plonecli-3.0b1}/plonecli_autocomplete.sh +0 -0
  48. {plonecli-2.4 → plonecli-3.0b1}/tests/__init__.py +0 -0
  49. {plonecli-2.4 → plonecli-3.0b1}/tests/test_configure_mrbob.py +0 -0
@@ -1,6 +1,22 @@
1
1
  History
2
2
  =======
3
3
 
4
+ 3.0b1 (2026-04-14)
5
+ ------------------
6
+
7
+ - Support only python 3.11 - 3.14
8
+ [erral]
9
+
10
+ - Require setuptools < 82.0.0
11
+ [erral]
12
+
13
+
14
+ 2.5 (2022-11-03)
15
+ ----------------
16
+
17
+ - Provide a way to pass a mrbob configuration file
18
+ [erral]
19
+
4
20
  2.4 (2022-10-10)
5
21
  ----------------
6
22
 
@@ -1,13 +1,12 @@
1
- Metadata-Version: 2.1
1
+ Metadata-Version: 2.4
2
2
  Name: plonecli
3
- Version: 2.4
3
+ Version: 3.0b1
4
4
  Summary: A Plone CLI for creating Plone packages
5
5
  Home-page: https://github.com/plone/plonecli
6
6
  Author: Maik Derstappen
7
7
  Author-email: md@derico.de
8
8
  License: BSD License
9
9
  Keywords: plonecli
10
- Platform: UNKNOWN
11
10
  Classifier: Development Status :: 5 - Production/Stable
12
11
  Classifier: Intended Audience :: Developers
13
12
  Classifier: License :: OSI Approved :: BSD License
@@ -18,23 +17,35 @@ Classifier: Topic :: Software Development :: Quality Assurance
18
17
  Classifier: Topic :: Utilities
19
18
  Classifier: Environment :: Console
20
19
  Classifier: Framework :: Plone
20
+ Classifier: Framework :: Plone :: 6.0
21
21
  Classifier: Intended Audience :: Developers
22
- Classifier: Programming Language :: Python :: 3
23
- Classifier: Programming Language :: Python :: 3.6
24
- Classifier: Programming Language :: Python :: 3.7
25
- Classifier: Programming Language :: Python :: 3.8
22
+ Classifier: Programming Language :: Python :: 3.11
23
+ Classifier: Programming Language :: Python :: 3.12
24
+ Classifier: Programming Language :: Python :: 3.13
25
+ Classifier: Programming Language :: Python :: 3.14
26
26
  Requires-Python: >=3.6
27
- Provides-Extra: test
28
- Provides-Extra: dev
29
27
  License-File: LICENSE
30
28
  License-File: AUTHORS.rst
29
+ Requires-Dist: setuptools<82.0.0
30
+ Requires-Dist: Click>=7.0
31
+ Requires-Dist: click-aliases
32
+ Requires-Dist: mr.bob
33
+ Requires-Dist: bobtemplates.plone>=6.0b15
34
+ Requires-Dist: tox
35
+ Provides-Extra: test
36
+ Requires-Dist: pytest; extra == "test"
37
+ Requires-Dist: isort>=5.0.0; extra == "test"
38
+ Provides-Extra: dev
39
+ Requires-Dist: tox; extra == "dev"
40
+ Requires-Dist: zest.releaser[recommended]; extra == "dev"
41
+ Dynamic: keywords
42
+ Dynamic: license-file
43
+ Dynamic: provides-extra
44
+ Dynamic: requires-dist
45
+ Dynamic: requires-python
31
46
 
32
- .. image:: https://secure.travis-ci.org/plone/plonecli.png?branch=master
33
- :target: http://travis-ci.org/plone/plonecli
34
-
35
- .. image:: https://coveralls.io/repos/github/plone/plonecli/badge.svg?branch=master
36
- :target: https://coveralls.io/github/plone/plonecli?branch=master
37
- :alt: Coveralls
47
+ .. image:: https://github.com/plone/plonecli/actions/workflows/python-package.yml/badge.svg
48
+ :target: https://github.com/plone/plonecli/actions/workflows/python-package.yml
38
49
 
39
50
  .. image:: https://img.shields.io/pypi/v/plonecli.svg
40
51
  :target: https://pypi.python.org/pypi/plonecli/
@@ -43,6 +54,7 @@ License-File: AUTHORS.rst
43
54
  .. image:: https://img.shields.io/pypi/pyversions/bobtemplates.plone.svg?style=plastic
44
55
  :alt: PyPI - Python Version
45
56
 
57
+
46
58
  =========
47
59
  Plone CLI
48
60
  =========
@@ -204,7 +216,6 @@ Creating A Plone Add-on
204
216
  - viewlet
205
217
  - vocabulary
206
218
  - buildout
207
- - theme_package [deprecated] >> Please use the theme_barceloneta subtemplate!
208
219
 
209
220
  $ plonecli create addon src/collective.todo
210
221
 
@@ -331,7 +342,7 @@ Register Your Bobtemplates Package For Plonecli
331
342
 
332
343
  All mr.bob templates can be registered for plonecli by adding an entry_point to your setup.py.
333
344
 
334
- Here are the entry_points of the bobtemplates.plone package:
345
+ Here are some entry_points of the bobtemplates.plone package:
335
346
 
336
347
  .. code-block:: python
337
348
 
@@ -339,7 +350,6 @@ Here are the entry_points of the bobtemplates.plone package:
339
350
  'mrbob_templates': [
340
351
  'plone_addon = bobtemplates.plone.bobregistry:plone_addon',
341
352
  'plone_buildout = bobtemplates.plone.bobregistry:plone_buildout', # NOQA E501
342
- 'plone_theme_package = bobtemplates.plone.bobregistry:plone_theme_package', # NOQA E501
343
353
  'plone_content_type = bobtemplates.plone.bobregistry:plone_content_type', # NOQA E501
344
354
  'plone_view = bobtemplates.plone.bobregistry:plone_view',
345
355
  'plone_viewlet = bobtemplates.plone.bobregistry:plone_viewlet',
@@ -411,6 +421,22 @@ This project is licensed under the BSD license.
411
421
  History
412
422
  =======
413
423
 
424
+ 3.0b1 (2026-04-14)
425
+ ------------------
426
+
427
+ - Support only python 3.11 - 3.14
428
+ [erral]
429
+
430
+ - Require setuptools < 82.0.0
431
+ [erral]
432
+
433
+
434
+ 2.5 (2022-11-03)
435
+ ----------------
436
+
437
+ - Provide a way to pass a mrbob configuration file
438
+ [erral]
439
+
414
440
  2.4 (2022-10-10)
415
441
  ----------------
416
442
 
@@ -645,5 +671,3 @@ History
645
671
 
646
672
  - initital version with list templates support and bobtemplates.plone integration
647
673
  [MrTango, tmassman, Gomez]
648
-
649
-
@@ -1,9 +1,5 @@
1
- .. image:: https://secure.travis-ci.org/plone/plonecli.png?branch=master
2
- :target: http://travis-ci.org/plone/plonecli
3
-
4
- .. image:: https://coveralls.io/repos/github/plone/plonecli/badge.svg?branch=master
5
- :target: https://coveralls.io/github/plone/plonecli?branch=master
6
- :alt: Coveralls
1
+ .. image:: https://github.com/plone/plonecli/actions/workflows/python-package.yml/badge.svg
2
+ :target: https://github.com/plone/plonecli/actions/workflows/python-package.yml
7
3
 
8
4
  .. image:: https://img.shields.io/pypi/v/plonecli.svg
9
5
  :target: https://pypi.python.org/pypi/plonecli/
@@ -12,6 +8,7 @@
12
8
  .. image:: https://img.shields.io/pypi/pyversions/bobtemplates.plone.svg?style=plastic
13
9
  :alt: PyPI - Python Version
14
10
 
11
+
15
12
  =========
16
13
  Plone CLI
17
14
  =========
@@ -173,7 +170,6 @@ Creating A Plone Add-on
173
170
  - viewlet
174
171
  - vocabulary
175
172
  - buildout
176
- - theme_package [deprecated] >> Please use the theme_barceloneta subtemplate!
177
173
 
178
174
  $ plonecli create addon src/collective.todo
179
175
 
@@ -300,7 +296,7 @@ Register Your Bobtemplates Package For Plonecli
300
296
 
301
297
  All mr.bob templates can be registered for plonecli by adding an entry_point to your setup.py.
302
298
 
303
- Here are the entry_points of the bobtemplates.plone package:
299
+ Here are some entry_points of the bobtemplates.plone package:
304
300
 
305
301
  .. code-block:: python
306
302
 
@@ -308,7 +304,6 @@ Here are the entry_points of the bobtemplates.plone package:
308
304
  'mrbob_templates': [
309
305
  'plone_addon = bobtemplates.plone.bobregistry:plone_addon',
310
306
  'plone_buildout = bobtemplates.plone.bobregistry:plone_buildout', # NOQA E501
311
- 'plone_theme_package = bobtemplates.plone.bobregistry:plone_theme_package', # NOQA E501
312
307
  'plone_content_type = bobtemplates.plone.bobregistry:plone_content_type', # NOQA E501
313
308
  'plone_view = bobtemplates.plone.bobregistry:plone_view',
314
309
  'plone_viewlet = bobtemplates.plone.bobregistry:plone_viewlet',
@@ -3,7 +3,7 @@
3
3
 
4
4
  # You can set these variables from the command line.
5
5
  SPHINXOPTS =
6
- SPHINXBUILD = sphinx-build
6
+ SPHINXBUILD = ./venv/bin/sphinx-build
7
7
  PAPER =
8
8
  BUILDDIR = _build
9
9
 
@@ -1,9 +1,9 @@
1
1
  # -*- coding: utf-8 -*-
2
2
  """Top-level package for Plone CLI."""
3
3
 
4
- import pkg_resources
4
+ import importlib.metadata
5
5
 
6
6
 
7
7
  __author__ = """Maik Derstappen"""
8
8
  __email__ = "md@derico.de"
9
- __version__ = pkg_resources.require("plonecli")[0].version
9
+ __version__ = importlib.metadata.version("plonecli")
@@ -3,9 +3,11 @@
3
3
 
4
4
  from __future__ import absolute_import
5
5
 
6
+ import importlib.metadata
7
+
6
8
  from click_aliases import ClickAliasedGroup
7
9
  from mrbob.cli import main as mrbobmain
8
- from pkg_resources import WorkingSet
10
+
9
11
  from plonecli.configure_mrbob import is_venv_disabled
10
12
  from plonecli.exceptions import NoSuchValue
11
13
  from plonecli.exceptions import NotInPackageError
@@ -58,10 +60,8 @@ def cli(context, list_templates, versions):
58
60
  if list_templates:
59
61
  click.echo(reg.list_templates())
60
62
  if versions:
61
- ws = WorkingSet()
62
- bobtemplates_dist = ws.by_key["bobtemplates.plone"]
63
- bobtemplates_version = bobtemplates_dist.version
64
- plonecli_version = ws.by_key["plonecli"].version
63
+ bobtemplates_version = importlib.metadata.version("bobtemplates.plone")
64
+ plonecli_version = importlib.metadata.version("plonecli")
65
65
  version_str = """Available packages:\n
66
66
  plonecli : {0}\n
67
67
  bobtemplates.plone: {1}\n""".format(
@@ -73,8 +73,14 @@ def cli(context, list_templates, versions):
73
73
  @cli.command()
74
74
  @click.argument("template", type=click.STRING, shell_complete=get_templates)
75
75
  @click.argument("name")
76
+ @click.option(
77
+ "-b",
78
+ "--bobconfig",
79
+ default=None,
80
+ help="mrbob configuration file. The default is ~/.mrbob.",
81
+ )
76
82
  @click.pass_context
77
- def create(context, template, name):
83
+ def create(context, template, name, bobconfig):
78
84
  """Create a new Plone package"""
79
85
  bobtemplate = reg.resolve_template_name(template)
80
86
  if bobtemplate is None:
@@ -83,18 +89,29 @@ def create(context, template, name):
83
89
  )
84
90
  cur_dir = os.getcwd()
85
91
  context.obj["target_dir"] = "{0}/{1}".format(cur_dir, name)
92
+
93
+ mrbob_args = [bobtemplate, "-O", name]
94
+ if bobconfig is not None:
95
+ mrbob_args.extend(["-c", bobconfig])
96
+
86
97
  echo(
87
- "\nRUN: mrbob {0} -O {1}".format(bobtemplate, name),
98
+ "\nRUN: {0}".format(" ".join(mrbob_args)),
88
99
  fg="green",
89
100
  reverse=True,
90
101
  )
91
- mrbobmain([bobtemplate, "-O", name])
102
+ mrbobmain(mrbob_args)
92
103
 
93
104
 
94
105
  @cli.command()
95
106
  @click.argument("template", type=click.STRING, shell_complete=get_templates)
107
+ @click.option(
108
+ "-b",
109
+ "--bobconfig",
110
+ default=None,
111
+ help="mrbob configuration file. The default is ~/.mrbob.",
112
+ )
96
113
  @click.pass_context
97
- def add(context, template):
114
+ def add(context, template, bobconfig):
98
115
  """Add features to your existing Plone package"""
99
116
  if context.obj.get("target_dir", None) is None:
100
117
  raise NotInPackageError(context.command.name)
@@ -103,8 +120,12 @@ def add(context, template):
103
120
  raise NoSuchValue(
104
121
  context.command.name, template, possibilities=reg.get_templates()
105
122
  )
106
- echo("\nRUN: mrbob {0}".format(bobtemplate), fg="green", reverse=True)
107
- mrbobmain([bobtemplate])
123
+ mrbob_args = [bobtemplate]
124
+ if bobconfig is not None:
125
+ mrbob_args.extend(["-c", bobconfig])
126
+
127
+ echo("\nRUN: mrbob {0}".format(" ".join(mrbob_args)), fg="green", reverse=True)
128
+ mrbobmain(mrbob_args)
108
129
 
109
130
 
110
131
  @cli.command("venv", aliases=["virtualenv"])
@@ -52,17 +52,17 @@ def configoverride_warning_post_question(configurator, question, answer):
52
52
 
53
53
  def mrbob_config_exists(configurator, answer):
54
54
  target_directory = home_path
55
- file_name = u".mrbob"
55
+ file_name = ".mrbob"
56
56
  file_list = os.listdir(target_directory)
57
57
  if file_name not in file_list:
58
58
  raise SkipQuestion(
59
- u"No existing mrbob config file found, so we skip this question."
59
+ "No existing mrbob config file found, so we skip this question."
60
60
  )
61
61
 
62
62
 
63
63
  def check_git_disabled(configurator, answer):
64
64
  if configurator.variables["configure_mrbob.package.git.disabled"]:
65
- raise SkipQuestion(u"GIT is disabled, so we skip git related questions.")
65
+ raise SkipQuestion("GIT is disabled, so we skip git related questions.")
66
66
 
67
67
 
68
68
  def get_mrbob_config_variable(varname, dirname):
@@ -73,7 +73,7 @@ def get_mrbob_config_variable(varname, dirname):
73
73
  file_list = os.listdir(dirname)
74
74
  if file_name not in file_list:
75
75
  return
76
- config.readfp(codecs.open(config_path, "r", "utf-8"))
76
+ config.read_file(codecs.open(config_path, "r", "utf-8"))
77
77
  if not config.sections():
78
78
  return
79
79
  if config.has_option("variables", varname):
@@ -145,7 +145,7 @@ def is_venv_disabled():
145
145
 
146
146
 
147
147
  def generate_mrbob_ini(configurator, directory_path, answers):
148
- file_name = u".mrbob"
148
+ file_name = ".mrbob"
149
149
  file_path = directory_path + "/" + file_name
150
150
  template = """[mr.bob]
151
151
  verbose = False
@@ -166,11 +166,14 @@ package.git.disabled = {4}
166
166
  safe_string(answers["package.git.disabled"]),
167
167
  )
168
168
  if not configurator.variables["configure_mrbob.package.git.disabled"]:
169
- template = template + """package.git.init = {0}
169
+ template = (
170
+ template
171
+ + """package.git.init = {0}
170
172
  package.git.autocommit = {1}
171
173
  """.format(
172
- safe_string(answers["package.git.init"]),
173
- safe_string(answers["package.git.autocommit"]),
174
+ safe_string(answers["package.git.init"]),
175
+ safe_string(answers["package.git.autocommit"]),
176
+ )
174
177
  )
175
178
  template = (
176
179
  template
@@ -225,6 +228,6 @@ def post_render(configurator, target_directory=None):
225
228
  target_directory = configurator.target_directory
226
229
  generate_mrbob_ini(configurator, target_directory, mrbob_config)
227
230
  echo(
228
- u"\nMrbob's settings have been saved to {0}/.mrbob\n".format(target_directory),
231
+ "\nMrbob's settings have been saved to {0}/.mrbob\n".format(target_directory),
229
232
  msg_type="info",
230
233
  )
@@ -2,9 +2,8 @@
2
2
 
3
3
  from __future__ import print_function
4
4
 
5
+ import importlib.metadata
5
6
  import os
6
- import pkg_resources
7
-
8
7
 
9
8
  try:
10
9
  from six.moves.configparser import ConfigParser
@@ -76,7 +75,8 @@ class TemplateRegistry(object):
76
75
  self.bob_config = read_bob_config(self.root_folder)
77
76
  self.templates = {}
78
77
  self.template_infos = {}
79
- for entry_point in pkg_resources.iter_entry_points("mrbob_templates"):
78
+
79
+ for entry_point in importlib.metadata.entry_points(group="mrbob_templates"):
80
80
  template_info_method = entry_point.load()
81
81
  self.template_infos[entry_point.name] = template_info_method()
82
82
 
@@ -1,13 +1,12 @@
1
- Metadata-Version: 2.1
1
+ Metadata-Version: 2.4
2
2
  Name: plonecli
3
- Version: 2.4
3
+ Version: 3.0b1
4
4
  Summary: A Plone CLI for creating Plone packages
5
5
  Home-page: https://github.com/plone/plonecli
6
6
  Author: Maik Derstappen
7
7
  Author-email: md@derico.de
8
8
  License: BSD License
9
9
  Keywords: plonecli
10
- Platform: UNKNOWN
11
10
  Classifier: Development Status :: 5 - Production/Stable
12
11
  Classifier: Intended Audience :: Developers
13
12
  Classifier: License :: OSI Approved :: BSD License
@@ -18,23 +17,35 @@ Classifier: Topic :: Software Development :: Quality Assurance
18
17
  Classifier: Topic :: Utilities
19
18
  Classifier: Environment :: Console
20
19
  Classifier: Framework :: Plone
20
+ Classifier: Framework :: Plone :: 6.0
21
21
  Classifier: Intended Audience :: Developers
22
- Classifier: Programming Language :: Python :: 3
23
- Classifier: Programming Language :: Python :: 3.6
24
- Classifier: Programming Language :: Python :: 3.7
25
- Classifier: Programming Language :: Python :: 3.8
22
+ Classifier: Programming Language :: Python :: 3.11
23
+ Classifier: Programming Language :: Python :: 3.12
24
+ Classifier: Programming Language :: Python :: 3.13
25
+ Classifier: Programming Language :: Python :: 3.14
26
26
  Requires-Python: >=3.6
27
- Provides-Extra: test
28
- Provides-Extra: dev
29
27
  License-File: LICENSE
30
28
  License-File: AUTHORS.rst
29
+ Requires-Dist: setuptools<82.0.0
30
+ Requires-Dist: Click>=7.0
31
+ Requires-Dist: click-aliases
32
+ Requires-Dist: mr.bob
33
+ Requires-Dist: bobtemplates.plone>=6.0b15
34
+ Requires-Dist: tox
35
+ Provides-Extra: test
36
+ Requires-Dist: pytest; extra == "test"
37
+ Requires-Dist: isort>=5.0.0; extra == "test"
38
+ Provides-Extra: dev
39
+ Requires-Dist: tox; extra == "dev"
40
+ Requires-Dist: zest.releaser[recommended]; extra == "dev"
41
+ Dynamic: keywords
42
+ Dynamic: license-file
43
+ Dynamic: provides-extra
44
+ Dynamic: requires-dist
45
+ Dynamic: requires-python
31
46
 
32
- .. image:: https://secure.travis-ci.org/plone/plonecli.png?branch=master
33
- :target: http://travis-ci.org/plone/plonecli
34
-
35
- .. image:: https://coveralls.io/repos/github/plone/plonecli/badge.svg?branch=master
36
- :target: https://coveralls.io/github/plone/plonecli?branch=master
37
- :alt: Coveralls
47
+ .. image:: https://github.com/plone/plonecli/actions/workflows/python-package.yml/badge.svg
48
+ :target: https://github.com/plone/plonecli/actions/workflows/python-package.yml
38
49
 
39
50
  .. image:: https://img.shields.io/pypi/v/plonecli.svg
40
51
  :target: https://pypi.python.org/pypi/plonecli/
@@ -43,6 +54,7 @@ License-File: AUTHORS.rst
43
54
  .. image:: https://img.shields.io/pypi/pyversions/bobtemplates.plone.svg?style=plastic
44
55
  :alt: PyPI - Python Version
45
56
 
57
+
46
58
  =========
47
59
  Plone CLI
48
60
  =========
@@ -204,7 +216,6 @@ Creating A Plone Add-on
204
216
  - viewlet
205
217
  - vocabulary
206
218
  - buildout
207
- - theme_package [deprecated] >> Please use the theme_barceloneta subtemplate!
208
219
 
209
220
  $ plonecli create addon src/collective.todo
210
221
 
@@ -331,7 +342,7 @@ Register Your Bobtemplates Package For Plonecli
331
342
 
332
343
  All mr.bob templates can be registered for plonecli by adding an entry_point to your setup.py.
333
344
 
334
- Here are the entry_points of the bobtemplates.plone package:
345
+ Here are some entry_points of the bobtemplates.plone package:
335
346
 
336
347
  .. code-block:: python
337
348
 
@@ -339,7 +350,6 @@ Here are the entry_points of the bobtemplates.plone package:
339
350
  'mrbob_templates': [
340
351
  'plone_addon = bobtemplates.plone.bobregistry:plone_addon',
341
352
  'plone_buildout = bobtemplates.plone.bobregistry:plone_buildout', # NOQA E501
342
- 'plone_theme_package = bobtemplates.plone.bobregistry:plone_theme_package', # NOQA E501
343
353
  'plone_content_type = bobtemplates.plone.bobregistry:plone_content_type', # NOQA E501
344
354
  'plone_view = bobtemplates.plone.bobregistry:plone_view',
345
355
  'plone_viewlet = bobtemplates.plone.bobregistry:plone_viewlet',
@@ -411,6 +421,22 @@ This project is licensed under the BSD license.
411
421
  History
412
422
  =======
413
423
 
424
+ 3.0b1 (2026-04-14)
425
+ ------------------
426
+
427
+ - Support only python 3.11 - 3.14
428
+ [erral]
429
+
430
+ - Require setuptools < 82.0.0
431
+ [erral]
432
+
433
+
434
+ 2.5 (2022-11-03)
435
+ ----------------
436
+
437
+ - Provide a way to pass a mrbob configuration file
438
+ [erral]
439
+
414
440
  2.4 (2022-10-10)
415
441
  ----------------
416
442
 
@@ -645,5 +671,3 @@ History
645
671
 
646
672
  - initital version with list templates support and bobtemplates.plone integration
647
673
  [MrTango, tmassman, Gomez]
648
-
649
-
@@ -6,6 +6,7 @@ MANIFEST.in
6
6
  README.rst
7
7
  plonecli.rst
8
8
  plonecli_autocomplete.sh
9
+ requirements.txt
9
10
  setup.cfg
10
11
  setup.py
11
12
  tox.ini
@@ -1,3 +1,2 @@
1
1
  [console_scripts]
2
2
  plonecli = plonecli.cli:cli
3
-
@@ -1,4 +1,4 @@
1
- setuptools
1
+ setuptools<82.0.0
2
2
  Click>=7.0
3
3
  click-aliases
4
4
  mr.bob
@@ -0,0 +1,2 @@
1
+ Sphinx
2
+ -e .
@@ -1,6 +1,6 @@
1
1
  [metadata]
2
2
  name = plonecli
3
- version = 2.4
3
+ version = 3.0b1
4
4
  description = A Plone CLI for creating Plone packages
5
5
  long_description = file: README.rst, CHANGES.rst
6
6
  keywords = plone cli bobtemplates mrbob zopeskel development
@@ -19,11 +19,12 @@ classifiers =
19
19
  Topic :: Utilities
20
20
  Environment :: Console
21
21
  Framework :: Plone
22
+ Framework :: Plone :: 6.0
22
23
  Intended Audience :: Developers
23
- Programming Language :: Python :: 3
24
- Programming Language :: Python :: 3.6
25
- Programming Language :: Python :: 3.7
26
- Programming Language :: Python :: 3.8
24
+ Programming Language :: Python :: 3.11
25
+ Programming Language :: Python :: 3.12
26
+ Programming Language :: Python :: 3.13
27
+ Programming Language :: Python :: 3.14
27
28
 
28
29
  [bumpversion]
29
30
  current_version = 0.1.1
@@ -39,7 +40,7 @@ universal = 1
39
40
 
40
41
  [flake8]
41
42
  exclude = docs,tmp,tmpdist,local,lib,build,bin,dist,include,man
42
- ignore = W503, C812, E501, T001 # E203, E266
43
+ ignore = W503, C812, E501, T001
43
44
  max-line-length = 88
44
45
  max-complexity = 18
45
46
  select = B,C,E,F,W,T4,B
@@ -55,7 +56,7 @@ ignore =
55
56
  .gitattributes
56
57
 
57
58
  [isort]
58
- profile = black
59
+ profile = plone
59
60
  multi_line_output = 3
60
61
  force_alphabetical_sort = True
61
62
  force_single_line = True
@@ -20,7 +20,7 @@ setup(
20
20
  include_package_data=True,
21
21
  python_requires=">=3.6",
22
22
  install_requires=[
23
- "setuptools",
23
+ "setuptools<82.0.0",
24
24
  "Click>=7.0",
25
25
  "click-aliases",
26
26
  "mr.bob",
@@ -0,0 +1,11 @@
1
+ import os
2
+ import pytest
3
+ import sys
4
+
5
+
6
+ @pytest.fixture(scope="module")
7
+ def plonecli_bin():
8
+ bin_path = os.path.abspath(os.path.dirname(sys.argv[0]))
9
+ plonecli_bin = bin_path + "/plonecli"
10
+ print("plonebin path: " + plonecli_bin)
11
+ yield plonecli_bin
@@ -70,9 +70,11 @@ git_init = y
70
70
  context.obj["target_dir"] = os.path.dirname(os.path.abspath("bobtemplate.cfg"))
71
71
 
72
72
  test_command_result_a = runner.invoke(
73
- cli.run_test, args=["--all"], obj=context.obj,
73
+ cli.run_test,
74
+ args=["--all"],
75
+ obj=context.obj,
74
76
  )
75
- assert u"\nRUN: ./bin/test --all" in test_command_result_a.output
77
+ assert "\nRUN: ./bin/test --all" in test_command_result_a.output
76
78
 
77
79
  test_command_result_t_a = runner.invoke(
78
80
  cli.run_test,
@@ -80,15 +82,17 @@ git_init = y
80
82
  obj=context.obj,
81
83
  )
82
84
  assert (
83
- u"./bin/test --test src/collective/todo/tests/test_robot.py --all"
85
+ "./bin/test --test src/collective/todo/tests/test_robot.py --all"
84
86
  in test_command_result_t_a.output
85
87
  ) # NOQA: E501
86
88
 
87
89
  test_command_result_s_a = runner.invoke(
88
- cli.run_test, args=["-s collective.todo", "-a"], obj=context.obj,
90
+ cli.run_test,
91
+ args=["-s collective.todo", "-a"],
92
+ obj=context.obj,
89
93
  )
90
94
  assert (
91
- u"./bin/test --package collective.todo --all"
95
+ "./bin/test --package collective.todo --all"
92
96
  in test_command_result_s_a.output
93
97
  ) # NOQA: E501
94
98
 
@@ -98,7 +102,7 @@ git_init = y
98
102
  obj=context.obj,
99
103
  )
100
104
  assert (
101
- u"./bin/test --test src/collective/todo/tests/test_robot.py --package collective.todo"
105
+ "./bin/test --test src/collective/todo/tests/test_robot.py --package collective.todo"
102
106
  in test_command_result_t_s.output
103
107
  ) # NOQA: E501
104
108
 
@@ -112,7 +116,7 @@ git_init = y
112
116
  obj=context.obj,
113
117
  )
114
118
  assert (
115
- u"./bin/test --test src/collective/todo/tests/test_robot.py --package collective.todo --all"
119
+ "./bin/test --test src/collective/todo/tests/test_robot.py --package collective.todo --all"
116
120
  in test_command_result.output
117
121
  ) # NOQA: E501
118
122
 
@@ -142,7 +146,7 @@ git_init = y
142
146
  with open("bobtemplate.cfg", "w") as f:
143
147
  f.write(template)
144
148
  result = subprocess.check_output([plonecli_bin, "build"], cwd=target_path)
145
- assert u"\nRUN: python3 -m venv venv" in result.decode()
149
+ assert "\nRUN: python3 -m venv venv" in result.decode()
146
150
 
147
151
 
148
152
  @pytest.mark.skipif(sys.version_info < (3, 7), reason="requires explicitly python3.7")
@@ -171,9 +175,10 @@ python = python3
171
175
  f.write(template)
172
176
 
173
177
  result = subprocess.check_output(
174
- [plonecli_bin, "build", "-p", "python3"], cwd=target_path,
178
+ [plonecli_bin, "build", "-p", "python3"],
179
+ cwd=target_path,
175
180
  )
176
- assert u"\nRUN: python3 -m venv venv" in result.decode()
181
+ assert "\nRUN: python3 -m venv venv" in result.decode()
177
182
 
178
183
 
179
184
  @pytest.mark.skipif(sys.version_info < (3, 0), reason="requires python3")
@@ -203,32 +208,3 @@ python = python3
203
208
 
204
209
  result = subprocess.check_output([plonecli_bin, "build"], cwd=target_path)
205
210
  assert "\nRUN: python3 -m venv venv" in result.decode()
206
-
207
-
208
- @pytest.mark.skipif(sys.version_info < (3, 0), reason="requires python3")
209
- def test_plonecli_build_target_py27(tmpdir, plonecli_bin):
210
- target_path = tmpdir.strpath
211
- os.chdir(target_path)
212
- template = """
213
- setuptools==40.8.0
214
- zc.buildout==2.13.1
215
- """
216
- with open("requirements.txt", "w") as f:
217
- f.write(template)
218
-
219
- template = """[buildout]
220
- parts =
221
- """
222
- with open("buildout.cfg", "w") as f:
223
- f.write(template)
224
-
225
- template = """[main]
226
- version = 5.2.2
227
- template = plone_addon
228
- python = python2.7
229
- """
230
- with open("bobtemplate.cfg", "w") as f:
231
- f.write(template)
232
-
233
- result = subprocess.check_output([plonecli_bin, "build"], cwd=target_path)
234
- assert "\nRUN: virtualenv -p python2.7 venv" in result.decode()
@@ -1,5 +1,4 @@
1
1
  #!/usr/bin/env python
2
- # -*- coding: utf-8 -*-
3
2
 
4
3
  """Tests for `plonecli` package."""
5
4
 
@@ -16,14 +15,14 @@ def test_list_templates(tmpdir):
16
15
  os.chdir(tmpdir.strpath)
17
16
  reg = TemplateRegistry()
18
17
  template_str = reg.list_templates()
19
- assert '- buildout' in template_str
20
- assert '- addon' in template_str
21
- assert '- theme' in template_str
22
- assert '- content_type' in template_str
18
+ assert "- buildout" in template_str
19
+ assert "- addon" in template_str
20
+ assert "- theme" in template_str
21
+ assert "- content_type" in template_str
23
22
 
24
23
 
25
24
  def test_get_package_root(tmpdir):
26
- target_dir = tmpdir.strpath + '/collective.foo'
25
+ target_dir = tmpdir.strpath + "/collective.foo"
27
26
  os.mkdir(target_dir)
28
27
 
29
28
  package_root = get_package_root()
@@ -34,7 +33,7 @@ def test_get_package_root(tmpdir):
34
33
  check=True
35
34
 
36
35
  """
37
- with open(os.path.join(target_dir + '/bobtemplate.cfg'), 'w') as f:
36
+ with open(os.path.join(target_dir + "/bobtemplate.cfg"), "w") as f:
38
37
  f.write(template)
39
38
 
40
39
  package_root = get_package_root()
@@ -48,7 +47,7 @@ check=True
48
47
  template=plone_addon
49
48
  version=5.1-latest
50
49
  """
51
- with open(os.path.join(target_dir + '/bobtemplate.cfg'), 'w') as f:
50
+ with open(os.path.join(target_dir + "/bobtemplate.cfg"), "w") as f:
52
51
  f.write(template)
53
52
 
54
53
  package_root = get_package_root()
@@ -56,7 +55,7 @@ version=5.1-latest
56
55
 
57
56
 
58
57
  def test_bob_config(tmpdir):
59
- target_dir = tmpdir.strpath + '/collective.foo'
58
+ target_dir = tmpdir.strpath + "/collective.foo"
60
59
  os.mkdir(target_dir)
61
60
  os.chdir(target_dir)
62
61
  template = """[main]
@@ -64,16 +63,15 @@ template=plone_addon
64
63
  version=5.1-latest
65
64
  python=python2.7
66
65
  """
67
- with open(os.path.join(target_dir + '/bobtemplate.cfg'), 'w') as f:
66
+ with open(os.path.join(target_dir + "/bobtemplate.cfg"), "w") as f:
68
67
  f.write(template)
69
68
  reg = TemplateRegistry()
70
69
  bob_config = read_bob_config(reg.root_folder)
71
- assert bob_config.python == 'python2.7'
70
+ assert bob_config.python == "python2.7"
72
71
 
73
72
 
74
73
  def test_get_subtemplates(tmpdir):
75
- """ test get_templates inside of a package
76
- """
74
+ """test get_templates inside of a package"""
77
75
  template = """[check-manifest]
78
76
  check=True
79
77
 
@@ -81,33 +79,30 @@ check=True
81
79
  template=plone_addon
82
80
  version=5.1-latest
83
81
  """
84
- target_dir = tmpdir.strpath + '/collective.foo'
82
+ target_dir = tmpdir.strpath + "/collective.foo"
85
83
  os.mkdir(target_dir)
86
- with open(os.path.join(target_dir + '/bobtemplate.cfg'), 'w') as f:
84
+ with open(os.path.join(target_dir + "/bobtemplate.cfg"), "w") as f:
87
85
  f.write(template)
88
86
  os.chdir(target_dir)
89
87
  reg = TemplateRegistry()
90
88
  templates = reg.get_templates()
91
- assert 'content_type' in templates
92
- assert 'theme' in templates
93
- assert 'vocabulary' in templates
89
+ assert "content_type" in templates
90
+ assert "theme" in templates
91
+ assert "vocabulary" in templates
94
92
 
95
93
 
96
94
  def test_get_templates(tmpdir):
97
- """ test get_templates outside of a package
98
- """
95
+ """test get_templates outside of a package"""
99
96
  os.chdir(tmpdir.strpath)
100
97
  reg = TemplateRegistry()
101
98
  templates = reg.get_templates()
102
- assert 'addon' in templates
103
- assert 'theme_package' in templates
104
- assert 'buildout' in templates
99
+ assert "addon" in templates
100
+ assert "buildout" in templates
105
101
 
106
102
 
107
103
  def test_resolve_template_name(tmpdir):
108
- """ test resolving template names from plonecli alias
109
- """
110
- plonecli_alias = 'addon'
104
+ """test resolving template names from plonecli alias"""
105
+ plonecli_alias = "addon"
111
106
  reg = TemplateRegistry()
112
107
  template_name = reg.resolve_template_name(plonecli_alias)
113
- assert 'bobtemplates.plone:addon' == template_name
108
+ assert "bobtemplates.plone:addon" == template_name
@@ -1,16 +1,17 @@
1
1
  [tox]
2
2
  envlist =
3
- {py36,py37,py38},
4
- {lint-py36,lint-py37,lint-py38},
3
+ {py311,py312,py313,py314},
4
+ {lint-py311,lint-py312,lint-py313,lint-py314},
5
5
  coverage-report,
6
6
 
7
7
  skip_missing_interpreters = True
8
8
 
9
9
  [travis]
10
10
  python =
11
- 3.6: py36
12
- 3.7: py37
13
- 3.8: py38
11
+ 3.11: py311
12
+ 3.12: py312
13
+ 3.13: py313
14
+ 3.14: py314
14
15
 
15
16
 
16
17
  [testenv]
@@ -19,9 +20,10 @@ extras =
19
20
  test
20
21
 
21
22
  basepython:
22
- py36: python3.6
23
- py37: python3.7
24
- py38: python3.8
23
+ py311: python3.11
24
+ py312: python3.12
25
+ py313: python3.13
26
+ py314: python3.14
25
27
  # pypy: pypy
26
28
 
27
29
  commands =
@@ -46,12 +48,12 @@ deps =
46
48
  pytest-mock
47
49
  pytest-html
48
50
 
49
- whitelist_externals =
51
+ allowlist_externals =
50
52
  mkdir
51
53
 
52
54
  [testenv:coverage-report]
53
55
  usedevelop = True
54
- basepython = python3.7
56
+ basepython = python3.13
55
57
  deps =
56
58
  coverage
57
59
 
@@ -68,7 +70,7 @@ commands =
68
70
  coverage xml
69
71
 
70
72
  [testenv:isort-apply]
71
- basepython = python3.7
73
+ basepython = python3.13
72
74
  deps =
73
75
  isort
74
76
 
@@ -76,7 +78,7 @@ commands =
76
78
  isort {toxinidir}/plonecli setup.py tests
77
79
 
78
80
  [testenv:autopep8]
79
- basepython = python3.7
81
+ basepython = python3.13
80
82
  skip_install = true
81
83
  deps =
82
84
  autopep8
@@ -107,7 +109,6 @@ deps =
107
109
  flake8-quotes
108
110
  flake8-string-format
109
111
  flake8-todo
110
- flake8_strict
111
112
 
112
113
  commands =
113
114
  mkdir -p {toxinidir}/_build/reports/flake8
@@ -118,22 +119,29 @@ commands =
118
119
  whitelist_externals =
119
120
  mkdir
120
121
 
121
- [testenv:lint-py36]
122
- basepython = python3.6
122
+ [testenv:lint-py311]
123
+ basepython = python3.11
124
+ skip_install = true
125
+ deps = {[lint]deps}
126
+ commands = {[lint]commands}
127
+ whitelist_externals = {[lint]whitelist_externals}
128
+
129
+ [testenv:lint-py312]
130
+ basepython = python3.12
123
131
  skip_install = true
124
132
  deps = {[lint]deps}
125
133
  commands = {[lint]commands}
126
134
  whitelist_externals = {[lint]whitelist_externals}
127
135
 
128
- [testenv:lint-py37]
129
- basepython = python3.7
136
+ [testenv:lint-py313]
137
+ basepython = python3.13
130
138
  skip_install = true
131
139
  deps = {[lint]deps}
132
140
  commands = {[lint]commands}
133
141
  whitelist_externals = {[lint]whitelist_externals}
134
142
 
135
- [testenv:lint-py38]
136
- basepython = python3.8
143
+ [testenv:lint-py314]
144
+ basepython = python3.14
137
145
  skip_install = true
138
146
  deps = {[lint]deps}
139
147
  commands = {[lint]commands}
@@ -1,13 +0,0 @@
1
- # -*- coding: utf-8 -*-
2
-
3
- import os
4
- import pytest
5
- import sys
6
-
7
-
8
- @pytest.fixture(scope='module')
9
- def plonecli_bin():
10
- bin_path = os.path.abspath(os.path.dirname(sys.argv[0]))
11
- plonecli_bin = bin_path + '/plonecli'
12
- print('plonebin path: ' + plonecli_bin)
13
- yield plonecli_bin
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes