fix(core): update
This commit is contained in:
5
ts/smartbucket.classes.bucket.ts
Normal file
5
ts/smartbucket.classes.bucket.ts
Normal file
@ -0,0 +1,5 @@
|
||||
import * as plugins from './smartbucket.plugins';
|
||||
|
||||
export class Bucket {
|
||||
|
||||
}
|
5
ts/smartbucket.classes.directory.ts
Normal file
5
ts/smartbucket.classes.directory.ts
Normal file
@ -0,0 +1,5 @@
|
||||
import * as plugins from './smartbucket.plugins';
|
||||
|
||||
export class Directory {
|
||||
|
||||
}
|
5
ts/smartbucket.classes.file.ts
Normal file
5
ts/smartbucket.classes.file.ts
Normal file
@ -0,0 +1,5 @@
|
||||
import * as plugins from './smartbucket.plugins';
|
||||
|
||||
export class File {
|
||||
|
||||
}
|
@ -1,14 +1,14 @@
|
||||
import * as plugins from './smartbucket.plugins';
|
||||
|
||||
export interface ISmartBucketConfig {
|
||||
provider: 'google';
|
||||
provider: 'digitalocean';
|
||||
projectId: string;
|
||||
bucketName: string;
|
||||
}
|
||||
|
||||
export class SmartBucket {
|
||||
config: ISmartBucketConfig;
|
||||
private _googleBucket;
|
||||
public config: ISmartBucketConfig;
|
||||
|
||||
/**
|
||||
* the constructor of SmartBucket
|
||||
*/
|
||||
@ -19,12 +19,7 @@ export class SmartBucket {
|
||||
/**
|
||||
* initializes the Smartbucket
|
||||
*/
|
||||
async init() {
|
||||
if (this.config.provider === 'google') {
|
||||
const storage = new plugins.googleCloudStorage.Storage({
|
||||
projectId: this.config.projectId
|
||||
});
|
||||
storage.createBucket(this.config.bucketName, () => {});
|
||||
}
|
||||
public async init() {
|
||||
|
||||
}
|
||||
}
|
||||
|
@ -3,7 +3,4 @@ import * as smartpromise from '@pushrocks/smartpromise';
|
||||
export { smartpromise };
|
||||
|
||||
// third party scope
|
||||
import * as googleCloudStorage from '@google-cloud/storage';
|
||||
import * as minio from 'minio';
|
||||
|
||||
export { googleCloudStorage };
|
||||
|
Reference in New Issue
Block a user