@teambit/stash 1.0.228 → 1.0.230
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/artifacts/__bit_junit.xml +1 -1
- package/artifacts/schema.json +95 -21
- package/dist/index.d.ts +4 -0
- package/dist/stash-data.d.ts +23 -0
- package/dist/stash-files.d.ts +13 -0
- package/dist/stash.aspect.d.ts +2 -0
- package/dist/stash.cmd.d.ts +56 -0
- package/dist/stash.main.runtime.d.ts +29 -0
- package/package.json +8 -8
- package/tsconfig.json +1 -19
- /package/dist/{preview-1712805335812.js → preview-1712891953391.js} +0 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
2
|
<testsuites tests="0" failures="0" errors="0" skipped="0">
|
|
3
|
-
<testsuite name="teambit.component/stash@1.0.
|
|
3
|
+
<testsuite name="teambit.component/stash@1.0.230" tests="0" failures="0" errors="0" skipped="0"/>
|
|
4
4
|
</testsuites>
|
package/artifacts/schema.json
CHANGED
|
@@ -48,7 +48,11 @@
|
|
|
48
48
|
"line": 23,
|
|
49
49
|
"character": 34
|
|
50
50
|
},
|
|
51
|
-
"name": "Workspace"
|
|
51
|
+
"name": "Workspace",
|
|
52
|
+
"componentId": {
|
|
53
|
+
"scope": "teambit.workspace",
|
|
54
|
+
"name": "workspace"
|
|
55
|
+
}
|
|
52
56
|
},
|
|
53
57
|
"isOptional": false,
|
|
54
58
|
"isSpread": false
|
|
@@ -68,7 +72,11 @@
|
|
|
68
72
|
"line": 23,
|
|
69
73
|
"character": 63
|
|
70
74
|
},
|
|
71
|
-
"name": "CheckoutMain"
|
|
75
|
+
"name": "CheckoutMain",
|
|
76
|
+
"componentId": {
|
|
77
|
+
"scope": "teambit.component",
|
|
78
|
+
"name": "checkout"
|
|
79
|
+
}
|
|
72
80
|
},
|
|
73
81
|
"isOptional": false,
|
|
74
82
|
"isSpread": false
|
|
@@ -88,7 +96,11 @@
|
|
|
88
96
|
"line": 23,
|
|
89
97
|
"character": 95
|
|
90
98
|
},
|
|
91
|
-
"name": "SnappingMain"
|
|
99
|
+
"name": "SnappingMain",
|
|
100
|
+
"componentId": {
|
|
101
|
+
"scope": "teambit.component",
|
|
102
|
+
"name": "snapping"
|
|
103
|
+
}
|
|
92
104
|
},
|
|
93
105
|
"isOptional": false,
|
|
94
106
|
"isSpread": false
|
|
@@ -200,7 +212,11 @@
|
|
|
200
212
|
"line": 27,
|
|
201
213
|
"character": 72
|
|
202
214
|
},
|
|
203
|
-
"name": "ComponentID"
|
|
215
|
+
"name": "ComponentID",
|
|
216
|
+
"componentId": {
|
|
217
|
+
"scope": "teambit.component",
|
|
218
|
+
"name": "component"
|
|
219
|
+
}
|
|
204
220
|
}
|
|
205
221
|
}
|
|
206
222
|
]
|
|
@@ -242,7 +258,8 @@
|
|
|
242
258
|
"line": 66,
|
|
243
259
|
"character": 25
|
|
244
260
|
},
|
|
245
|
-
"name": "ListResult"
|
|
261
|
+
"name": "ListResult",
|
|
262
|
+
"internalFilePath": "stash.main.runtime.ts"
|
|
246
263
|
}
|
|
247
264
|
}
|
|
248
265
|
]
|
|
@@ -276,7 +293,11 @@
|
|
|
276
293
|
"line": 80,
|
|
277
294
|
"character": 35
|
|
278
295
|
},
|
|
279
|
-
"name": "CheckoutProps"
|
|
296
|
+
"name": "CheckoutProps",
|
|
297
|
+
"componentId": {
|
|
298
|
+
"scope": "teambit.component",
|
|
299
|
+
"name": "checkout"
|
|
300
|
+
}
|
|
280
301
|
},
|
|
281
302
|
"isOptional": true,
|
|
282
303
|
"defaultValue": "{}",
|
|
@@ -412,7 +433,11 @@
|
|
|
412
433
|
"line": 128,
|
|
413
434
|
"character": 64
|
|
414
435
|
},
|
|
415
|
-
"name": "CLIMain"
|
|
436
|
+
"name": "CLIMain",
|
|
437
|
+
"componentId": {
|
|
438
|
+
"scope": "teambit.harmony",
|
|
439
|
+
"name": "cli"
|
|
440
|
+
}
|
|
416
441
|
},
|
|
417
442
|
{
|
|
418
443
|
"__schema": "TypeRefSchema",
|
|
@@ -421,7 +446,11 @@
|
|
|
421
446
|
"line": 128,
|
|
422
447
|
"character": 73
|
|
423
448
|
},
|
|
424
|
-
"name": "Workspace"
|
|
449
|
+
"name": "Workspace",
|
|
450
|
+
"componentId": {
|
|
451
|
+
"scope": "teambit.workspace",
|
|
452
|
+
"name": "workspace"
|
|
453
|
+
}
|
|
425
454
|
},
|
|
426
455
|
{
|
|
427
456
|
"__schema": "TypeRefSchema",
|
|
@@ -430,7 +459,11 @@
|
|
|
430
459
|
"line": 128,
|
|
431
460
|
"character": 84
|
|
432
461
|
},
|
|
433
|
-
"name": "CheckoutMain"
|
|
462
|
+
"name": "CheckoutMain",
|
|
463
|
+
"componentId": {
|
|
464
|
+
"scope": "teambit.component",
|
|
465
|
+
"name": "checkout"
|
|
466
|
+
}
|
|
434
467
|
},
|
|
435
468
|
{
|
|
436
469
|
"__schema": "TypeRefSchema",
|
|
@@ -439,7 +472,11 @@
|
|
|
439
472
|
"line": 128,
|
|
440
473
|
"character": 98
|
|
441
474
|
},
|
|
442
|
-
"name": "SnappingMain"
|
|
475
|
+
"name": "SnappingMain",
|
|
476
|
+
"componentId": {
|
|
477
|
+
"scope": "teambit.component",
|
|
478
|
+
"name": "snapping"
|
|
479
|
+
}
|
|
443
480
|
}
|
|
444
481
|
]
|
|
445
482
|
},
|
|
@@ -548,7 +585,11 @@
|
|
|
548
585
|
"line": 23,
|
|
549
586
|
"character": 34
|
|
550
587
|
},
|
|
551
|
-
"name": "Workspace"
|
|
588
|
+
"name": "Workspace",
|
|
589
|
+
"componentId": {
|
|
590
|
+
"scope": "teambit.workspace",
|
|
591
|
+
"name": "workspace"
|
|
592
|
+
}
|
|
552
593
|
},
|
|
553
594
|
"isOptional": false,
|
|
554
595
|
"isSpread": false
|
|
@@ -568,7 +609,11 @@
|
|
|
568
609
|
"line": 23,
|
|
569
610
|
"character": 63
|
|
570
611
|
},
|
|
571
|
-
"name": "CheckoutMain"
|
|
612
|
+
"name": "CheckoutMain",
|
|
613
|
+
"componentId": {
|
|
614
|
+
"scope": "teambit.component",
|
|
615
|
+
"name": "checkout"
|
|
616
|
+
}
|
|
572
617
|
},
|
|
573
618
|
"isOptional": false,
|
|
574
619
|
"isSpread": false
|
|
@@ -588,7 +633,11 @@
|
|
|
588
633
|
"line": 23,
|
|
589
634
|
"character": 95
|
|
590
635
|
},
|
|
591
|
-
"name": "SnappingMain"
|
|
636
|
+
"name": "SnappingMain",
|
|
637
|
+
"componentId": {
|
|
638
|
+
"scope": "teambit.component",
|
|
639
|
+
"name": "snapping"
|
|
640
|
+
}
|
|
592
641
|
},
|
|
593
642
|
"isOptional": false,
|
|
594
643
|
"isSpread": false
|
|
@@ -700,7 +749,11 @@
|
|
|
700
749
|
"line": 27,
|
|
701
750
|
"character": 72
|
|
702
751
|
},
|
|
703
|
-
"name": "ComponentID"
|
|
752
|
+
"name": "ComponentID",
|
|
753
|
+
"componentId": {
|
|
754
|
+
"scope": "teambit.component",
|
|
755
|
+
"name": "component"
|
|
756
|
+
}
|
|
704
757
|
}
|
|
705
758
|
}
|
|
706
759
|
]
|
|
@@ -742,7 +795,8 @@
|
|
|
742
795
|
"line": 66,
|
|
743
796
|
"character": 25
|
|
744
797
|
},
|
|
745
|
-
"name": "ListResult"
|
|
798
|
+
"name": "ListResult",
|
|
799
|
+
"internalFilePath": "stash.main.runtime.ts"
|
|
746
800
|
}
|
|
747
801
|
}
|
|
748
802
|
]
|
|
@@ -776,7 +830,11 @@
|
|
|
776
830
|
"line": 80,
|
|
777
831
|
"character": 35
|
|
778
832
|
},
|
|
779
|
-
"name": "CheckoutProps"
|
|
833
|
+
"name": "CheckoutProps",
|
|
834
|
+
"componentId": {
|
|
835
|
+
"scope": "teambit.component",
|
|
836
|
+
"name": "checkout"
|
|
837
|
+
}
|
|
780
838
|
},
|
|
781
839
|
"isOptional": true,
|
|
782
840
|
"defaultValue": "{}",
|
|
@@ -912,7 +970,11 @@
|
|
|
912
970
|
"line": 128,
|
|
913
971
|
"character": 64
|
|
914
972
|
},
|
|
915
|
-
"name": "CLIMain"
|
|
973
|
+
"name": "CLIMain",
|
|
974
|
+
"componentId": {
|
|
975
|
+
"scope": "teambit.harmony",
|
|
976
|
+
"name": "cli"
|
|
977
|
+
}
|
|
916
978
|
},
|
|
917
979
|
{
|
|
918
980
|
"__schema": "TypeRefSchema",
|
|
@@ -921,7 +983,11 @@
|
|
|
921
983
|
"line": 128,
|
|
922
984
|
"character": 73
|
|
923
985
|
},
|
|
924
|
-
"name": "Workspace"
|
|
986
|
+
"name": "Workspace",
|
|
987
|
+
"componentId": {
|
|
988
|
+
"scope": "teambit.workspace",
|
|
989
|
+
"name": "workspace"
|
|
990
|
+
}
|
|
925
991
|
},
|
|
926
992
|
{
|
|
927
993
|
"__schema": "TypeRefSchema",
|
|
@@ -930,7 +996,11 @@
|
|
|
930
996
|
"line": 128,
|
|
931
997
|
"character": 84
|
|
932
998
|
},
|
|
933
|
-
"name": "CheckoutMain"
|
|
999
|
+
"name": "CheckoutMain",
|
|
1000
|
+
"componentId": {
|
|
1001
|
+
"scope": "teambit.component",
|
|
1002
|
+
"name": "checkout"
|
|
1003
|
+
}
|
|
934
1004
|
},
|
|
935
1005
|
{
|
|
936
1006
|
"__schema": "TypeRefSchema",
|
|
@@ -939,7 +1009,11 @@
|
|
|
939
1009
|
"line": 128,
|
|
940
1010
|
"character": 98
|
|
941
1011
|
},
|
|
942
|
-
"name": "SnappingMain"
|
|
1012
|
+
"name": "SnappingMain",
|
|
1013
|
+
"componentId": {
|
|
1014
|
+
"scope": "teambit.component",
|
|
1015
|
+
"name": "snapping"
|
|
1016
|
+
}
|
|
943
1017
|
}
|
|
944
1018
|
]
|
|
945
1019
|
},
|
|
@@ -1118,7 +1192,7 @@
|
|
|
1118
1192
|
"componentId": {
|
|
1119
1193
|
"scope": "teambit.component",
|
|
1120
1194
|
"name": "stash",
|
|
1121
|
-
"version": "1.0.
|
|
1195
|
+
"version": "1.0.230"
|
|
1122
1196
|
},
|
|
1123
1197
|
"taggedModuleExports": []
|
|
1124
1198
|
}
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { ComponentID, ComponentIdObj } from '@teambit/component-id';
|
|
2
|
+
export type StashCompData = {
|
|
3
|
+
id: ComponentID;
|
|
4
|
+
hash: string;
|
|
5
|
+
};
|
|
6
|
+
export type StashCompDataWithIdObj = {
|
|
7
|
+
id: ComponentIdObj;
|
|
8
|
+
hash: string;
|
|
9
|
+
};
|
|
10
|
+
export type StashMetadata = {
|
|
11
|
+
message?: string;
|
|
12
|
+
};
|
|
13
|
+
export type StashDataObj = {
|
|
14
|
+
metadata: StashMetadata;
|
|
15
|
+
stashCompsData: StashCompDataWithIdObj[];
|
|
16
|
+
};
|
|
17
|
+
export declare class StashData {
|
|
18
|
+
readonly metadata: StashMetadata;
|
|
19
|
+
readonly stashCompsData: StashCompData[];
|
|
20
|
+
constructor(metadata: StashMetadata, stashCompsData: StashCompData[]);
|
|
21
|
+
toObject(): StashDataObj;
|
|
22
|
+
static fromObject(obj: Record<string, any>): Promise<StashData>;
|
|
23
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { Workspace } from '@teambit/workspace';
|
|
2
|
+
import { StashData } from './stash-data';
|
|
3
|
+
export declare class StashFiles {
|
|
4
|
+
private workspace;
|
|
5
|
+
constructor(workspace: Workspace);
|
|
6
|
+
getPath(): string;
|
|
7
|
+
getStashFiles(): Promise<string[]>;
|
|
8
|
+
getLatestStashFile(): Promise<string | undefined>;
|
|
9
|
+
getNextStashFileName(): Promise<string>;
|
|
10
|
+
deleteStashFile(filename: string): Promise<void>;
|
|
11
|
+
saveStashData(stashData: StashData): Promise<void>;
|
|
12
|
+
getStashData(filename: string): Promise<StashData>;
|
|
13
|
+
}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { MergeStrategy } from '@teambit/legacy/dist/consumer/versions-ops/merge-version';
|
|
2
|
+
import { Command, CommandOptions } from '@teambit/cli';
|
|
3
|
+
import { StashMain } from './stash.main.runtime';
|
|
4
|
+
export declare class StashSaveCmd implements Command {
|
|
5
|
+
private stash;
|
|
6
|
+
name: string;
|
|
7
|
+
alias: string;
|
|
8
|
+
description: string;
|
|
9
|
+
group: string;
|
|
10
|
+
options: CommandOptions;
|
|
11
|
+
loader: boolean;
|
|
12
|
+
constructor(stash: StashMain);
|
|
13
|
+
report(_arg: any, { pattern, message, }: {
|
|
14
|
+
pattern?: string;
|
|
15
|
+
message?: string;
|
|
16
|
+
}): Promise<string>;
|
|
17
|
+
}
|
|
18
|
+
export declare class StashListCmd implements Command {
|
|
19
|
+
private stash;
|
|
20
|
+
name: string;
|
|
21
|
+
description: string;
|
|
22
|
+
group: string;
|
|
23
|
+
options: CommandOptions;
|
|
24
|
+
loader: boolean;
|
|
25
|
+
constructor(stash: StashMain);
|
|
26
|
+
report(): Promise<string>;
|
|
27
|
+
}
|
|
28
|
+
type StashLoadOpts = {
|
|
29
|
+
autoMergeResolve?: MergeStrategy;
|
|
30
|
+
manual?: boolean;
|
|
31
|
+
forceOurs?: boolean;
|
|
32
|
+
forceTheirs?: boolean;
|
|
33
|
+
};
|
|
34
|
+
export declare class StashLoadCmd implements Command {
|
|
35
|
+
private stash;
|
|
36
|
+
name: string;
|
|
37
|
+
alias: string;
|
|
38
|
+
description: string;
|
|
39
|
+
group: string;
|
|
40
|
+
options: CommandOptions;
|
|
41
|
+
loader: boolean;
|
|
42
|
+
constructor(stash: StashMain);
|
|
43
|
+
report([stashId]: [string], { autoMergeResolve, forceOurs, forceTheirs, manual }: StashLoadOpts): Promise<string>;
|
|
44
|
+
}
|
|
45
|
+
export declare class StashCmd implements Command {
|
|
46
|
+
private stash;
|
|
47
|
+
name: string;
|
|
48
|
+
description: string;
|
|
49
|
+
group: string;
|
|
50
|
+
options: CommandOptions;
|
|
51
|
+
loader: boolean;
|
|
52
|
+
commands: Command[];
|
|
53
|
+
constructor(stash: StashMain);
|
|
54
|
+
report([unrecognizedSubcommand]: [string]): Promise<string>;
|
|
55
|
+
}
|
|
56
|
+
export {};
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { Workspace } from '@teambit/workspace';
|
|
2
|
+
import { SnappingMain } from '@teambit/snapping';
|
|
3
|
+
import { ComponentID } from '@teambit/component';
|
|
4
|
+
import { CLIMain } from '@teambit/cli';
|
|
5
|
+
import { CheckoutMain, CheckoutProps } from '@teambit/checkout';
|
|
6
|
+
type ListResult = {
|
|
7
|
+
id: string;
|
|
8
|
+
message?: string;
|
|
9
|
+
components: string[];
|
|
10
|
+
};
|
|
11
|
+
export declare class StashMain {
|
|
12
|
+
private workspace;
|
|
13
|
+
private checkout;
|
|
14
|
+
private snapping;
|
|
15
|
+
private stashFiles;
|
|
16
|
+
constructor(workspace: Workspace, checkout: CheckoutMain, snapping: SnappingMain);
|
|
17
|
+
save(options: {
|
|
18
|
+
message?: string;
|
|
19
|
+
pattern?: string;
|
|
20
|
+
}): Promise<ComponentID[]>;
|
|
21
|
+
list(): Promise<ListResult[]>;
|
|
22
|
+
loadLatest(checkoutProps?: CheckoutProps, stashId?: string): Promise<ComponentID[]>;
|
|
23
|
+
private addComponentDataToRepo;
|
|
24
|
+
static slots: never[];
|
|
25
|
+
static dependencies: import("@teambit/harmony").Aspect[];
|
|
26
|
+
static runtime: import("@teambit/harmony").RuntimeDefinition;
|
|
27
|
+
static provider([cli, workspace, checkout, snapping]: [CLIMain, Workspace, CheckoutMain, SnappingMain]): Promise<StashMain>;
|
|
28
|
+
}
|
|
29
|
+
export default StashMain;
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@teambit/stash",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.230",
|
|
4
4
|
"homepage": "https://bit.cloud/teambit/component/stash",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"componentId": {
|
|
7
7
|
"scope": "teambit.component",
|
|
8
8
|
"name": "stash",
|
|
9
|
-
"version": "1.0.
|
|
9
|
+
"version": "1.0.230"
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"fs-extra": "10.0.0",
|
|
@@ -16,18 +16,18 @@
|
|
|
16
16
|
"@teambit/component-id": "1.2.0",
|
|
17
17
|
"@teambit/harmony": "0.4.6",
|
|
18
18
|
"@teambit/bit-error": "0.0.404",
|
|
19
|
-
"@teambit/workspace": "1.0.
|
|
20
|
-
"@teambit/checkout": "1.0.
|
|
21
|
-
"@teambit/cli": "0.0.
|
|
22
|
-
"@teambit/component": "1.0.
|
|
23
|
-
"@teambit/snapping": "1.0.
|
|
19
|
+
"@teambit/workspace": "1.0.230",
|
|
20
|
+
"@teambit/checkout": "1.0.230",
|
|
21
|
+
"@teambit/cli": "0.0.862",
|
|
22
|
+
"@teambit/component": "1.0.230",
|
|
23
|
+
"@teambit/snapping": "1.0.230"
|
|
24
24
|
},
|
|
25
25
|
"devDependencies": {
|
|
26
26
|
"@types/fs-extra": "9.0.7",
|
|
27
27
|
"@types/lodash": "4.14.165",
|
|
28
28
|
"@types/mocha": "9.1.0",
|
|
29
29
|
"chai": "4.3.0",
|
|
30
|
-
"@teambit/harmony.envs.core-aspect-env": "0.0.
|
|
30
|
+
"@teambit/harmony.envs.core-aspect-env": "0.0.33"
|
|
31
31
|
},
|
|
32
32
|
"peerDependencies": {
|
|
33
33
|
"@teambit/legacy": "1.0.624"
|
package/tsconfig.json
CHANGED
|
@@ -20,8 +20,7 @@
|
|
|
20
20
|
"emitDeclarationOnly": true,
|
|
21
21
|
"strict": true,
|
|
22
22
|
"strictPropertyInitialization": false,
|
|
23
|
-
"noImplicitAny": false
|
|
24
|
-
"composite": true
|
|
23
|
+
"noImplicitAny": false
|
|
25
24
|
},
|
|
26
25
|
"exclude": [
|
|
27
26
|
"artifacts",
|
|
@@ -36,22 +35,5 @@
|
|
|
36
35
|
"include": [
|
|
37
36
|
"**/*",
|
|
38
37
|
"**/*.json"
|
|
39
|
-
],
|
|
40
|
-
"references": [
|
|
41
|
-
{
|
|
42
|
-
"path": "/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.workspace_workspace@1.0.228"
|
|
43
|
-
},
|
|
44
|
-
{
|
|
45
|
-
"path": "/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.component_checkout@1.0.228"
|
|
46
|
-
},
|
|
47
|
-
{
|
|
48
|
-
"path": "/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.harmony_cli@0.0.861"
|
|
49
|
-
},
|
|
50
|
-
{
|
|
51
|
-
"path": "/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.component_component@1.0.228"
|
|
52
|
-
},
|
|
53
|
-
{
|
|
54
|
-
"path": "/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.component_snapping@1.0.228"
|
|
55
|
-
}
|
|
56
38
|
]
|
|
57
39
|
}
|
|
File without changes
|