PyProd 0.5.0__tar.gz → 0.6.0__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 (51) hide show
  1. {pyprod-0.5.0 → pyprod-0.6.0}/PKG-INFO +1 -1
  2. {pyprod-0.5.0 → pyprod-0.6.0}/docs/releasenotes.rst +5 -0
  3. pyprod-0.6.0/src/pyprod/__init__.py +1 -0
  4. {pyprod-0.5.0 → pyprod-0.6.0}/src/pyprod/main.py +13 -0
  5. {pyprod-0.5.0 → pyprod-0.6.0}/src/pyprod/prod.py +6 -0
  6. {pyprod-0.5.0 → pyprod-0.6.0}/tests/test_prod.py +1 -1
  7. pyprod-0.5.0/src/pyprod/__init__.py +0 -1
  8. {pyprod-0.5.0 → pyprod-0.6.0}/.github/workflows/publish.yml +0 -0
  9. {pyprod-0.5.0 → pyprod-0.6.0}/.github/workflows/test.yml +0 -0
  10. {pyprod-0.5.0 → pyprod-0.6.0}/.gitignore +0 -0
  11. {pyprod-0.5.0 → pyprod-0.6.0}/LICENSE +0 -0
  12. {pyprod-0.5.0 → pyprod-0.6.0}/README.rst +0 -0
  13. {pyprod-0.5.0 → pyprod-0.6.0}/docs/Makefile +0 -0
  14. {pyprod-0.5.0 → pyprod-0.6.0}/docs/commandline.rst +0 -0
  15. {pyprod-0.5.0 → pyprod-0.6.0}/docs/conf.py +0 -0
  16. {pyprod-0.5.0 → pyprod-0.6.0}/docs/index.rst +0 -0
  17. {pyprod-0.5.0 → pyprod-0.6.0}/docs/make.bat +0 -0
  18. {pyprod-0.5.0 → pyprod-0.6.0}/docs/prodfile.rst +0 -0
  19. {pyprod-0.5.0 → pyprod-0.6.0}/docs/pyprod2.png +0 -0
  20. {pyprod-0.5.0 → pyprod-0.6.0}/docs/quickstart.rst +0 -0
  21. {pyprod-0.5.0 → pyprod-0.6.0}/docs/requirements.txt +0 -0
  22. {pyprod-0.5.0 → pyprod-0.6.0}/pyprod.webp +0 -0
  23. {pyprod-0.5.0 → pyprod-0.6.0}/pyprod2.png +0 -0
  24. {pyprod-0.5.0 → pyprod-0.6.0}/pyproject.toml +0 -0
  25. {pyprod-0.5.0 → pyprod-0.6.0}/samples/build-c/Makefile +0 -0
  26. {pyprod-0.5.0 → pyprod-0.6.0}/samples/build-c/Prodfile.py +0 -0
  27. {pyprod-0.5.0 → pyprod-0.6.0}/samples/build-c/hello.c +0 -0
  28. {pyprod-0.5.0 → pyprod-0.6.0}/samples/build-c/hello.h +0 -0
  29. {pyprod-0.5.0 → pyprod-0.6.0}/samples/build-c/main.c +0 -0
  30. {pyprod-0.5.0 → pyprod-0.6.0}/samples/generate-doc/Prodfile.py +0 -0
  31. {pyprod-0.5.0 → pyprod-0.6.0}/samples/generate-doc/a.txt +0 -0
  32. {pyprod-0.5.0 → pyprod-0.6.0}/samples/generate-doc/b.txt +0 -0
  33. {pyprod-0.5.0 → pyprod-0.6.0}/samples/generate-doc/c.txt +0 -0
  34. {pyprod-0.5.0 → pyprod-0.6.0}/samples/generate-doc/inc1.txt +0 -0
  35. {pyprod-0.5.0 → pyprod-0.6.0}/samples/generate-doc/inc2.txt +0 -0
  36. {pyprod-0.5.0 → pyprod-0.6.0}/samples/md-to-pdf/Prodfile.py +0 -0
  37. {pyprod-0.5.0 → pyprod-0.6.0}/samples/md-to-pdf/doc.md +0 -0
  38. {pyprod-0.5.0 → pyprod-0.6.0}/samples/md-to-pdf/md_to_html.py +0 -0
  39. {pyprod-0.5.0 → pyprod-0.6.0}/samples/md-to-pdf/template.html +0 -0
  40. {pyprod-0.5.0 → pyprod-0.6.0}/samples/s3files/Prodfile.py +0 -0
  41. {pyprod-0.5.0 → pyprod-0.6.0}/samples/s3files/S3TEST.txt +0 -0
  42. {pyprod-0.5.0 → pyprod-0.6.0}/samples/tutorial-1/Prodfile.py +0 -0
  43. {pyprod-0.5.0 → pyprod-0.6.0}/samples/tutorial-2/Prodfile.py +0 -0
  44. {pyprod-0.5.0 → pyprod-0.6.0}/src/pyprod/__main__.py +0 -0
  45. {pyprod-0.5.0 → pyprod-0.6.0}/src/pyprod/utils.py +0 -0
  46. {pyprod-0.5.0 → pyprod-0.6.0}/src/pyprod/venv.py +0 -0
  47. {pyprod-0.5.0 → pyprod-0.6.0}/tests/__init__.py +0 -0
  48. {pyprod-0.5.0 → pyprod-0.6.0}/tests/conftest.py +0 -0
  49. {pyprod-0.5.0 → pyprod-0.6.0}/tests/test_prodfuncs.py +0 -0
  50. {pyprod-0.5.0 → pyprod-0.6.0}/tests/test_rule.py +0 -0
  51. {pyprod-0.5.0 → pyprod-0.6.0}/tests/utils.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: PyProd
3
- Version: 0.5.0
3
+ Version: 0.6.0
4
4
  Summary: PyProd: More Makeable than Make
5
5
  Project-URL: Homepage, https://github.com/atsuoishimoto/pyprod
6
6
  Project-URL: Documentation, https://pyprod.readthedocs.io/en/latest/
@@ -1,6 +1,11 @@
1
1
  Release Notes
2
2
  ================
3
3
 
4
+ 0.6.0 (2025-4-6)
5
+ -----------------------------
6
+
7
+ - Ignore None or falsy values in the ``depends`` and ``uses`` in the rule.
8
+
4
9
  0.5.0 (2025-2-12)
5
10
  -----------------------------
6
11
 
@@ -0,0 +1 @@
1
+ __version__ = "0.6.0"
@@ -53,6 +53,15 @@ parser.add_argument(
53
53
  help="Increase verbosity level (default: 0)",
54
54
  )
55
55
 
56
+ parser.add_argument(
57
+ "-V",
58
+ "--version",
59
+ dest="version",
60
+ action="store_true",
61
+ default=0,
62
+ help="Show version",
63
+ )
64
+
56
65
 
57
66
  parser.add_argument("targets", nargs="*", help="Build targets")
58
67
 
@@ -74,6 +83,10 @@ def init_args(args=None):
74
83
 
75
84
  def main():
76
85
  args = init_args()
86
+ if args.version:
87
+ print(f"PyProd {pyprod.__version__}")
88
+ sys.exit(0)
89
+
77
90
  pyprod.verbose = args.verbose
78
91
  chdir = args.directory
79
92
  if chdir:
@@ -216,6 +216,9 @@ class Rule:
216
216
 
217
217
  self.depends = []
218
218
  for depend in flatten(depends or ()):
219
+ if not depend:
220
+ continue
221
+
219
222
  depend = _name_to_str(depend)
220
223
  _check_pattern_count(depend)
221
224
  _check_wildcard(depend)
@@ -223,6 +226,9 @@ class Rule:
223
226
 
224
227
  self.uses = []
225
228
  for use in flatten(uses or ()):
229
+ if not use:
230
+ continue
231
+
226
232
  use = _name_to_str(use)
227
233
  _check_pattern_count(use)
228
234
  _check_wildcard(use)
@@ -71,7 +71,7 @@ async def test_prod(tmp_path, jobs):
71
71
  p = prod.Prod("Prodfile.py", 4)
72
72
  await p.start(["app.exe"])
73
73
 
74
- assert mtime < (tmp_path / "app.exe").stat().st_mtime
74
+ assert mtime <= (tmp_path / "app.exe").stat().st_mtime
75
75
 
76
76
 
77
77
  @pytest.mark.asyncio
@@ -1 +0,0 @@
1
- __version__ = "0.5.0"
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
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