fix(core): Update dependencies, code style and project config; add pnpm overrides and ignore AI folders

This commit is contained in:
2025-11-20 08:10:17 +00:00
parent f2bf3f1314
commit 871f0e0b78
9 changed files with 2445 additions and 2567 deletions

View File

@@ -3,6 +3,6 @@
*/
export const commitinfo = {
name: '@push.rocks/smarts3',
version: '2.2.6',
version: '2.2.7',
description: 'A Node.js TypeScript package to create a local S3 endpoint for simulating AWS S3 operations using mapped local directories for development and testing purposes.'
}

View File

@@ -8,7 +8,9 @@ export interface ISmarts3ContructorOptions {
export class Smarts3 {
// STATIC
public static async createAndStart(optionsArg: ConstructorParameters<typeof Smarts3>[0]) {
public static async createAndStart(
optionsArg: ConstructorParameters<typeof Smarts3>[0],
) {
const smartS3Instance = new Smarts3(optionsArg);
await smartS3Instance.start();
return smartS3Instance;
@@ -43,7 +45,7 @@ export class Smarts3 {
}
public async getS3Descriptor(
optionsArg?: Partial<plugins.tsclass.storage.IS3Descriptor>
optionsArg?: Partial<plugins.tsclass.storage.IS3Descriptor>,
): Promise<plugins.tsclass.storage.IS3Descriptor> {
return {
...{
@@ -53,12 +55,14 @@ export class Smarts3 {
port: this.options.port,
useSsl: false,
},
...(optionsArg? optionsArg : {})
...(optionsArg ? optionsArg : {}),
};
}
public async createBucket(bucketNameArg: string) {
const smartbucketInstance = new plugins.smartbucket.SmartBucket(await this.getS3Descriptor());
const smartbucketInstance = new plugins.smartbucket.SmartBucket(
await this.getS3Descriptor(),
);
const bucket = await smartbucketInstance.createBucket(bucketNameArg);
return bucket;
}