Check whether file settings.toml exists.
This commit is contained in:
parent
4be8dad823
commit
ee07600546
2 changed files with 8 additions and 4 deletions
|
@ -48,6 +48,10 @@ if __name__ == 'jabbercard.__main__':
|
||||||
|
|
||||||
# Configure settings file
|
# Configure settings file
|
||||||
file_settings = os.path.join(directory_settings, 'settings.toml')
|
file_settings = os.path.join(directory_settings, 'settings.toml')
|
||||||
|
if not os.path.exists(file_settings):
|
||||||
|
directory_configs = os.path.join(directory, 'configs')
|
||||||
|
file_settings_empty = os.path.join(directory_configs, 'settings.toml')
|
||||||
|
shutil.copyfile(file_settings_empty, file_settings)
|
||||||
data_settings = Toml.open_file_toml(file_settings)
|
data_settings = Toml.open_file_toml(file_settings)
|
||||||
|
|
||||||
# Configure account
|
# Configure account
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
# An account to connect FASI to the XMPP network
|
# JabberCard configuration file
|
||||||
|
|
||||||
[account]
|
[account]
|
||||||
alias = "FASI" # Alias
|
alias = "JabberCard" # Alias
|
||||||
xmpp = "" # Jabber ID
|
xmpp = "" # Jabber ID
|
||||||
pass = "" # Password
|
pass = "" # Password
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue