- Refactored string formatting in various files to use consistent double quotes. - Improved readability by adding newlines in function definitions and method calls. - Cleaned up unnecessary imports and ensured proper spacing for better code clarity. - Updated management commands and context processors for consistent formatting. - Enhanced the overall maintainability of the codebase by adhering to PEP 8 guidelines. - Applied Ruff linting and formatting
27 lines
785 B
Python
Executable file
27 lines
785 B
Python
Executable file
#!/usr/bin/env -S uv run
|
|
"""Django's command-line utility for administrative tasks."""
|
|
|
|
import os
|
|
import sys
|
|
|
|
|
|
def main():
|
|
"""Run administrative tasks."""
|
|
os.environ.setdefault(
|
|
"DJANGO_SETTINGS_MODULE", "pkmntrade_club.django_project.settings"
|
|
)
|
|
sys.path.append(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
|
|
|
|
try:
|
|
from django.core.management import execute_from_command_line
|
|
except ImportError as exc:
|
|
raise ImportError(
|
|
"Couldn't import Django. Are you sure it's installed and "
|
|
"available on your PYTHONPATH environment variable? Did you "
|
|
"forget to activate a virtual environment?"
|
|
) from exc
|
|
execute_from_command_line(sys.argv)
|
|
|
|
|
|
if __name__ == "__main__":
|
|
main()
|