mirror of
https://github.com/Aider-AI/aider.git
synced 2025-05-20 12:24:59 +00:00
style: Run linter on clean_metadata.py
This commit is contained in:
parent
226108d05d
commit
ce1266be68
1 changed files with 8 additions and 6 deletions
|
@ -84,10 +84,12 @@ def main():
|
||||||
print("\n" + "=" * 40)
|
print("\n" + "=" * 40)
|
||||||
|
|
||||||
# Ask user if they want to remove the entry from aider's metadata
|
# Ask user if they want to remove the entry from aider's metadata
|
||||||
response = input(
|
response = (
|
||||||
f"Remove '{key}' from aider/resources/model-metadata.json? (y/N): "
|
input(f"Remove '{key}' from aider/resources/model-metadata.json? (y/N): ")
|
||||||
).strip().lower()
|
.strip()
|
||||||
if response == 'y':
|
.lower()
|
||||||
|
)
|
||||||
|
if response == "y":
|
||||||
keys_to_remove.add(key)
|
keys_to_remove.add(key)
|
||||||
print(f"Marked '{key}' for removal.")
|
print(f"Marked '{key}' for removal.")
|
||||||
else:
|
else:
|
||||||
|
@ -96,7 +98,7 @@ def main():
|
||||||
|
|
||||||
else:
|
else:
|
||||||
print("No common models found between the two files.")
|
print("No common models found between the two files.")
|
||||||
return # Exit if no common keys
|
return # Exit if no common keys
|
||||||
|
|
||||||
# Remove marked keys after iterating through all common models
|
# Remove marked keys after iterating through all common models
|
||||||
if keys_to_remove:
|
if keys_to_remove:
|
||||||
|
@ -121,7 +123,7 @@ def main():
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
print(f"\nError writing updated data to {aider_path}: {e}")
|
print(f"\nError writing updated data to {aider_path}: {e}")
|
||||||
else:
|
else:
|
||||||
print("\nNo entries were actually removed (perhaps they were already gone?).")
|
print("\nNo entries were actually removed (perhaps they were already gone?).")
|
||||||
else:
|
else:
|
||||||
print("\nNo entries marked for removal.")
|
print("\nNo entries marked for removal.")
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue