-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtest.py
More file actions
28 lines (25 loc) · 875 Bytes
/
Copy pathtest.py
File metadata and controls
28 lines (25 loc) · 875 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
import os
# Common VLC locations
paths_to_check = [
r'C:\Program Files\VideoLAN\VLC\vlc.exe',
r'C:\Program Files (x86)\VideoLAN\VLC\vlc.exe',
r'C:\VLC\vlc.exe',
os.path.expanduser('~/AppData/Local/Programs/VLC/vlc.exe'),
]
print("🔍 Searching for VLC...")
found = False
for path in paths_to_check:
if os.path.exists(path):
print(f"✅ FOUND VLC at: {path}")
found = True
# Test if it works
try:
import subprocess
result = subprocess.run([path, '--version'], capture_output=True, text=True)
print(f" Version: {result.stdout.splitlines()[0] if result.stdout else 'Unknown'}")
except:
print(" But couldn't run it")
break
if not found:
print("❌ VLC not found in common locations")
print("Please install VLC from: https://www.videolan.org/vlc/")