docs: def files():
      """Load files."""
      srcroot = dirname(dirname(__file__))
      d = current_app.config['DATADIR']
      if exists(d):
          shutil.rmtree(d)
      makedirs(d)
  
      # Clear data
      Part.query.delete()
      MultipartObject.query.delete()
      ObjectVersion.query.delete()
      Bucket.query.delete()
      FileInstance.query.delete()
      Location.query.delete()
      db.session.commit()
  
      # Create location
      loc = Location(name='local', uri=d, default=True)
      db.session.add(loc)
      db.session.commit()
  
      # Bucket 0
      b1 = Bucket.create(loc)
      b1.id = '00000000-0000-0000-0000-000000000000'
      for f in ['README.rst', 'LICENSE']:
          with open(join(srcroot, f), 'rb') as fp:
              ObjectVersion.create(b1, f, stream=fp)
  
      # Bucket 1
      b2 = Bucket.create(loc)
      b2.id = '11111111-1111-1111-1111-111111111111'
      k = 'AUTHORS.rst'
      with open(join(srcroot, 'CHANGES.rst'), 'rb') as fp:
          ObjectVersion.create(b2, k, stream=fp)
      with open(join(srcroot, 'AUTHORS.rst'), 'rb') as fp:
          ObjectVersion.create(b2, k, stream=fp)
  
      k = 'RELEASE-NOTES.rst'
      with open(join(srcroot, 'RELEASE-NOTES.rst'), 'rb') as fp:
          ObjectVersion.create(b2, k, stream=fp)
      with open(join(srcroot, 'CHANGES.rst'), 'rb') as fp:
          ObjectVersion.create(b2, k, stream=fp)
      ObjectVersion.delete(b2.id, k)
  
      # Bucket 2
      b2 = Bucket.create(loc)
      b2.id = '22222222-2222-2222-2222-222222222222'
  
      db.session.commit()