32 lines
696 B
Python
32 lines
696 B
Python
#!/usr/bin/env python3
|
|
"""Transmutate — Media Conversion GUI.
|
|
|
|
Usage:
|
|
python transmutate.py <path/to/image|video|audio>
|
|
|
|
Opens a CustomTkinter GUI for converting the specified file.
|
|
"""
|
|
|
|
import sys
|
|
import os
|
|
from transmutate_app.gui import open_file
|
|
|
|
|
|
def main():
|
|
"""CLI entry point: validate arguments and open the GUI."""
|
|
if len(sys.argv) < 2:
|
|
print("Usage: python transmutate.py <path/to/image|video|audio>")
|
|
sys.exit(1)
|
|
|
|
filepath = os.path.abspath(sys.argv[1])
|
|
|
|
if not os.path.isfile(filepath):
|
|
print(f"Error: File does not exist: {filepath}", file=sys.stderr)
|
|
sys.exit(1)
|
|
|
|
open_file(filepath)
|
|
|
|
|
|
if __name__ == "__main__":
|
|
main()
|