diff --git a/npmextra.json b/npmextra.json index 80a8bcb..4722c14 100644 --- a/npmextra.json +++ b/npmextra.json @@ -8,7 +8,7 @@ "githost": "code.foss.global", "gitscope": "push.rocks", "gitrepo": "smartbucket", - "description": "A TypeScript library that offers simple, cloud-independent object storage with features like bucket creation, file management, and directory management.", + "description": "A TypeScript library for cloud-independent object storage, providing features like bucket creation, file and directory management, and data streaming.", "npmPackagename": "@push.rocks/smartbucket", "license": "MIT", "keywords": [ @@ -26,7 +26,12 @@ "unified storage", "buffer handling", "access key", - "secret key" + "secret key", + "metadata", + "file locking", + "file streaming", + "directory listing", + "cloud agnostic" ] } }, diff --git a/package.json b/package.json index e6fa930..3a345e5 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "@push.rocks/smartbucket", "version": "3.0.5", - "description": "A TypeScript library that offers simple, cloud-independent object storage with features like bucket creation, file management, and directory management.", + "description": "A TypeScript library for cloud-independent object storage, providing features like bucket creation, file and directory management, and data streaming.", "main": "dist_ts/index.js", "typings": "dist_ts/index.d.ts", "type": "module", @@ -58,6 +58,11 @@ "unified storage", "buffer handling", "access key", - "secret key" + "secret key", + "metadata", + "file locking", + "file streaming", + "directory listing", + "cloud agnostic" ] -} +} \ No newline at end of file diff --git a/readme.md b/readme.md index 7807153..eb9e4dc 100644 --- a/readme.md +++ b/readme.md @@ -1,5 +1,6 @@ # @push.rocks/smartbucket -A TypeScript library for simple cloud independent object storage with support for buckets, directories, and files. + +A TypeScript library that offers simple, cloud-independent object storage with features like bucket creation, file management, and directory management. ## Install @@ -199,12 +200,15 @@ writeFileStream("exampleBucket", "path/to/streamedObject.txt", readable); `@push.rocks/smartbucket` abstracts directories within buckets for easier object management. You can create, list, and delete directories using the `Directory` class. +Here's how to list the contents of a directory: + ```typescript async function listDirectoryContents(bucketName: string, directoryPath: string) { const myBucket: Bucket = await mySmartBucket.getBucketByName(bucketName); if (myBucket) { const baseDirectory: Directory = await myBucket.getBaseDirectory(); const targetDirectory: Directory = await baseDirectory.getSubDirectoryByName(directoryPath); + console.log('Listing directories:'); const directories = await targetDirectory.listDirectories(); directories.forEach(dir => { @@ -304,6 +308,8 @@ Remember, each cloud provider has specific features and limitations. `@push.rock This guide covers the basic to advanced scenarios of using `@push.rocks/smartbucket`. For further details, refer to the API documentation and examples. + + ## License and Legal Information This repository contains open-source code that is licensed under the MIT License. A copy of the MIT License can be found in the [license](license) file within this repository. diff --git a/ts/00_commitinfo_data.ts b/ts/00_commitinfo_data.ts index 8f89296..98f99e8 100644 --- a/ts/00_commitinfo_data.ts +++ b/ts/00_commitinfo_data.ts @@ -3,6 +3,6 @@ */ export const commitinfo = { name: '@push.rocks/smartbucket', - version: '3.0.5', - description: 'A TypeScript library that offers simple, cloud-independent object storage with features like bucket creation, file management, and directory management.' + version: '3.0.6', + description: 'A TypeScript library for cloud-independent object storage, providing features like bucket creation, file and directory management, and data streaming.' }