ultralytics-actions 0.0.76__py3-none-any.whl → 0.0.78__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.
actions/__init__.py CHANGED
@@ -22,4 +22,4 @@
22
22
  # ├── test_summarize_pr.py
23
23
  # └── ...
24
24
 
25
- __version__ = "0.0.76"
25
+ __version__ = "0.0.78"
@@ -29,6 +29,11 @@ COMMENT_MAP = {
29
29
  ".rs": ("// ", "/* ", " */"), # Rust files
30
30
  ".java": ("// ", "/* ", " */"), # Android Java
31
31
  ".kt": ("// ", "/* ", " */"), # Android Kotlin
32
+ # Vue/Nuxt style
33
+ ".vue": ("// ", "/* ", " */"), # Vue single-file components
34
+ # React/Next.js style
35
+ ".jsx": ("// ", "/* ", " */"), # JSX files
36
+ ".tsx": ("// ", "/* ", " */"), # TSX files
32
37
  # CSS style
33
38
  ".css": (None, "/* ", " */"),
34
39
  # HTML/XML style
@@ -64,7 +69,7 @@ IGNORE_PATHS = {
64
69
 
65
70
 
66
71
  def update_file(file_path, prefix, block_start, block_end, base_header):
67
- """Update file with the correct header and proper spacing."""
72
+ """Update file with header and proper spacing, respecting Python docstrings."""
68
73
  try:
69
74
  with open(file_path, encoding="utf-8") as f:
70
75
  lines = f.readlines()
@@ -86,9 +91,7 @@ def update_file(file_path, prefix, block_start, block_end, base_header):
86
91
  # Save original content for comparison
87
92
  original_content = "".join(lines)
88
93
 
89
- # Create two separate line collections:
90
- # 1. prefix_lines: Special first line + header + blank line
91
- # 2. content_lines: The actual file content (excluding header)
94
+ # Create two separate line collections
92
95
  prefix_lines = []
93
96
 
94
97
  # Check for special first line
@@ -103,7 +106,7 @@ def update_file(file_path, prefix, block_start, block_end, base_header):
103
106
  end_idx = min(start_idx + 5, len(lines)) # Look in first few lines
104
107
 
105
108
  for i in range(start_idx, end_idx):
106
- if "Ultralytics " in lines[i]:
109
+ if any(x in lines[i] for x in {"© 2014-", "AGPL-3.0", "CONFIDENTIAL", "Ultralytics 🚀"}):
107
110
  header_index = i
108
111
  break
109
112
 
@@ -127,8 +130,8 @@ def update_file(file_path, prefix, block_start, block_end, base_header):
127
130
  # No special line, content starts at beginning
128
131
  content_lines = lines
129
132
 
130
- # Add blank line before content if first content line isn't already blank
131
- if content_lines and content_lines[0].strip():
133
+ # Add blank line if the first content line isn't blank and isn't a docstring
134
+ if content_lines and content_lines[0].strip() and not content_lines[0].strip().startswith('"""'):
132
135
  prefix_lines.append("\n")
133
136
 
134
137
  # Combine prefix lines and content lines
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: ultralytics-actions
3
- Version: 0.0.76
3
+ Version: 0.0.78
4
4
  Summary: Ultralytics Actions for GitHub automation and PR management.
5
5
  Author-email: Glenn Jocher <glenn.jocher@ultralytics.com>
6
6
  Maintainer-email: Ultralytics <hello@ultralytics.com>
@@ -1,17 +1,17 @@
1
- actions/__init__.py,sha256=2VsR2b1-w7Wy2J616Dd2_o3l0i_QMo4pNRot1Z_geT8,742
1
+ actions/__init__.py,sha256=qdxFRB2m6Cwkly4TbzqDaP94NUVJ7LOrpvT3S6J4rxI,742
2
2
  actions/dispatch_actions.py,sha256=vbA4w_B8vMXMen__ck2WoDsUFCELjXOQbpLzZCmqTXg,4240
3
3
  actions/first_interaction.py,sha256=whphdBrWkcWRt6RgOeK2dUoGq3aBTqttQdokxVjkye4,16309
4
4
  actions/summarize_pr.py,sha256=NCaDSbw4PVoRbPJzji_Ua2HadI2pn7QOE_dy3VK9_cc,10463
5
5
  actions/summarize_release.py,sha256=OncODHx7XsmB-nPf-B1tnxUTcaJx6hM4JAMa9frypzM,7922
6
- actions/update_file_headers.py,sha256=G2fvweDvBuesEkHOzCqlkSSJ3G3iW9aKc1Dd58xASWs,6019
6
+ actions/update_file_headers.py,sha256=w8EZj4mwefz4d-iVeXdDV-1pz_-i9nL6ufq9uEbHRLg,6229
7
7
  actions/update_markdown_code_blocks.py,sha256=9PL7YIQfApRNAa0que2hYHv7umGZTZoHlblesB0xFj4,8587
8
8
  actions/utils/__init__.py,sha256=TXYvhFgDeAnosePM4jfOrEd6PlC7tWC-WMOgCB_T6Tw,728
9
9
  actions/utils/common_utils.py,sha256=2eNwGJFigl9bBXcyWzdr8mr97Lrx7zFKWIFYugZcUJw,11736
10
10
  actions/utils/github_utils.py,sha256=gdObDzOGmoLl8LXJ-fza7Dr2qLKfDsX2HbpcyFBEMtE,10097
11
11
  actions/utils/openai_utils.py,sha256=09kW4K2LOc6KsWz5tijf2Piinhu3PIKPDVkRC3KyIxU,2943
12
- ultralytics_actions-0.0.76.dist-info/licenses/LICENSE,sha256=hIahDEOTzuHCU5J2nd07LWwkLW7Hko4UFO__ffsvB-8,34523
13
- ultralytics_actions-0.0.76.dist-info/METADATA,sha256=CYdGRXK2uY6SPpC-vE0rCAfLyE5Z6hIzarf62JSzR60,11638
14
- ultralytics_actions-0.0.76.dist-info/WHEEL,sha256=DnLRTWE75wApRYVsjgc6wsVswC54sMSJhAEd4xhDpBk,91
15
- ultralytics_actions-0.0.76.dist-info/entry_points.txt,sha256=rvqr6Juj7lCJL1DQLwMmOrA8R2Q8tyR_dvCe0mYuJ8s,441
16
- ultralytics_actions-0.0.76.dist-info/top_level.txt,sha256=5apM5x80QlJcGbACn1v3fkmIuL1-XQCKcItJre7w7Tw,8
17
- ultralytics_actions-0.0.76.dist-info/RECORD,,
12
+ ultralytics_actions-0.0.78.dist-info/licenses/LICENSE,sha256=hIahDEOTzuHCU5J2nd07LWwkLW7Hko4UFO__ffsvB-8,34523
13
+ ultralytics_actions-0.0.78.dist-info/METADATA,sha256=avzPEkegz-SkD5WDDeDICCqPz0oVNiYtlfE_R5c9Brk,11638
14
+ ultralytics_actions-0.0.78.dist-info/WHEEL,sha256=DnLRTWE75wApRYVsjgc6wsVswC54sMSJhAEd4xhDpBk,91
15
+ ultralytics_actions-0.0.78.dist-info/entry_points.txt,sha256=rvqr6Juj7lCJL1DQLwMmOrA8R2Q8tyR_dvCe0mYuJ8s,441
16
+ ultralytics_actions-0.0.78.dist-info/top_level.txt,sha256=5apM5x80QlJcGbACn1v3fkmIuL1-XQCKcItJre7w7Tw,8
17
+ ultralytics_actions-0.0.78.dist-info/RECORD,,