code: def load_profiles(self):
          
          if not os.path.isfile('tcex.json'):
              msg = 'The tcex.json config file is required.'
              sys.exit(msg)
  
          # create default directories
          self._create_tcex_dirs()
  
          # open tcex.json configuration file
          with open('tcex.json', 'r+') as fh:
              data = json.load(fh)
              if data.get('profiles') is not None:
                  # no longer supporting profiles in tcex.json
                  print(
                      '{}{}Migrating profiles from tcex.json to individual files.'.format(
                          c.Style.BRIGHT, c.Fore.YELLOW
                      )
                  )
  
                  for profile in data.get('profiles') or []:
                      outfile = '{}.json'.format(
                          profile.get('profile_name').replace(' ', '_').lower()
                      )
                      self.profile_write(profile, outfile)
  
                  # remove legacy profile key
                  del data['profiles']
                  data.setdefault('profile_include_dirs', [])
                  if self.profile_dir not in data.get('profile_include_dirs'):
                      data['profile_include_dirs'].append(self.profile_dir)
              fh.seek(0)
              fh.write(json.dumps(data, indent=2, sort_keys=True))
              fh.truncate()
  
          # load includes
          for directory in data.get('profile_include_dirs') or []:
              self.load_profile_include(directory)
docs: Return configuration data.
  
          Load on first access, otherwise return existing data.
  
          .. code-block:: python
  
              self.profiles = {
                  <profile name>: {
                      'data': {},
                      'ij_filename': <filename>,
                      'fqfn': 'tcex.json'
                  }