Metadata-Version: 2.4
Name: osskit
Version: 0.6.0
Summary: A vendor-neutral command line toolkit for S3-compatible object storage
Author: osskit contributors
License: MIT
Classifier: Development Status :: 3 - Alpha
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Topic :: System :: Archiving :: Backup
Requires-Python: >=3.7
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: click>=8.0
Dynamic: license-file

# osskit

`osskit` is a small command-line toolkit for S3-compatible object storage. It
uses the locally installed [`s3cmd`](https://s3tools.org/s3cmd) executable and
supports common bucket, object, and model transfer operations.

## Configuration

Credentials are read from environment variables and are never written to
`.s3cfg` or placed in the `s3cmd` command line:

```bash
export OSS_HOST="https://oss-cn-hangzhou.aliyuncs.com"
export OSS_AK="your-access-key"
export OSS_SK="your-secret-key"
export OSS_CHUNK_SIZE="1024"  # optional, MB
```

`s3cmd` must be installed separately. Check the environment with:

```bash
osskit config
```

## Examples

```bash
osskit ls
osskit ls /bucket/path -r
osskit get /bucket/path/file.wav
osskit get s3://bucket/path/file.wav ./
osskit get http://bucket.nx4oss.ctyunxs.cn/path/file.wav ./
osskit put local.wav /bucket/path/
osskit share s3://bucket/path/file.wav --expires +86400
osskit get /bucket/path -r
osskit get /bucket/path ./local -r --skip --continue
```

For downloads, `--skip` passes `--skip-existing` to `s3cmd`, while
`--continue` resumes a partial local file. They can be used together to skip
complete files and continue partial files.

For HTTP and HTTPS object URLs, the hostname must use the virtual-hosted style
`<bucket>.<OSS_HOST>`. `osskit` converts the URL to the equivalent S3 URI before
calling `s3cmd`; URL query parameters and fragments are ignored.

`share` creates a temporary signed URL for one object only. It does not change
the object's ACL. The default link lifetime is 24 hours.

## License

MIT
