📋
Pysettings-Manager
  • Home
  • Save
  • Load
  • Config File Exists
Powered by GitBook
On this page
  • Parameters
  • Returns
  • Example

Config File Exists

config_file_exists function

Check whether a configuration file exists.

Parameters

  • config_file (str): The file to check for existence.

Returns

  • bool: True if the file exists, False if it does not.

Example

import pysettings_manager as pysm
exists = pysm.config_file_exists("settings.json")
if exists:
    print("Settings file found")
else:
    print("Settings file not found")
PreviousLoad

Last updated 2 years ago