mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-08-13 05:20:25 +00:00
serverless: add Utils class types
This commit is contained in:
Vendored
+22
@@ -0,0 +1,22 @@
|
||||
import Serverless = require("../index");
|
||||
|
||||
declare class Utils {
|
||||
constructor(serverless: Serverless);
|
||||
|
||||
getVersion(): string;
|
||||
dirExistsSync(dirPath: string): boolean;
|
||||
fileExistsSync(filePath: string): boolean;
|
||||
writeFileDir(filePath: string): void;
|
||||
writeFileSync(filePath: string, contents: string): void;
|
||||
writeFile(filePath: string, contents: string): PromiseLike<{}>;
|
||||
appendFileSync(filePath: string, contents: string): PromiseLike<{}>;
|
||||
readFileSync(filePath: string): {};
|
||||
readFile(filePath: string): PromiseLike<{}>;
|
||||
walkDirSync(dirPath: string): string[];
|
||||
copyDirContentsSync(srcDir: string, destDir: string): void;
|
||||
generateShortId(length: number): string;
|
||||
findServicePath(): string;
|
||||
logStat(serverless: Serverless, context: string): PromiseLike<{}>;
|
||||
}
|
||||
|
||||
export = Utils;
|
||||
Vendored
+2
-1
@@ -6,6 +6,7 @@
|
||||
import Service = require("./classes/Service");
|
||||
import Plugin = require("./classes/Plugin");
|
||||
import PluginManager = require("./classes/PluginManager");
|
||||
import Utils = require("./classes/Utils");
|
||||
import YamlParser = require("./classes/YamlParser");
|
||||
import AwsProvider = require("./plugins/aws/provider/awsProvider");
|
||||
|
||||
@@ -45,7 +46,7 @@ declare class Serverless {
|
||||
};
|
||||
|
||||
providers: {};
|
||||
utils: {};
|
||||
utils: Utils;
|
||||
variables: {};
|
||||
yamlParser: YamlParser;
|
||||
pluginManager: PluginManager;
|
||||
|
||||
Reference in New Issue
Block a user