Autodetect json file name
Detect if file name ends on '.json'. If this is the case and the name was entered manually the json dump will be saved.pull/23/head
parent
2c23bc0604
commit
6ccea1e719
|
@ -130,6 +130,7 @@ def main():
|
|||
# If they didn't give a filename, then just prompt them. (They probably just double-clicked.)
|
||||
while not args.file:
|
||||
args.file = input('Enter a file name (e.g. playlists.txt): ')
|
||||
args.format = args.file.split('.')[-1]
|
||||
|
||||
# Log into the Spotify API.
|
||||
if args.token:
|
||||
|
|
Loading…
Reference in New Issue