Skip to content

Commit

Permalink
Add docstring example
Browse files Browse the repository at this point in the history
  • Loading branch information
hagenw committed Sep 4, 2024
1 parent c5e6a27 commit 393cff7
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions audbackend/core/backend/minio.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,21 @@ class Minio(Base):
If ``None``,
it requests it by calling :meth:`get_authentication`
Examples:
>>> host = "play.min.io" # playground provided by https://min.io
>>> auth = ("Q3AM3UQ867SPQQA43P2F", "zuf+tfteSlswRu7BJ86wekitnifILbZam1KYY3TG")
>>> repository = "my-data" + audeer.uid()
>>> Minio.create(host, repository, authentication=auth)
>>> file = audeer.touch("file.txt")
>>> backend = Minio(host, repository, authentication=auth)
>>> try:
... with backend:
... backend.put_file(file, "/sub/file.txt")
... backend.ls()
... finally:
... Minio.delete(host, repository, authentication=auth)
['/sub/file.txt']
""" # noqa: E501

def __init__(
Expand Down

0 comments on commit 393cff7

Please sign in to comment.