Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
r350178982 committed Apr 12, 2024
1 parent 74e7c2c commit e2f9b16
Showing 1 changed file with 13 additions and 13 deletions.
26 changes: 13 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -160,25 +160,25 @@ seafile_api.delete_repo(repo_id)



## File / Dir operation
## File / folder operation

You can use Repo object to manipulate files and directories.
You can use Repo object to manipulate files and folders.

### List dir
### List folder items

```python
repo.list_dir(dir_path = '/')
```

Return the list of items in plain objects showed in a specific dir.
Return the list of items in plain objects showed in a specific folder.

**Example:**

```python
repo.list_dir('/root')
```

A list of dir items in plain objects is returned:
A list of folder items in plain objects is returned:

```
[{
Expand Down Expand Up @@ -210,21 +210,21 @@ A list of dir items in plain objects is returned:
}, ...]
```

### Create a dir
### Create a folder

```python
repo.create_dir(path)
```

Create a directory and return a plain object.
Create a folder and return a plain object.

**Example:**

```python
repo.create_dir('/A new')
```

A dir in plain object is returned:
A folder in plain object is returned

```
{
Expand All @@ -237,21 +237,21 @@ A dir in plain object is returned:
}
```

### Rename a dir
### Rename a folder

```python
repo.rename_dir(path, new_name)
```

Change the dir name and return a plain object.
Change the folder name and return a plain object.

**Example:**

```python
repo.rename_dir('/A new', 'new file')
```

A dir in plain object is returned:
A folder in plain object is returned:

```
{
Expand All @@ -264,13 +264,13 @@ A dir in plain object is returned:
}
```

### Delete dir
### Delete a folder

```python
repo.delete_dir(path)
```

A dir in a specific path will be deleted.
A folder in a specific path will be deleted.

**Example:**

Expand Down

0 comments on commit e2f9b16

Please sign in to comment.