Metadata-Version: 2.4
Name: efs-cli
Version: 1.2.1
Summary: EepyFileServer API CLI written in Python
Author: maxie
License-Expression: MIT
Project-URL: Homepage, https://codeberg.org/maxeepy/eepyfileserver-cli
Project-URL: Issues, https://codeberg.org/maxeepy/eepyfileserver-cli/issues
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Classifier: Operating System :: POSIX :: Linux
Requires-Python: >=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: requests>=2.30
Requires-Dist: efs-wrapper>=1.1.0
Dynamic: license-file

# efs-cli (formerly eepyfileserver-cli)

command line interface for eepyfileserver written in python

## prerequisites

- python 3.10 (3.12+ recommended)
- [`eepyfileserver`](https://codeberg.org/maxeepy/eepyfileserver) 1.1.0-alpha (or later for some features, such as users)

## install

`pip install efs-cli`

## usage

### log in to an instance

```bash
#login fully (lets you upload and download files)
#password is saved in PLAIN TEXT
efs-cli auth "https://example.com" "password123" --custom-api-path (optional) "/meow/v123"

#login only using the url (lets you download PUBLIC files)
efs-cli auth  "https://example.com"

efs-cli login ...
```

### see and edit your configs

cli config

```bash
efs-cli config
efs-cli config --reset # resets your entire config

efs-cli conf
efs-cli cli-config
```

efs config

```bash
efs-cli efs-config
efs-cli efs-conf
```

### view version

```bash
efs-cli version
efs-cli ver
```

### view instance information

```bash
efs-cli instance
efs-cli info
```

### list files

```bash
efs-cli list
efs-cli ls
efs-cli files
```

### view file/directory metadata

```bash
efs-cli metadata <path> --public (optional) # uses public url
efs-cli meta ...
```

### edit a file

```bash
efs-cli edit <file_path>
```

### get a url for a file

```bash
efs-cli url-for <file_path> --public (optional) --check-if-exists (optional) # --public uses public url, --check-if-exists checks if the file exists on efs
efs-cli url ...
```

### download a file

```bash
efs-cli download /example.txt /home/maxeepy/Downloads/example.txt --public (optional) # uses public url
efs-cli get ...
efs-cli d ...
```

### upload a file

```bash
efs-cli upload /home/maxeepy/Downloads/example.txt /example.txt
efs-cli post ...
efs-cli up ...
efs-cli put ...
```

### overwrite a file

```bash
efs-cli overwrite /home/maxeepy/Downloads/example.txt /example.txt
efs-cli over ...
```

### delete a file

```bash
efs-cli delete /example.txt
efs-cli remove ...
efs-cli rm ...
```

### read a file

```bash
efs-cli read /example.txt
efs-cli read /example.txt --no-less # doesn't use less
efs-cli cat ...
```

### list users

```bash
efs-cli users
efs-cli listusers
efs-cli lsu
```

### add a user

```bash
efs-cli adduser dir123 "rw" # or "ro"
efs-cli auser ...
efs-cli au ...
```

### change a user

```bash
efs-cli changeuser efskey_123 dir123 "rw" # or "ro"
efs-cli chuser ...
efs-cli chu ...
```

### remove a user

```bash
efs-cli removeuser efskey_123 --remove-dir (optional) # removes the user directory if set
efs-cli rmuser ...
efs-cli ru ...
```
