Move credentials printing to info command
MODIFY
plextraktsync/commands/info.py
plextraktsync/commands/info.py
@@ -25,6 +25,10 @@ def info():
print(f"Config Dir: {config_dir}")
print(f"Log Dir: {log_dir}")
+ config = factory.config()
+ print(f"Plex username: {config['PLEX_USERNAME']}")
+ print(f"Trakt username: {config['TRAKT_USERNAME']}")
+
plex = factory.plex_api()
print(f"Plex Server version: {plex.version}, updated at: {plex.updated_at}")
print(f"Enabled {len(plex.library_sections)} libraries in Plex Server: {plex.library_section_names}")

MODIFY
plextraktsync/commands/sync.py
plextraktsync/commands/sync.py
@@ -74,10 +74,7 @@ def sync(
"""
logger.info(f"PlexTraktSync [{version()}]")
-
ensure_login()
- CONFIG = factory.config()
- logger.info(f"Syncing with Plex {CONFIG['PLEX_USERNAME']} and Trakt {CONFIG['TRAKT_USERNAME']}")
movies = sync_option in ["all", "movies"]
shows = sync_option in ["all", "tv", "shows"]

Move credentials printing to info command