mirror of
https://github.com/asciinema/asciinema.git
synced 2025-12-16 11:48:13 +01:00
Write config file only if it doesn't exist
This commit is contained in:
@@ -408,8 +408,9 @@ def main():
|
|||||||
if not os.path.isdir(BASE_DIR):
|
if not os.path.isdir(BASE_DIR):
|
||||||
os.mkdir(BASE_DIR)
|
os.mkdir(BASE_DIR)
|
||||||
|
|
||||||
with open(cfg_file, 'wb') as configfile:
|
if not os.path.exists(cfg_file):
|
||||||
config.write(configfile)
|
with open(cfg_file, 'wb') as configfile:
|
||||||
|
config.write(configfile)
|
||||||
|
|
||||||
api_url = os.environ.get('ASCII_IO_API_URL', api_url)
|
api_url = os.environ.get('ASCII_IO_API_URL', api_url)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user