fix(competitor-analysis): final migration fixes and documentation updates
This commit is contained in:
19
patch_cleaning_release.py
Normal file
19
patch_cleaning_release.py
Normal file
@@ -0,0 +1,19 @@
|
||||
import sys
|
||||
|
||||
with open('fotograf-de-scraper/frontend/src/App.tsx', 'r') as f:
|
||||
content = f.read()
|
||||
|
||||
new_cleaning = ".replace(/\\(JOB\\d+\\)/gi, '').replace(/Kindergarten/gi, '').replace(/\\d{4}/g, '').replace(/\\s+/g, ' ').trim()"
|
||||
|
||||
old_pattern = """.replace(/\\(JOB\\d+\\)\\s*/, '')
|
||||
.replace(/Kindergarten\\s+/gi, '') // Remove "Kindergarten" prefix
|
||||
.replace(/\\s+\\d{4}$/, '') // Remove year at the end
|
||||
.trim()"""
|
||||
|
||||
if old_pattern in content:
|
||||
content = content.replace(old_pattern, new_cleaning)
|
||||
with open('fotograf-de-scraper/frontend/src/App.tsx', 'w') as f:
|
||||
f.write(content)
|
||||
print("Cleaning logic updated for release feature")
|
||||
else:
|
||||
print("Old cleaning pattern not found")
|
||||
Reference in New Issue
Block a user