You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
476 B
17 lines
476 B
import sys
|
|
|
|
sys.path.append("..")
|
|
|
|
import os
|
|
from ssh_config_utils.config_file import ConfigFile
|
|
|
|
base = "./sample_configs"
|
|
write_base = "./write_test"
|
|
for file in os.listdir(base):
|
|
print(file)
|
|
fullpath = os.path.join(base, file)
|
|
with open(fullpath, encoding="utf-8") as read_file:
|
|
config_file = ConfigFile.read_file(read_file)
|
|
|
|
with open(os.path.join(write_base, file), "w", encoding="utf-8") as write_file:
|
|
config_file.write_file(write_file)
|