haraka 0.2.22__py3-none-any.whl → 0.2.24__py3-none-any.whl

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.
@@ -78,29 +78,44 @@ class ResourcePurger:
78
78
  def _purge_unrelated(self, root: Path, spec: PathSpec) -> None:
79
79
  """
80
80
  Walk the project tree; delete every path NOT matched by *spec*.
81
+
82
+ Updated to align with the `test_java_manifest` logic for cleaner organization.
81
83
  """
82
84
 
85
+ # Dictionaries to separate matches and non-matches for logging
86
+ matches = []
87
+ non_matches = []
88
+
89
+ # Walk the project tree to inspect all paths
83
90
  for path in root.rglob("*"):
84
- self._log.debug(f"Scanning path: {path}")
91
+ self._log.debug(f"\nScanning path: {path}")
85
92
  rel = path.relative_to(root).as_posix()
86
93
  self._log.debug(f"Relative path for inspection: {rel}")
87
94
 
88
- # Match directory paths explicitly with trailing slash
89
- if path.is_dir() and spec.match_file(f"{rel}/"):
90
- self._log.debug(f"Path matches keep patterns: {rel}/")
91
- self._log.debug(f"Keeping directory: {rel}")
92
- continue
93
-
94
- # Regular file matching
95
+ # Match file against the PathSpec
95
96
  if spec.match_file(rel):
96
97
  self._log.debug(f"Path matches keep patterns: {rel}")
97
- self._log.debug(f"Keeping file: {rel}")
98
+ matches.append(path) # Collect paths to keep
98
99
  continue
99
100
 
100
- # If path didn't match, delete
101
+ # Non-matching paths: collect and delete
102
+ self._log.debug(f"Path does not match keep patterns: {rel}")
103
+ non_matches.append(path)
101
104
  if path.is_dir():
102
105
  self._f.remove_dir(path)
103
106
  self._log.debug(f"Deleted directory: {path}")
104
107
  else:
105
108
  self._f.remove_file(path)
106
109
  self._log.debug(f"Deleted file: {path}")
110
+
111
+ # Print results cleanly for debugging/logging purposes
112
+ self._log.info("\nMATCHED PATHS:")
113
+ self._log.info("=" * 80)
114
+ for match in matches:
115
+ self._log.info(f"✅ {match}")
116
+
117
+ self._log.info("\nNOT MATCHED PATHS:")
118
+ self._log.info("=" * 80)
119
+ for non_match in non_matches:
120
+ self._log.info(f"❌ {non_match}")
121
+
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: haraka
3
- Version: 0.2.22
3
+ Version: 0.2.24
4
4
  Summary: Reusable post-generation helper for Cookiecutter micro-service templates
5
5
  Author-email: Will Burks <will@example.com>
6
6
  License: MIT
@@ -17,7 +17,7 @@ haraka/post_gen/service/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG
17
17
  haraka/post_gen/service/command.py,sha256=yvEzW9rMSXWeQ_2DXuQNtGH6sRuZnK6viMud-amFQXw,2348
18
18
  haraka/post_gen/service/fileOps/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
19
19
  haraka/post_gen/service/fileOps/files.py,sha256=Jm_0bhvVnNqSPGKQ2RnMpx8JLV74M-IXMmwly9fpmVw,3020
20
- haraka/post_gen/service/fileOps/purge.py,sha256=yMdjWPBj_k06gDw9hCoZmtv69KwuZdSROABPUNl1lVA,3911
20
+ haraka/post_gen/service/fileOps/purge.py,sha256=_PXMqui27DTwB5uh01vzb7g4vOUDiRSgQXFa8RiGyfg,4402
21
21
  haraka/post_gen/service/gitOps/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
22
22
  haraka/post_gen/service/gitOps/gitops.py,sha256=clWny1m9qB4yr8asba8JwqBjewlMVsJUmIOCLtAL8RI,4052
23
23
  haraka/utils/__init__.py,sha256=3Cp4u0dyAGcmqes-tIr95KFsNsJx5Ji5Yzkto9546Hs,168
@@ -29,7 +29,7 @@ haraka/utils/manifests/go-grpc-gateway-buf.yml,sha256=47DEQpj8HBSa-_TImW-5JCeuQe
29
29
  haraka/utils/manifests/go-grpc-protoc.yml,sha256=OaQlfW_S_OguhW_UcpBVdqdEtUMlg-SrT4bqLhQrY7Y,936
30
30
  haraka/utils/manifests/java-springboot.yml,sha256=WzcaStDgzyWmBhV2TUiYEkxHhYwydN9ww2yjZYyhSmw,929
31
31
  haraka/utils/manifests/python-fastapi.yml,sha256=nhO6S9j_r-S10nM8nuw7PtR247-ePhBXHvaXg74CjWw,922
32
- haraka-0.2.22.dist-info/METADATA,sha256=oc3A_fN_HikrFUOFQkJxzGkyLk0-ds9rzjP03soOdHk,579
33
- haraka-0.2.22.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
34
- haraka-0.2.22.dist-info/top_level.txt,sha256=1khpwypLKWoklVd_CgFiwAfcctVSXRoRPc3BI9lyIXo,7
35
- haraka-0.2.22.dist-info/RECORD,,
32
+ haraka-0.2.24.dist-info/METADATA,sha256=f_EduVFavefmgRKkUvkvuCqbexvqBnp25yB_CeLQtQQ,579
33
+ haraka-0.2.24.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
34
+ haraka-0.2.24.dist-info/top_level.txt,sha256=1khpwypLKWoklVd_CgFiwAfcctVSXRoRPc3BI9lyIXo,7
35
+ haraka-0.2.24.dist-info/RECORD,,