27 lines
558 B
Python
27 lines
558 B
Python
from __future__ import annotations
|
|
|
|
import sys
|
|
from pathlib import Path
|
|
|
|
from PyQt6.QtWidgets import QApplication
|
|
|
|
from photo_sorter.core.config_manager import ConfigManager
|
|
from photo_sorter.ui.main_window import MainWindow
|
|
|
|
|
|
def main() -> int:
|
|
app = QApplication(sys.argv)
|
|
|
|
base_dir = Path(__file__).resolve().parent
|
|
config_path = base_dir / "config.json"
|
|
config_manager = ConfigManager(config_path)
|
|
|
|
window = MainWindow(config_manager)
|
|
window.show()
|
|
|
|
return app.exec()
|
|
|
|
|
|
if __name__ == "__main__":
|
|
raise SystemExit(main())
|