tnp-helpers 13.1.16 → 13.1.17
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/app.js +3 -3
- package/browser/README.md +24 -24
- package/browser/esm2020/lib/angular.helper.mjs +87 -87
- package/browser/esm2020/lib/base-component.mjs +49 -49
- package/browser/esm2020/lib/base-formly-component.mjs +112 -112
- package/browser/esm2020/lib/condition-wait.mjs +45 -45
- package/browser/esm2020/lib/constants.mjs +7 -7
- package/browser/esm2020/lib/dual-component-ctrl.mjs +118 -118
- package/browser/esm2020/lib/firedev-models.mjs +3 -3
- package/browser/esm2020/lib/helpers-array-obj.mjs +82 -82
- package/browser/esm2020/lib/helpers-browser.mjs +46 -46
- package/browser/esm2020/lib/helpers-environment.mjs +32 -32
- package/browser/esm2020/lib/helpers-numbers.mjs +7 -7
- package/browser/esm2020/lib/helpers-strings-regexes.mjs +50 -50
- package/browser/esm2020/lib/helpers-strings.mjs +252 -252
- package/browser/esm2020/lib/helpers.mjs +283 -283
- package/browser/esm2020/lib/index.mjs +15 -15
- package/browser/esm2020/lib/long-press.directive.mjs +112 -112
- package/browser/esm2020/lib/project.mjs +429 -429
- package/browser/esm2020/lib/resize-service.mjs +21 -21
- package/browser/esm2020/public-api.mjs +1 -1
- package/browser/esm2020/tnp-helpers.mjs +4 -4
- package/browser/fesm2015/tnp-helpers.mjs +1676 -1676
- package/browser/fesm2020/tnp-helpers.mjs +1666 -1666
- package/browser/lib/angular.helper.d.ts +35 -35
- package/browser/lib/base-component.d.ts +16 -16
- package/browser/lib/base-formly-component.d.ts +30 -30
- package/browser/lib/condition-wait.d.ts +7 -7
- package/browser/lib/constants.d.ts +5 -5
- package/browser/lib/dual-component-ctrl.d.ts +24 -24
- package/browser/lib/firedev-models.d.ts +12 -12
- package/browser/lib/helpers-array-obj.d.ts +14 -14
- package/browser/lib/helpers-browser.d.ts +10 -10
- package/browser/lib/helpers-environment.d.ts +4 -4
- package/browser/lib/helpers-numbers.d.ts +2 -2
- package/browser/lib/helpers-strings-regexes.d.ts +27 -27
- package/browser/lib/helpers-strings.d.ts +49 -49
- package/browser/lib/helpers.d.ts +31 -31
- package/browser/lib/index.d.ts +11 -11
- package/browser/lib/long-press.directive.d.ts +24 -24
- package/browser/lib/project.d.ts +94 -94
- package/browser/lib/resize-service.d.ts +8 -8
- package/browser/tnp-helpers.d.ts +4 -4
- package/client/README.md +24 -24
- package/client/esm2020/lib/angular.helper.mjs +87 -87
- package/client/esm2020/lib/base-component.mjs +49 -49
- package/client/esm2020/lib/base-formly-component.mjs +112 -112
- package/client/esm2020/lib/condition-wait.mjs +45 -45
- package/client/esm2020/lib/constants.mjs +7 -7
- package/client/esm2020/lib/dual-component-ctrl.mjs +118 -118
- package/client/esm2020/lib/firedev-models.mjs +3 -3
- package/client/esm2020/lib/helpers-array-obj.mjs +82 -82
- package/client/esm2020/lib/helpers-browser.mjs +46 -46
- package/client/esm2020/lib/helpers-environment.mjs +32 -32
- package/client/esm2020/lib/helpers-numbers.mjs +7 -7
- package/client/esm2020/lib/helpers-strings-regexes.mjs +50 -50
- package/client/esm2020/lib/helpers-strings.mjs +252 -252
- package/client/esm2020/lib/helpers.mjs +283 -283
- package/client/esm2020/lib/index.mjs +15 -15
- package/client/esm2020/lib/long-press.directive.mjs +112 -112
- package/client/esm2020/lib/project.mjs +429 -429
- package/client/esm2020/lib/resize-service.mjs +21 -21
- package/client/esm2020/public-api.mjs +1 -1
- package/client/esm2020/tnp-helpers.mjs +4 -4
- package/client/fesm2015/tnp-helpers.mjs +1676 -1676
- package/client/fesm2020/tnp-helpers.mjs +1666 -1666
- package/client/lib/angular.helper.d.ts +35 -35
- package/client/lib/base-component.d.ts +16 -16
- package/client/lib/base-formly-component.d.ts +30 -30
- package/client/lib/condition-wait.d.ts +7 -7
- package/client/lib/constants.d.ts +5 -5
- package/client/lib/dual-component-ctrl.d.ts +24 -24
- package/client/lib/firedev-models.d.ts +12 -12
- package/client/lib/helpers-array-obj.d.ts +14 -14
- package/client/lib/helpers-browser.d.ts +10 -10
- package/client/lib/helpers-environment.d.ts +4 -4
- package/client/lib/helpers-numbers.d.ts +2 -2
- package/client/lib/helpers-strings-regexes.d.ts +27 -27
- package/client/lib/helpers-strings.d.ts +49 -49
- package/client/lib/helpers.d.ts +31 -31
- package/client/lib/index.d.ts +11 -11
- package/client/lib/long-press.directive.d.ts +24 -24
- package/client/lib/project.d.ts +94 -94
- package/client/lib/resize-service.d.ts +8 -8
- package/client/tnp-helpers.d.ts +4 -4
- package/index.d.ts +1 -1
- package/lib/angular.helper.d.ts +35 -35
- package/lib/angular.helper.js +3 -3
- package/lib/base-component.d.ts +13 -13
- package/lib/base-component.js +3 -3
- package/lib/base-formly-component.d.ts +27 -27
- package/lib/base-formly-component.js +3 -3
- package/lib/condition-wait.d.ts +8 -8
- package/lib/constants.d.ts +6 -6
- package/lib/dual-component-ctrl.d.ts +24 -24
- package/lib/dual-component-ctrl.js +3 -3
- package/lib/firedev-models.d.ts +13 -13
- package/lib/git-project.d.ts +45 -45
- package/lib/helpers-array-obj.d.ts +15 -15
- package/lib/helpers-browser.d.ts +11 -11
- package/lib/helpers-cli-tool.backend.d.ts +55 -55
- package/lib/helpers-cli-tool.backend.js +1 -1
- package/lib/helpers-dependencies.backend.d.ts +11 -11
- package/lib/helpers-environment.d.ts +5 -5
- package/lib/helpers-file-folders.backend.d.ts +83 -83
- package/lib/helpers-file-folders.backend.js +6 -6
- package/lib/helpers-git.backend.d.ts +43 -43
- package/lib/helpers-json5.backend.d.ts +16 -16
- package/lib/helpers-morphi-framework.backend.d.ts +4 -4
- package/lib/helpers-network.backend.d.ts +8 -8
- package/lib/helpers-npm.backend.d.ts +3 -3
- package/lib/helpers-numbers.d.ts +3 -3
- package/lib/helpers-path.backend.d.ts +7 -7
- package/lib/helpers-process.backend.d.ts +54 -54
- package/lib/helpers-strings-regexes.d.ts +28 -28
- package/lib/helpers-strings.d.ts +50 -50
- package/lib/helpers-system-terminal.backend.d.ts +5 -5
- package/lib/helpers-vscode.backend.d.ts +5 -5
- package/lib/helpers.d.ts +72 -72
- package/lib/index.d.ts +12 -12
- package/lib/long-press.directive.d.ts +22 -22
- package/lib/merge-helpers.backend.d.ts +23 -23
- package/lib/project.d.ts +97 -97
- package/lib/resize-service.d.ts +6 -6
- package/lib/ts-code/index.d.ts +1 -1
- package/lib/ts-code/ts-code-extractor.d.ts +14 -14
- package/lib/ts-code/ts-code-modifier.backend.d.ts +12 -12
- package/package.json +3 -3
- package/package.json_devDependencies.json +222 -222
- package/package.json_tnp.json5 +44 -44
- package/tmp-environment.json +12 -12
- package/websql/README.md +24 -24
- package/websql/esm2020/lib/angular.helper.mjs +87 -87
- package/websql/esm2020/lib/base-component.mjs +49 -49
- package/websql/esm2020/lib/base-formly-component.mjs +112 -112
- package/websql/esm2020/lib/condition-wait.mjs +45 -45
- package/websql/esm2020/lib/constants.mjs +7 -7
- package/websql/esm2020/lib/dual-component-ctrl.mjs +118 -118
- package/websql/esm2020/lib/firedev-models.mjs +3 -3
- package/websql/esm2020/lib/helpers-array-obj.mjs +82 -82
- package/websql/esm2020/lib/helpers-browser.mjs +46 -46
- package/websql/esm2020/lib/helpers-environment.mjs +32 -32
- package/websql/esm2020/lib/helpers-numbers.mjs +7 -7
- package/websql/esm2020/lib/helpers-strings-regexes.mjs +50 -50
- package/websql/esm2020/lib/helpers-strings.mjs +252 -252
- package/websql/esm2020/lib/helpers.mjs +283 -283
- package/websql/esm2020/lib/index.mjs +15 -15
- package/websql/esm2020/lib/long-press.directive.mjs +112 -112
- package/websql/esm2020/lib/project.mjs +429 -429
- package/websql/esm2020/lib/resize-service.mjs +21 -21
- package/websql/esm2020/public-api.mjs +1 -1
- package/websql/esm2020/tnp-helpers.mjs +4 -4
- package/websql/fesm2015/tnp-helpers.mjs +1676 -1676
- package/websql/fesm2020/tnp-helpers.mjs +1666 -1666
- package/websql/lib/angular.helper.d.ts +35 -35
- package/websql/lib/base-component.d.ts +16 -16
- package/websql/lib/base-formly-component.d.ts +30 -30
- package/websql/lib/condition-wait.d.ts +7 -7
- package/websql/lib/constants.d.ts +5 -5
- package/websql/lib/dual-component-ctrl.d.ts +24 -24
- package/websql/lib/firedev-models.d.ts +12 -12
- package/websql/lib/helpers-array-obj.d.ts +14 -14
- package/websql/lib/helpers-browser.d.ts +10 -10
- package/websql/lib/helpers-environment.d.ts +4 -4
- package/websql/lib/helpers-numbers.d.ts +2 -2
- package/websql/lib/helpers-strings-regexes.d.ts +27 -27
- package/websql/lib/helpers-strings.d.ts +49 -49
- package/websql/lib/helpers.d.ts +31 -31
- package/websql/lib/index.d.ts +11 -11
- package/websql/lib/long-press.directive.d.ts +24 -24
- package/websql/lib/project.d.ts +94 -94
- package/websql/lib/resize-service.d.ts +8 -8
- package/websql/tnp-helpers.d.ts +4 -4
package/lib/git-project.d.ts
CHANGED
|
@@ -1,45 +1,45 @@
|
|
|
1
|
-
import { Project } from './project';
|
|
2
|
-
import { RunOptions, ExecuteOptions } from 'tnp-core';
|
|
3
|
-
export declare abstract class ProjectGit {
|
|
4
|
-
runCommandGetString(this: Project, command: string): string;
|
|
5
|
-
execute(this: Project, command: string, options?: ExecuteOptions & {
|
|
6
|
-
showCommand?: boolean;
|
|
7
|
-
}): Promise<unknown>;
|
|
8
|
-
run(this: Project, command: string, options?: RunOptions): {
|
|
9
|
-
sync(): string;
|
|
10
|
-
async(detach?: boolean, mockFun?: (stdoutCallback: (dataForStdout: any) => any, stdErrcCallback: (dataForStder: any) => any, shouldProcesBeDead?: () => boolean) => number | Promise<number>): any;
|
|
11
|
-
asyncAsPromise(): any;
|
|
12
|
-
unitlOutputContains(stdoutMsg: string | string[], stderMsg?: string | string[]): Promise<any>;
|
|
13
|
-
};
|
|
14
|
-
get git(this: Project): {
|
|
15
|
-
clone(url: string, destinationFolderName?: string): void;
|
|
16
|
-
restoreLastVersion(localFilePath: string): void;
|
|
17
|
-
resetFiles(...relativePathes: string[]): void;
|
|
18
|
-
readonly isGitRepo: boolean;
|
|
19
|
-
readonly isGitRoot: boolean;
|
|
20
|
-
readonly originURL: string;
|
|
21
|
-
updateOrigin(askToRetry?: boolean): Promise<void>;
|
|
22
|
-
commit(args?: string): void;
|
|
23
|
-
pushCurrentBranch(force?: boolean, origin?: string): void;
|
|
24
|
-
readonly thereAreSomeUncommitedChange: boolean;
|
|
25
|
-
thereAreSomeUncommitedChangeExcept(filesList?: string[]): boolean;
|
|
26
|
-
pullCurrentBranch(askToRetry?: boolean): Promise<void>;
|
|
27
|
-
readonly currentBranchName: string;
|
|
28
|
-
getBranchesNamesBy(pattern: string | RegExp): string[];
|
|
29
|
-
resetHard(): void;
|
|
30
|
-
countComits(): number;
|
|
31
|
-
hasAnyCommits(): boolean;
|
|
32
|
-
readonly isInMergeProcess: boolean;
|
|
33
|
-
lastCommitDate(): Date;
|
|
34
|
-
lastCommitHash(): string;
|
|
35
|
-
lastCommitMessage(): string;
|
|
36
|
-
penultimageCommitHash(): string;
|
|
37
|
-
checkTagExists(tag: string): boolean;
|
|
38
|
-
lastTagHash(): string;
|
|
39
|
-
readonly lastTagVersionName: string;
|
|
40
|
-
/**
|
|
41
|
-
* TODO does this make any sense
|
|
42
|
-
*/
|
|
43
|
-
renameOrigin(newNameOrUlr: string): void;
|
|
44
|
-
};
|
|
45
|
-
}
|
|
1
|
+
import { Project } from './project';
|
|
2
|
+
import { RunOptions, ExecuteOptions } from 'tnp-core';
|
|
3
|
+
export declare abstract class ProjectGit {
|
|
4
|
+
runCommandGetString(this: Project, command: string): string;
|
|
5
|
+
execute(this: Project, command: string, options?: ExecuteOptions & {
|
|
6
|
+
showCommand?: boolean;
|
|
7
|
+
}): Promise<unknown>;
|
|
8
|
+
run(this: Project, command: string, options?: RunOptions): {
|
|
9
|
+
sync(): string;
|
|
10
|
+
async(detach?: boolean, mockFun?: (stdoutCallback: (dataForStdout: any) => any, stdErrcCallback: (dataForStder: any) => any, shouldProcesBeDead?: () => boolean) => number | Promise<number>): any;
|
|
11
|
+
asyncAsPromise(): any;
|
|
12
|
+
unitlOutputContains(stdoutMsg: string | string[], stderMsg?: string | string[]): Promise<any>;
|
|
13
|
+
};
|
|
14
|
+
get git(this: Project): {
|
|
15
|
+
clone(url: string, destinationFolderName?: string): void;
|
|
16
|
+
restoreLastVersion(localFilePath: string): void;
|
|
17
|
+
resetFiles(...relativePathes: string[]): void;
|
|
18
|
+
readonly isGitRepo: boolean;
|
|
19
|
+
readonly isGitRoot: boolean;
|
|
20
|
+
readonly originURL: string;
|
|
21
|
+
updateOrigin(askToRetry?: boolean): Promise<void>;
|
|
22
|
+
commit(args?: string): void;
|
|
23
|
+
pushCurrentBranch(force?: boolean, origin?: string): void;
|
|
24
|
+
readonly thereAreSomeUncommitedChange: boolean;
|
|
25
|
+
thereAreSomeUncommitedChangeExcept(filesList?: string[]): boolean;
|
|
26
|
+
pullCurrentBranch(askToRetry?: boolean): Promise<void>;
|
|
27
|
+
readonly currentBranchName: string;
|
|
28
|
+
getBranchesNamesBy(pattern: string | RegExp): string[];
|
|
29
|
+
resetHard(): void;
|
|
30
|
+
countComits(): number;
|
|
31
|
+
hasAnyCommits(): boolean;
|
|
32
|
+
readonly isInMergeProcess: boolean;
|
|
33
|
+
lastCommitDate(): Date;
|
|
34
|
+
lastCommitHash(): string;
|
|
35
|
+
lastCommitMessage(): string;
|
|
36
|
+
penultimageCommitHash(): string;
|
|
37
|
+
checkTagExists(tag: string): boolean;
|
|
38
|
+
lastTagHash(): string;
|
|
39
|
+
readonly lastTagVersionName: string;
|
|
40
|
+
/**
|
|
41
|
+
* TODO does this make any sense
|
|
42
|
+
*/
|
|
43
|
+
renameOrigin(newNameOrUlr: string): void;
|
|
44
|
+
};
|
|
45
|
+
}
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
export declare class HelpersArrayObj {
|
|
2
|
-
from(s: string | string[]): string[];
|
|
3
|
-
second(arr: any): any;
|
|
4
|
-
arrayMoveElementBefore<T = any>(arr: any[], a: any, b: any, prop?: keyof T): any[];
|
|
5
|
-
arrayMoveElementAfterB<T = any>(arr: any[], a: any, b: any, prop?: keyof T): any[];
|
|
6
|
-
uniqArray<T = any>(array: any[], uniqueProperty?: (keyof T)): T[];
|
|
7
|
-
sortKeys(obj: any): any;
|
|
8
|
-
/**
|
|
9
|
-
* Fuzzy search
|
|
10
|
-
*/
|
|
11
|
-
fuzzy<T = any>(query: string, list: T[], valueFn?: (modelFromList: T) => string): {
|
|
12
|
-
matches: string[];
|
|
13
|
-
results: T[];
|
|
14
|
-
};
|
|
15
|
-
}
|
|
1
|
+
export declare class HelpersArrayObj {
|
|
2
|
+
from(s: string | string[]): string[];
|
|
3
|
+
second(arr: any): any;
|
|
4
|
+
arrayMoveElementBefore<T = any>(arr: any[], a: any, b: any, prop?: keyof T): any[];
|
|
5
|
+
arrayMoveElementAfterB<T = any>(arr: any[], a: any, b: any, prop?: keyof T): any[];
|
|
6
|
+
uniqArray<T = any>(array: any[], uniqueProperty?: (keyof T)): T[];
|
|
7
|
+
sortKeys(obj: any): any;
|
|
8
|
+
/**
|
|
9
|
+
* Fuzzy search
|
|
10
|
+
*/
|
|
11
|
+
fuzzy<T = any>(query: string, list: T[], valueFn?: (modelFromList: T) => string): {
|
|
12
|
+
matches: string[];
|
|
13
|
+
results: T[];
|
|
14
|
+
};
|
|
15
|
+
}
|
package/lib/helpers-browser.d.ts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
export declare class HelpersBrowaser {
|
|
2
|
-
private static callbacks;
|
|
3
|
-
static onInit(callback: (ins: HelpersBrowaser) => any): void;
|
|
4
|
-
get win(): Window & typeof globalThis;
|
|
5
|
-
private get tabIdSessionStorage();
|
|
6
|
-
readonly tabId: number;
|
|
7
|
-
private static inst;
|
|
8
|
-
init: void;
|
|
9
|
-
private constructor();
|
|
10
|
-
static get instance(): HelpersBrowaser;
|
|
11
|
-
}
|
|
1
|
+
export declare class HelpersBrowaser {
|
|
2
|
+
private static callbacks;
|
|
3
|
+
static onInit(callback: (ins: HelpersBrowaser) => any): void;
|
|
4
|
+
get win(): Window & typeof globalThis;
|
|
5
|
+
private get tabIdSessionStorage();
|
|
6
|
+
readonly tabId: number;
|
|
7
|
+
private static inst;
|
|
8
|
+
init: void;
|
|
9
|
+
private constructor();
|
|
10
|
+
static get instance(): HelpersBrowaser;
|
|
11
|
+
}
|
|
@@ -1,55 +1,55 @@
|
|
|
1
|
-
import type { Project } from './project';
|
|
2
|
-
export declare class HelpersCliTool {
|
|
3
|
-
/**
|
|
4
|
-
* return simplified version of command:
|
|
5
|
-
* example: tnp HELLO:WORLD
|
|
6
|
-
* will be: tnp helloworld
|
|
7
|
-
*
|
|
8
|
-
* or: `tnp ${$START}`
|
|
9
|
-
* will be `tnp start`
|
|
10
|
-
*
|
|
11
|
-
* @param commandStringOrClass
|
|
12
|
-
*/
|
|
13
|
-
simplifiedCmd(commandStringOrClass: string | Function, shortVersion?: boolean): any;
|
|
14
|
-
argsFromBegin<T = any>(argumentsCommands: string | string[], argsFunc: (restOfCommandArgs: any) => T): {
|
|
15
|
-
resolved: T[];
|
|
16
|
-
/**
|
|
17
|
-
* arguments string without resolved
|
|
18
|
-
*/
|
|
19
|
-
commandString: string;
|
|
20
|
-
};
|
|
21
|
-
cleanCommand<T extends {
|
|
22
|
-
[k: string]: string | boolean | string[] | boolean[];
|
|
23
|
-
}>(command: string | string[], minimistOption: T): string;
|
|
24
|
-
argsFrom<T = any>(args: string | string[]): T;
|
|
25
|
-
removeStartEndCommandChars(command: string): string;
|
|
26
|
-
resolveProject<T = Project>(args: string | string[], CurrentProject: Project, ProjectClass: typeof Project): T;
|
|
27
|
-
/**
|
|
28
|
-
* Resolve child project when accessing from parent workspace, container etc...
|
|
29
|
-
* @param args string or string[] from cli args
|
|
30
|
-
* @param CurrentProject project from process.cwd()
|
|
31
|
-
*/
|
|
32
|
-
resolveChildProject(args: string | string[], CurrentProject: Project): Project;
|
|
33
|
-
resolveProjectsFromArgs(args: string | string[], CurrentProject: Project, ProjectClass: typeof Project): Project[];
|
|
34
|
-
/**
|
|
35
|
-
* Check if your function name fits into command line param
|
|
36
|
-
*
|
|
37
|
-
* @param name name of function
|
|
38
|
-
* @param restOfArgs arguments from command line
|
|
39
|
-
*/
|
|
40
|
-
match(name: string, restOfArgs: string[]): {
|
|
41
|
-
isMatch: boolean;
|
|
42
|
-
restOfArgs: string[];
|
|
43
|
-
};
|
|
44
|
-
/**
|
|
45
|
-
* @todo TODO replace with funciton below
|
|
46
|
-
*/
|
|
47
|
-
globalArgumentsParserTnp(argsv: string[]): string;
|
|
48
|
-
/**
|
|
49
|
-
* @todo TODO replace with funciton above
|
|
50
|
-
*/
|
|
51
|
-
globalArgumentsParser(argsv: string[]): string[];
|
|
52
|
-
removeArg(arg: string, argsv: string[]): string[];
|
|
53
|
-
removeArgTnp(arg: string, argsv: string[]): string[];
|
|
54
|
-
removeArgFromString(argsString: string, argsToClear?: string[]): string;
|
|
55
|
-
}
|
|
1
|
+
import type { Project } from './project';
|
|
2
|
+
export declare class HelpersCliTool {
|
|
3
|
+
/**
|
|
4
|
+
* return simplified version of command:
|
|
5
|
+
* example: tnp HELLO:WORLD
|
|
6
|
+
* will be: tnp helloworld
|
|
7
|
+
*
|
|
8
|
+
* or: `tnp ${$START}`
|
|
9
|
+
* will be `tnp start`
|
|
10
|
+
*
|
|
11
|
+
* @param commandStringOrClass
|
|
12
|
+
*/
|
|
13
|
+
simplifiedCmd(commandStringOrClass: string | Function, shortVersion?: boolean): any;
|
|
14
|
+
argsFromBegin<T = any>(argumentsCommands: string | string[], argsFunc: (restOfCommandArgs: any) => T): {
|
|
15
|
+
resolved: T[];
|
|
16
|
+
/**
|
|
17
|
+
* arguments string without resolved
|
|
18
|
+
*/
|
|
19
|
+
commandString: string;
|
|
20
|
+
};
|
|
21
|
+
cleanCommand<T extends {
|
|
22
|
+
[k: string]: string | boolean | string[] | boolean[];
|
|
23
|
+
}>(command: string | string[], minimistOption: T): string;
|
|
24
|
+
argsFrom<T = any>(args: string | string[]): T;
|
|
25
|
+
removeStartEndCommandChars(command: string): string;
|
|
26
|
+
resolveProject<T = Project>(args: string | string[], CurrentProject: Project, ProjectClass: typeof Project): T;
|
|
27
|
+
/**
|
|
28
|
+
* Resolve child project when accessing from parent workspace, container etc...
|
|
29
|
+
* @param args string or string[] from cli args
|
|
30
|
+
* @param CurrentProject project from process.cwd()
|
|
31
|
+
*/
|
|
32
|
+
resolveChildProject(args: string | string[], CurrentProject: Project): Project;
|
|
33
|
+
resolveProjectsFromArgs(args: string | string[], CurrentProject: Project, ProjectClass: typeof Project): Project[];
|
|
34
|
+
/**
|
|
35
|
+
* Check if your function name fits into command line param
|
|
36
|
+
*
|
|
37
|
+
* @param name name of function
|
|
38
|
+
* @param restOfArgs arguments from command line
|
|
39
|
+
*/
|
|
40
|
+
match(name: string, restOfArgs: string[]): {
|
|
41
|
+
isMatch: boolean;
|
|
42
|
+
restOfArgs: string[];
|
|
43
|
+
};
|
|
44
|
+
/**
|
|
45
|
+
* @todo TODO replace with funciton below
|
|
46
|
+
*/
|
|
47
|
+
globalArgumentsParserTnp(argsv: string[]): string;
|
|
48
|
+
/**
|
|
49
|
+
* @todo TODO replace with funciton above
|
|
50
|
+
*/
|
|
51
|
+
globalArgumentsParser(argsv: string[]): string[];
|
|
52
|
+
removeArg(arg: string, argsv: string[]): string[];
|
|
53
|
+
removeArgTnp(arg: string, argsv: string[]): string[];
|
|
54
|
+
removeArgFromString(argsString: string, argsToClear?: string[]): string;
|
|
55
|
+
}
|
|
@@ -406,7 +406,7 @@ var HelpersCliTool = /** @class */ (function () {
|
|
|
406
406
|
return argsv;
|
|
407
407
|
};
|
|
408
408
|
HelpersCliTool.prototype.removeArgFromString = function (argsString, argsToClear) {
|
|
409
|
-
if (argsToClear === void 0) { argsToClear = ['websql', 'skipNodeModules', 'skipCopyToSelection', 'skipSmartContainerDistBundleInit', 'copyto']; }
|
|
409
|
+
if (argsToClear === void 0) { argsToClear = ['websql', 'serveApp', 'skipNodeModules', 'skipCopyToSelection', 'skipSmartContainerDistBundleInit', 'copyto']; }
|
|
410
410
|
var argsObj = require('minimist')(argsString.split(' '));
|
|
411
411
|
var _loop_1 = function (index) {
|
|
412
412
|
var element = argsToClear[index];
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { Project } from './project';
|
|
2
|
-
export declare class HelpersDependencies {
|
|
3
|
-
sort<P extends Project = Project>(deps: {
|
|
4
|
-
project: P;
|
|
5
|
-
copyto: P[];
|
|
6
|
-
}[]): {
|
|
7
|
-
project: P;
|
|
8
|
-
copyto: P[];
|
|
9
|
-
}[];
|
|
10
|
-
recrusiveFind<P extends Project = Project>(currentProj: P, allAvailableProjects: P[], deps?: P[], orgProj?: P): P[];
|
|
11
|
-
}
|
|
1
|
+
import { Project } from './project';
|
|
2
|
+
export declare class HelpersDependencies {
|
|
3
|
+
sort<P extends Project = Project>(deps: {
|
|
4
|
+
project: P;
|
|
5
|
+
copyto: P[];
|
|
6
|
+
}[]): {
|
|
7
|
+
project: P;
|
|
8
|
+
copyto: P[];
|
|
9
|
+
}[];
|
|
10
|
+
recrusiveFind<P extends Project = Project>(currentProj: P, allAvailableProjects: P[], deps?: P[], orgProj?: P): P[];
|
|
11
|
+
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export declare class HelpersEnvironment {
|
|
2
|
-
environmentName(filename: any, local_env_name: any): any;
|
|
3
|
-
isValidGitRepuUrl(url: string): boolean;
|
|
4
|
-
isValidIp(ip: string): boolean;
|
|
5
|
-
}
|
|
1
|
+
export declare class HelpersEnvironment {
|
|
2
|
+
environmentName(filename: any, local_env_name: any): any;
|
|
3
|
+
isValidGitRepuUrl(url: string): boolean;
|
|
4
|
+
isValidIp(ip: string): boolean;
|
|
5
|
+
}
|
|
@@ -1,83 +1,83 @@
|
|
|
1
|
-
import { fse } from 'tnp-core';
|
|
2
|
-
import { Models } from 'tnp-models';
|
|
3
|
-
import type { Project } from './project';
|
|
4
|
-
export interface GetRecrusiveFilesFromOptions {
|
|
5
|
-
}
|
|
6
|
-
export declare class HelpersFileFolders {
|
|
7
|
-
/**
|
|
8
|
-
* Calculate file or string checksum
|
|
9
|
-
*/
|
|
10
|
-
checksum(absolutePathToFileOrContent: string, algorithm?: 'md5' | 'sha1'): string;
|
|
11
|
-
getValueFromJSON(filepath: string, lodashGetPath: string, defaultValue?: any): any;
|
|
12
|
-
readValueFromJson(filepath: string, lodashGetPath: string, defaultValue?: any): any;
|
|
13
|
-
setValueToJSON(filepath: string, lodashGetPath: string, value: any): void;
|
|
14
|
-
/**
|
|
15
|
-
* file size in bytes
|
|
16
|
-
*/
|
|
17
|
-
size(filePath: string): number;
|
|
18
|
-
pathFromLink(filePath: string): string;
|
|
19
|
-
renameFolder(from: string, to: string, cwd?: string): void;
|
|
20
|
-
getTempFolder(): string;
|
|
21
|
-
isPlainFileOrFolder(filePath: any): boolean;
|
|
22
|
-
requireUncached(module: any): any;
|
|
23
|
-
/**
|
|
24
|
-
* get default export object from js file
|
|
25
|
-
* @param jsFilePath
|
|
26
|
-
*/
|
|
27
|
-
require(jsFilePath: string): any;
|
|
28
|
-
tryRecreateDir(dirpath: string): void;
|
|
29
|
-
tryCopyFrom(source: string, destination: string, options?: {}): void;
|
|
30
|
-
removeIfExists(absoluteFileOrFolderPath: string): void;
|
|
31
|
-
removeFileIfExists(absoluteFilePath: string, options?: {
|
|
32
|
-
modifiedFiles?: Models.other.ModifiedFiles;
|
|
33
|
-
}): void;
|
|
34
|
-
removeFolderIfExists(absoluteFolderPath: string, options?: {
|
|
35
|
-
modifiedFiles?: Models.other.ModifiedFiles;
|
|
36
|
-
}): void;
|
|
37
|
-
tryRemoveDir(dirpath: string, contentOnly?: boolean, omitWarningNotExisted?: boolean): void;
|
|
38
|
-
move(from: string, to: string): void;
|
|
39
|
-
findChildren<T>(location: any, createFn: (childLocation: string) => T): T[];
|
|
40
|
-
findChildrenNavi<T>(location: any, createFn: (childLocation: string) => T): T[];
|
|
41
|
-
getRecrusiveFilesFrom(dir: string, ommitFolders?: string[], options?: GetRecrusiveFilesFromOptions): string[];
|
|
42
|
-
getLinesFromFiles(filename: string, lineCount?: number): Promise<string[]>;
|
|
43
|
-
/**
|
|
44
|
-
* Get the most recent changes file in direcory
|
|
45
|
-
* @param dir absoulute path to file
|
|
46
|
-
*/
|
|
47
|
-
getMostRecentFileName(dir: any): string;
|
|
48
|
-
getMostRecentFilesNames(dir: any): string[];
|
|
49
|
-
removeExcept(fromPath: string, exceptFolderAndFiles: string[]): void;
|
|
50
|
-
copy(sourceDir: string, destinationDir: string, options?: {
|
|
51
|
-
filter?: any;
|
|
52
|
-
overwrite?: boolean;
|
|
53
|
-
recursive?: boolean;
|
|
54
|
-
asSeparatedFiles?: boolean;
|
|
55
|
-
asSeparatedFilesAllowNotCopied?: boolean;
|
|
56
|
-
asSeparatedFilesSymlinkAsFile?: boolean;
|
|
57
|
-
/**
|
|
58
|
-
* folders to omit: example: ['src','node_modules']
|
|
59
|
-
*
|
|
60
|
-
* This option works only with omitFoldersBaseFolder
|
|
61
|
-
*/
|
|
62
|
-
omitFolders?: string[];
|
|
63
|
-
/**
|
|
64
|
-
* absolute path for base folder for omitFolder option
|
|
65
|
-
*/
|
|
66
|
-
omitFoldersBaseFolder?: string;
|
|
67
|
-
copySymlinksAsFiles?: boolean;
|
|
68
|
-
useTempFolder?: boolean;
|
|
69
|
-
} & fse.CopyOptionsSync): void;
|
|
70
|
-
filterDontCopy(basePathFoldersTosSkip: string[], projectOrBasepath: Project | string): (src: string, dest: string) => boolean;
|
|
71
|
-
filterOnlyCopy(basePathFoldersOnlyToInclude: string[], projectOrBasepath: Project | string): (src: string, dest: string) => boolean;
|
|
72
|
-
copyFile(sourcePath: string, destinationPath: string, options?: {
|
|
73
|
-
transformTextFn?: (input: string) => string;
|
|
74
|
-
debugMode?: boolean;
|
|
75
|
-
fast?: boolean;
|
|
76
|
-
dontCopySameContent?: boolean;
|
|
77
|
-
modifiedFiles?: Models.other.ModifiedFiles;
|
|
78
|
-
}): boolean;
|
|
79
|
-
/**
|
|
80
|
-
* get real absolute path
|
|
81
|
-
*/
|
|
82
|
-
resolve(fileOrFolderPath: string): string;
|
|
83
|
-
}
|
|
1
|
+
import { fse } from 'tnp-core';
|
|
2
|
+
import { Models } from 'tnp-models';
|
|
3
|
+
import type { Project } from './project';
|
|
4
|
+
export interface GetRecrusiveFilesFromOptions {
|
|
5
|
+
}
|
|
6
|
+
export declare class HelpersFileFolders {
|
|
7
|
+
/**
|
|
8
|
+
* Calculate file or string checksum
|
|
9
|
+
*/
|
|
10
|
+
checksum(absolutePathToFileOrContent: string, algorithm?: 'md5' | 'sha1'): string;
|
|
11
|
+
getValueFromJSON(filepath: string, lodashGetPath: string, defaultValue?: any): any;
|
|
12
|
+
readValueFromJson(filepath: string, lodashGetPath: string, defaultValue?: any): any;
|
|
13
|
+
setValueToJSON(filepath: string, lodashGetPath: string, value: any): void;
|
|
14
|
+
/**
|
|
15
|
+
* file size in bytes
|
|
16
|
+
*/
|
|
17
|
+
size(filePath: string): number;
|
|
18
|
+
pathFromLink(filePath: string): string;
|
|
19
|
+
renameFolder(from: string, to: string, cwd?: string): void;
|
|
20
|
+
getTempFolder(): string;
|
|
21
|
+
isPlainFileOrFolder(filePath: any): boolean;
|
|
22
|
+
requireUncached(module: any): any;
|
|
23
|
+
/**
|
|
24
|
+
* get default export object from js file
|
|
25
|
+
* @param jsFilePath
|
|
26
|
+
*/
|
|
27
|
+
require(jsFilePath: string): any;
|
|
28
|
+
tryRecreateDir(dirpath: string): void;
|
|
29
|
+
tryCopyFrom(source: string, destination: string, options?: {}): void;
|
|
30
|
+
removeIfExists(absoluteFileOrFolderPath: string): void;
|
|
31
|
+
removeFileIfExists(absoluteFilePath: string, options?: {
|
|
32
|
+
modifiedFiles?: Models.other.ModifiedFiles;
|
|
33
|
+
}): void;
|
|
34
|
+
removeFolderIfExists(absoluteFolderPath: string, options?: {
|
|
35
|
+
modifiedFiles?: Models.other.ModifiedFiles;
|
|
36
|
+
}): void;
|
|
37
|
+
tryRemoveDir(dirpath: string, contentOnly?: boolean, omitWarningNotExisted?: boolean): void;
|
|
38
|
+
move(from: string, to: string): void;
|
|
39
|
+
findChildren<T>(location: any, createFn: (childLocation: string) => T): T[];
|
|
40
|
+
findChildrenNavi<T>(location: any, createFn: (childLocation: string) => T): T[];
|
|
41
|
+
getRecrusiveFilesFrom(dir: string, ommitFolders?: string[], options?: GetRecrusiveFilesFromOptions): string[];
|
|
42
|
+
getLinesFromFiles(filename: string, lineCount?: number): Promise<string[]>;
|
|
43
|
+
/**
|
|
44
|
+
* Get the most recent changes file in direcory
|
|
45
|
+
* @param dir absoulute path to file
|
|
46
|
+
*/
|
|
47
|
+
getMostRecentFileName(dir: any): string;
|
|
48
|
+
getMostRecentFilesNames(dir: any): string[];
|
|
49
|
+
removeExcept(fromPath: string, exceptFolderAndFiles: string[]): void;
|
|
50
|
+
copy(sourceDir: string, destinationDir: string, options?: {
|
|
51
|
+
filter?: any;
|
|
52
|
+
overwrite?: boolean;
|
|
53
|
+
recursive?: boolean;
|
|
54
|
+
asSeparatedFiles?: boolean;
|
|
55
|
+
asSeparatedFilesAllowNotCopied?: boolean;
|
|
56
|
+
asSeparatedFilesSymlinkAsFile?: boolean;
|
|
57
|
+
/**
|
|
58
|
+
* folders to omit: example: ['src','node_modules']
|
|
59
|
+
*
|
|
60
|
+
* This option works only with omitFoldersBaseFolder
|
|
61
|
+
*/
|
|
62
|
+
omitFolders?: string[];
|
|
63
|
+
/**
|
|
64
|
+
* absolute path for base folder for omitFolder option
|
|
65
|
+
*/
|
|
66
|
+
omitFoldersBaseFolder?: string;
|
|
67
|
+
copySymlinksAsFiles?: boolean;
|
|
68
|
+
useTempFolder?: boolean;
|
|
69
|
+
} & fse.CopyOptionsSync): void;
|
|
70
|
+
filterDontCopy(basePathFoldersTosSkip: string[], projectOrBasepath: Project | string): (src: string, dest: string) => boolean;
|
|
71
|
+
filterOnlyCopy(basePathFoldersOnlyToInclude: string[], projectOrBasepath: Project | string): (src: string, dest: string) => boolean;
|
|
72
|
+
copyFile(sourcePath: string, destinationPath: string, options?: {
|
|
73
|
+
transformTextFn?: (input: string) => string;
|
|
74
|
+
debugMode?: boolean;
|
|
75
|
+
fast?: boolean;
|
|
76
|
+
dontCopySameContent?: boolean;
|
|
77
|
+
modifiedFiles?: Models.other.ModifiedFiles;
|
|
78
|
+
}): boolean;
|
|
79
|
+
/**
|
|
80
|
+
* get real absolute path
|
|
81
|
+
*/
|
|
82
|
+
resolve(fileOrFolderPath: string): string;
|
|
83
|
+
}
|
|
@@ -143,7 +143,7 @@ var HelpersFileFolders = /** @class */ (function () {
|
|
|
143
143
|
var fileContent = tnp_core_1.fse.readFileSync(jsFilePath).toLocaleString();
|
|
144
144
|
(function () {
|
|
145
145
|
var stringForRegex = "require\\((\"|')\\.\\/([a-zA-Z0-9]|\\/|\\-|\\_|\\+|\\.)*(\"|')\\)";
|
|
146
|
-
index_1.Helpers.log("[
|
|
146
|
+
index_1.Helpers.log("[firedev-helpre][require][".concat(jsFilePath, "] stringForRegex: ").concat(stringForRegex), 1);
|
|
147
147
|
fileContent = fileContent.split('\n').map(function (line) {
|
|
148
148
|
var matches = line.match(new RegExp(stringForRegex));
|
|
149
149
|
if (matches !== null) {
|
|
@@ -161,7 +161,7 @@ var HelpersFileFolders = /** @class */ (function () {
|
|
|
161
161
|
})();
|
|
162
162
|
(function () {
|
|
163
163
|
var stringForRegex = "require\\((\"|')([a-zA-Z0-9]|\\/|\\-|\\_|\\+|\\.)*(\"|')\\)";
|
|
164
|
-
index_1.Helpers.log("[
|
|
164
|
+
index_1.Helpers.log("[firedev-helpre][require][".concat(jsFilePath, "] stringForRegex: ").concat(stringForRegex), 1);
|
|
165
165
|
fileContent = fileContent.split('\n').map(function (line) {
|
|
166
166
|
// console.log(`LINE: "${line}"`)
|
|
167
167
|
var matches = line.match(new RegExp(stringForRegex));
|
|
@@ -509,7 +509,7 @@ var HelpersFileFolders = /** @class */ (function () {
|
|
|
509
509
|
// sourceDir = sourceDir ? (sourceDir.replace(/\/$/, '')) : sourceDir;
|
|
510
510
|
// destinationDir = destinationDir ? (destinationDir.replace(/\/$/, '')) : destinationDir;
|
|
511
511
|
if (!tnp_core_1.fse.existsSync(sourceDir)) {
|
|
512
|
-
index_1.Helpers.warn("[
|
|
512
|
+
index_1.Helpers.warn("[firedev -helper][copy] Source dir doesnt exist: ".concat(sourceDir, " for destination: ").concat(destinationDir));
|
|
513
513
|
return;
|
|
514
514
|
}
|
|
515
515
|
if (!tnp_core_1.fse.existsSync(tnp_core_1.path.dirname(destinationDir))) {
|
|
@@ -544,7 +544,7 @@ var HelpersFileFolders = /** @class */ (function () {
|
|
|
544
544
|
// fse.existsSync(destinationDir) && fse.statSync(destinationDir),
|
|
545
545
|
// ];
|
|
546
546
|
// if (destStat && destStat.ino && destStat.dev && destStat.ino === srcStat.ino && destStat.dev === srcStat.dev) {
|
|
547
|
-
// Helpers.warn(`[
|
|
547
|
+
// Helpers.warn(`[firedev-helper][copy] Same location stats.. Trying to copy same source and destination:
|
|
548
548
|
// from: ${sourceDir}
|
|
549
549
|
// to: ${destinationDir}
|
|
550
550
|
// `);
|
|
@@ -556,7 +556,7 @@ var HelpersFileFolders = /** @class */ (function () {
|
|
|
556
556
|
options.filter = index_1.Helpers.filterDontCopy(options.omitFolders, options.omitFoldersBaseFolder);
|
|
557
557
|
}
|
|
558
558
|
if (sourceDir === destinationDir || tnp_core_1.path.resolve(sourceDir) === tnp_core_1.path.resolve(destinationDir)) {
|
|
559
|
-
index_1.Helpers.warn("[
|
|
559
|
+
index_1.Helpers.warn("[firedev-helper][copy] Trying to copy same source and destination\n from: ".concat(sourceDir, "\n to: ").concat(destinationDir, "\n "));
|
|
560
560
|
}
|
|
561
561
|
else {
|
|
562
562
|
// Helpers.warn('filter', _.isFunction(options.filter));
|
|
@@ -630,7 +630,7 @@ var HelpersFileFolders = /** @class */ (function () {
|
|
|
630
630
|
catch (error) {
|
|
631
631
|
var exitOnError = global['tnpNonInteractive'];
|
|
632
632
|
index_1.Helpers.log(error);
|
|
633
|
-
index_1.Helpers.error("[
|
|
633
|
+
index_1.Helpers.error("[firedev-helper] Not able to copy folder:\n from: ".concat(sourceDir, "\n to: ").concat(destinationDir, "\n options: ").concat(tnp_core_1.json5.stringify(options), "\n error: ").concat(error === null || error === void 0 ? void 0 : error.message, "\n "), !exitOnError);
|
|
634
634
|
index_1.Helpers.pressKeyAndContinue("Press any key to repeat copy action...");
|
|
635
635
|
copyFn_1();
|
|
636
636
|
}
|
|
@@ -1,43 +1,43 @@
|
|
|
1
|
-
import type { Project } from './project';
|
|
2
|
-
export declare class HelpersGit {
|
|
3
|
-
lastCommitHash(cwd: any): string;
|
|
4
|
-
penultimageCommitHash(cwd: any): string;
|
|
5
|
-
checkTagExists(tag: string, cwd?: string): boolean;
|
|
6
|
-
lastTagVersionName(cwd: string): string;
|
|
7
|
-
lastTagHash(cwd: any): string;
|
|
8
|
-
lastCommitDate(cwd: string): Date;
|
|
9
|
-
lastCommitMessage(cwd: any): string;
|
|
10
|
-
countCommits(cwd: string): number;
|
|
11
|
-
hasAnyCommits(cwd: string): boolean;
|
|
12
|
-
isInMergeProcess(cwd: string): boolean;
|
|
13
|
-
getBranchesNames(cwd: string, pattern?: string | RegExp): string[];
|
|
14
|
-
currentBranchName(cwd: any): string;
|
|
15
|
-
commitWhatIs(cwd: string, customMessage?: string): void;
|
|
16
|
-
commit(cwd: string, ProjectClass: typeof Project, args?: string): void;
|
|
17
|
-
/**
|
|
18
|
-
* example: https://github.com/darekf77/tnp-helpers.git
|
|
19
|
-
*
|
|
20
|
-
* Note: address ends with .git always
|
|
21
|
-
*
|
|
22
|
-
*/
|
|
23
|
-
getOriginURL(cwd: string, differentOriginName?: string): string;
|
|
24
|
-
isGitRoot(cwd: string): boolean;
|
|
25
|
-
isGitRepo(cwd: string): boolean;
|
|
26
|
-
private pull;
|
|
27
|
-
pullBranch(branchName: string, cwd: string, askToRetry?: boolean): Promise<void>;
|
|
28
|
-
pullCurrentBranch(cwd: string, askToRetry?: boolean): Promise<void>;
|
|
29
|
-
pushCurrentBranch(cwd: string, force?: boolean, origin?: string): void;
|
|
30
|
-
defaultRepoBranch(cwd: string): string;
|
|
31
|
-
checkoutDefaultBranch(cwd: any): void;
|
|
32
|
-
clone({ cwd, url, destinationFolderName, throwErrors, override }: {
|
|
33
|
-
cwd: string;
|
|
34
|
-
url: string;
|
|
35
|
-
destinationFolderName?: string;
|
|
36
|
-
throwErrors?: boolean;
|
|
37
|
-
override?: boolean;
|
|
38
|
-
}): void;
|
|
39
|
-
checkIfthereAreSomeUncommitedChange(cwd: string): boolean;
|
|
40
|
-
thereAreSomeUncommitedChangeExcept(filesList: string[], cwd: string): boolean;
|
|
41
|
-
restoreLastVersion(cwd: string, localFilePath: string): void;
|
|
42
|
-
resetFiles(cwd: string, ...relativePathes: string[]): void;
|
|
43
|
-
}
|
|
1
|
+
import type { Project } from './project';
|
|
2
|
+
export declare class HelpersGit {
|
|
3
|
+
lastCommitHash(cwd: any): string;
|
|
4
|
+
penultimageCommitHash(cwd: any): string;
|
|
5
|
+
checkTagExists(tag: string, cwd?: string): boolean;
|
|
6
|
+
lastTagVersionName(cwd: string): string;
|
|
7
|
+
lastTagHash(cwd: any): string;
|
|
8
|
+
lastCommitDate(cwd: string): Date;
|
|
9
|
+
lastCommitMessage(cwd: any): string;
|
|
10
|
+
countCommits(cwd: string): number;
|
|
11
|
+
hasAnyCommits(cwd: string): boolean;
|
|
12
|
+
isInMergeProcess(cwd: string): boolean;
|
|
13
|
+
getBranchesNames(cwd: string, pattern?: string | RegExp): string[];
|
|
14
|
+
currentBranchName(cwd: any): string;
|
|
15
|
+
commitWhatIs(cwd: string, customMessage?: string): void;
|
|
16
|
+
commit(cwd: string, ProjectClass: typeof Project, args?: string): void;
|
|
17
|
+
/**
|
|
18
|
+
* example: https://github.com/darekf77/tnp-helpers.git
|
|
19
|
+
*
|
|
20
|
+
* Note: address ends with .git always
|
|
21
|
+
*
|
|
22
|
+
*/
|
|
23
|
+
getOriginURL(cwd: string, differentOriginName?: string): string;
|
|
24
|
+
isGitRoot(cwd: string): boolean;
|
|
25
|
+
isGitRepo(cwd: string): boolean;
|
|
26
|
+
private pull;
|
|
27
|
+
pullBranch(branchName: string, cwd: string, askToRetry?: boolean): Promise<void>;
|
|
28
|
+
pullCurrentBranch(cwd: string, askToRetry?: boolean): Promise<void>;
|
|
29
|
+
pushCurrentBranch(cwd: string, force?: boolean, origin?: string): void;
|
|
30
|
+
defaultRepoBranch(cwd: string): string;
|
|
31
|
+
checkoutDefaultBranch(cwd: any): void;
|
|
32
|
+
clone({ cwd, url, destinationFolderName, throwErrors, override }: {
|
|
33
|
+
cwd: string;
|
|
34
|
+
url: string;
|
|
35
|
+
destinationFolderName?: string;
|
|
36
|
+
throwErrors?: boolean;
|
|
37
|
+
override?: boolean;
|
|
38
|
+
}): void;
|
|
39
|
+
checkIfthereAreSomeUncommitedChange(cwd: string): boolean;
|
|
40
|
+
thereAreSomeUncommitedChangeExcept(filesList: string[], cwd: string): boolean;
|
|
41
|
+
restoreLastVersion(cwd: string, localFilePath: string): void;
|
|
42
|
+
resetFiles(cwd: string, ...relativePathes: string[]): void;
|
|
43
|
+
}
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
export declare class JSON5Helpers<STRUCTURE = {}> {
|
|
2
|
-
private filePath;
|
|
3
|
-
private defaultValue;
|
|
4
|
-
private isDataReadFirstTime;
|
|
5
|
-
constructor(filePath: string, defaultValue?: {});
|
|
6
|
-
private fileContent;
|
|
7
|
-
get readOnlyData(): STRUCTURE;
|
|
8
|
-
private get writeInstance();
|
|
9
|
-
read(): void;
|
|
10
|
-
update(data: STRUCTURE): void;
|
|
11
|
-
save(): void;
|
|
12
|
-
}
|
|
13
|
-
export declare class HelpersJSON5 {
|
|
14
|
-
fromFile<STRUCTURE = {}>(filePath: string): JSON5Helpers<STRUCTURE>;
|
|
15
|
-
allFrom<STRUCTURE = {}>(folderPath: string): JSON5Helpers<STRUCTURE>[];
|
|
16
|
-
}
|
|
1
|
+
export declare class JSON5Helpers<STRUCTURE = {}> {
|
|
2
|
+
private filePath;
|
|
3
|
+
private defaultValue;
|
|
4
|
+
private isDataReadFirstTime;
|
|
5
|
+
constructor(filePath: string, defaultValue?: {});
|
|
6
|
+
private fileContent;
|
|
7
|
+
get readOnlyData(): STRUCTURE;
|
|
8
|
+
private get writeInstance();
|
|
9
|
+
read(): void;
|
|
10
|
+
update(data: STRUCTURE): void;
|
|
11
|
+
save(): void;
|
|
12
|
+
}
|
|
13
|
+
export declare class HelpersJSON5 {
|
|
14
|
+
fromFile<STRUCTURE = {}>(filePath: string): JSON5Helpers<STRUCTURE>;
|
|
15
|
+
allFrom<STRUCTURE = {}>(folderPath: string): JSON5Helpers<STRUCTURE>[];
|
|
16
|
+
}
|