@teambit/clear-cache 0.0.152 → 0.0.153
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/dist/clear-cache-action.js +0 -8
- package/dist/clear-cache-action.js.map +1 -1
- package/dist/clear-cache-cmd.js +0 -15
- package/dist/clear-cache-cmd.js.map +1 -1
- package/dist/clear-cache.aspect.js +0 -5
- package/dist/clear-cache.aspect.js.map +1 -1
- package/dist/clear-cache.composition.js +0 -6
- package/dist/clear-cache.composition.js.map +1 -1
- package/dist/clear-cache.main.runtime.js +0 -46
- package/dist/clear-cache.main.runtime.js.map +1 -1
- package/dist/index.js +0 -5
- package/dist/index.js.map +1 -1
- package/package-tar/teambit-clear-cache-0.0.153.tgz +0 -0
- package/package.json +3 -3
- package/{preview-1666409808293.js → preview-1666669368175.js} +2 -2
- package/package-tar/teambit-clear-cache-0.0.152.tgz +0 -0
|
@@ -1,36 +1,28 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
-
|
|
5
4
|
Object.defineProperty(exports, "__esModule", {
|
|
6
5
|
value: true
|
|
7
6
|
});
|
|
8
7
|
exports.ClearCacheAction = void 0;
|
|
9
|
-
|
|
10
8
|
function _defineProperty2() {
|
|
11
9
|
const data = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
12
|
-
|
|
13
10
|
_defineProperty2 = function () {
|
|
14
11
|
return data;
|
|
15
12
|
};
|
|
16
|
-
|
|
17
13
|
return data;
|
|
18
14
|
}
|
|
19
|
-
|
|
20
15
|
class ClearCacheAction {
|
|
21
16
|
constructor(scope) {
|
|
22
17
|
this.scope = scope;
|
|
23
18
|
(0, _defineProperty2().default)(this, "name", ClearCacheAction.name);
|
|
24
19
|
}
|
|
25
|
-
|
|
26
20
|
execute() {
|
|
27
21
|
if (!this.scope) return false;
|
|
28
22
|
this.scope.clearCache();
|
|
29
23
|
return true;
|
|
30
24
|
}
|
|
31
|
-
|
|
32
25
|
}
|
|
33
|
-
|
|
34
26
|
exports.ClearCacheAction = ClearCacheAction;
|
|
35
27
|
|
|
36
28
|
//# sourceMappingURL=clear-cache-action.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["ClearCacheAction","constructor","scope","name","execute","clearCache"],"sources":["clear-cache-action.ts"],"sourcesContent":["import { ScopeMain } from '@teambit/scope';\n\nexport class ClearCacheAction {\n name = ClearCacheAction.name;\n constructor(private scope: ScopeMain) {}\n execute() {\n if (!this.scope) return false;\n this.scope.clearCache();\n return true;\n }\n}\n"],"mappings":"
|
|
1
|
+
{"version":3,"names":["ClearCacheAction","constructor","scope","name","execute","clearCache"],"sources":["clear-cache-action.ts"],"sourcesContent":["import { ScopeMain } from '@teambit/scope';\n\nexport class ClearCacheAction {\n name = ClearCacheAction.name;\n constructor(private scope: ScopeMain) {}\n execute() {\n if (!this.scope) return false;\n this.scope.clearCache();\n return true;\n }\n}\n"],"mappings":";;;;;;;;;;;;;;AAEO,MAAMA,gBAAgB,CAAC;EAE5BC,WAAW,CAASC,KAAgB,EAAE;IAAA,KAAlBA,KAAgB,GAAhBA,KAAgB;IAAA,8CAD7BF,gBAAgB,CAACG,IAAI;EACW;EACvCC,OAAO,GAAG;IACR,IAAI,CAAC,IAAI,CAACF,KAAK,EAAE,OAAO,KAAK;IAC7B,IAAI,CAACA,KAAK,CAACG,UAAU,EAAE;IACvB,OAAO,IAAI;EACb;AACF;AAAC"}
|
package/dist/clear-cache-cmd.js
CHANGED
|
@@ -1,34 +1,25 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
-
|
|
5
4
|
require("core-js/modules/es.promise.js");
|
|
6
|
-
|
|
7
5
|
Object.defineProperty(exports, "__esModule", {
|
|
8
6
|
value: true
|
|
9
7
|
});
|
|
10
8
|
exports.default = void 0;
|
|
11
|
-
|
|
12
9
|
function _defineProperty2() {
|
|
13
10
|
const data = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
14
|
-
|
|
15
11
|
_defineProperty2 = function () {
|
|
16
12
|
return data;
|
|
17
13
|
};
|
|
18
|
-
|
|
19
14
|
return data;
|
|
20
15
|
}
|
|
21
|
-
|
|
22
16
|
function _chalk() {
|
|
23
17
|
const data = _interopRequireDefault(require("chalk"));
|
|
24
|
-
|
|
25
18
|
_chalk = function () {
|
|
26
19
|
return data;
|
|
27
20
|
};
|
|
28
|
-
|
|
29
21
|
return data;
|
|
30
22
|
}
|
|
31
|
-
|
|
32
23
|
class ClearCacheCmd {
|
|
33
24
|
constructor(clearCache, docsDomain) {
|
|
34
25
|
this.clearCache = clearCache;
|
|
@@ -47,28 +38,22 @@ class ClearCacheCmd {
|
|
|
47
38
|
3) scope's index file, which maps the component-id:object-hash
|
|
48
39
|
https://${docsDomain}/workspace/clearing-cache`;
|
|
49
40
|
}
|
|
50
|
-
|
|
51
41
|
async report(arg, {
|
|
52
42
|
remote
|
|
53
43
|
}) {
|
|
54
44
|
if (remote) {
|
|
55
45
|
const success = await this.clearCache.clearRemoteCache(remote);
|
|
56
|
-
|
|
57
46
|
if (success) {
|
|
58
47
|
return _chalk().default.green(`successfully cleaned the cache of "${remote}"`);
|
|
59
48
|
}
|
|
60
|
-
|
|
61
49
|
return _chalk().default.red(`failed cleaning the cache of "${remote}"`);
|
|
62
50
|
}
|
|
63
|
-
|
|
64
51
|
const cacheCleared = await this.clearCache.clearCache();
|
|
65
52
|
const title = 'the following cache(s) have been cleared:';
|
|
66
53
|
const output = cacheCleared.map(str => ` ✔ ${str}`).join('\n');
|
|
67
54
|
return _chalk().default.green(`${_chalk().default.bold(title)}\n${output}`);
|
|
68
55
|
}
|
|
69
|
-
|
|
70
56
|
}
|
|
71
|
-
|
|
72
57
|
exports.default = ClearCacheCmd;
|
|
73
58
|
|
|
74
59
|
//# sourceMappingURL=clear-cache-cmd.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["ClearCacheCmd","constructor","clearCache","docsDomain","extendedDescription","report","arg","remote","success","clearRemoteCache","chalk","green","red","cacheCleared","title","output","map","str","join","bold"],"sources":["clear-cache-cmd.ts"],"sourcesContent":["import { Command, CommandOptions } from '@teambit/cli';\nimport chalk from 'chalk';\nimport { ClearCacheMain } from './clear-cache.main.runtime';\n\nexport default class ClearCacheCmd implements Command {\n name = 'clear-cache';\n description = \"clears Bit's cache from current working machine\";\n group = 'general';\n extendedDescription: string;\n alias = 'cc';\n options = [['r', 'remote <remote-name>', 'clear memory cache from a remote scope']] as CommandOptions;\n loader = false;\n skipWorkspace = true;\n\n constructor(private clearCache: ClearCacheMain, private docsDomain: string) {\n this.extendedDescription = `The following gets removed by this command:\n1) V8 compiled code (generated the first time Bit is loaded by v8-compile-cache package)\n2) components cache on the filesystem (mainly the dependencies graph and docs)\n3) scope's index file, which maps the component-id:object-hash\nhttps://${docsDomain}/workspace/clearing-cache`;\n }\n\n async report(arg, { remote }: { remote?: string }): Promise<string> {\n if (remote) {\n const success = await this.clearCache.clearRemoteCache(remote);\n if (success) {\n return chalk.green(`successfully cleaned the cache of \"${remote}\"`);\n }\n return chalk.red(`failed cleaning the cache of \"${remote}\"`);\n }\n const cacheCleared = await this.clearCache.clearCache();\n const title = 'the following cache(s) have been cleared:';\n const output = cacheCleared.map((str) => ` ✔ ${str}`).join('\\n');\n return chalk.green(`${chalk.bold(title)}\\n${output}`);\n }\n}\n"],"mappings":"
|
|
1
|
+
{"version":3,"names":["ClearCacheCmd","constructor","clearCache","docsDomain","extendedDescription","report","arg","remote","success","clearRemoteCache","chalk","green","red","cacheCleared","title","output","map","str","join","bold"],"sources":["clear-cache-cmd.ts"],"sourcesContent":["import { Command, CommandOptions } from '@teambit/cli';\nimport chalk from 'chalk';\nimport { ClearCacheMain } from './clear-cache.main.runtime';\n\nexport default class ClearCacheCmd implements Command {\n name = 'clear-cache';\n description = \"clears Bit's cache from current working machine\";\n group = 'general';\n extendedDescription: string;\n alias = 'cc';\n options = [['r', 'remote <remote-name>', 'clear memory cache from a remote scope']] as CommandOptions;\n loader = false;\n skipWorkspace = true;\n\n constructor(private clearCache: ClearCacheMain, private docsDomain: string) {\n this.extendedDescription = `The following gets removed by this command:\n1) V8 compiled code (generated the first time Bit is loaded by v8-compile-cache package)\n2) components cache on the filesystem (mainly the dependencies graph and docs)\n3) scope's index file, which maps the component-id:object-hash\nhttps://${docsDomain}/workspace/clearing-cache`;\n }\n\n async report(arg, { remote }: { remote?: string }): Promise<string> {\n if (remote) {\n const success = await this.clearCache.clearRemoteCache(remote);\n if (success) {\n return chalk.green(`successfully cleaned the cache of \"${remote}\"`);\n }\n return chalk.red(`failed cleaning the cache of \"${remote}\"`);\n }\n const cacheCleared = await this.clearCache.clearCache();\n const title = 'the following cache(s) have been cleared:';\n const output = cacheCleared.map((str) => ` ✔ ${str}`).join('\\n');\n return chalk.green(`${chalk.bold(title)}\\n${output}`);\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;AACA;EAAA;EAAA;IAAA;EAAA;EAAA;AAAA;AAGe,MAAMA,aAAa,CAAoB;EAUpDC,WAAW,CAASC,UAA0B,EAAUC,UAAkB,EAAE;IAAA,KAAxDD,UAA0B,GAA1BA,UAA0B;IAAA,KAAUC,UAAkB,GAAlBA,UAAkB;IAAA,8CATnE,aAAa;IAAA,qDACN,iDAAiD;IAAA,+CACvD,SAAS;IAAA;IAAA,+CAET,IAAI;IAAA,iDACF,CAAC,CAAC,GAAG,EAAE,sBAAsB,EAAE,wCAAwC,CAAC,CAAC;IAAA,gDAC1E,KAAK;IAAA,uDACE,IAAI;IAGlB,IAAI,CAACC,mBAAmB,GAAI;AAChC;AACA;AACA;AACA,UAAUD,UAAW,2BAA0B;EAC7C;EAEA,MAAME,MAAM,CAACC,GAAG,EAAE;IAAEC;EAA4B,CAAC,EAAmB;IAClE,IAAIA,MAAM,EAAE;MACV,MAAMC,OAAO,GAAG,MAAM,IAAI,CAACN,UAAU,CAACO,gBAAgB,CAACF,MAAM,CAAC;MAC9D,IAAIC,OAAO,EAAE;QACX,OAAOE,gBAAK,CAACC,KAAK,CAAE,sCAAqCJ,MAAO,GAAE,CAAC;MACrE;MACA,OAAOG,gBAAK,CAACE,GAAG,CAAE,iCAAgCL,MAAO,GAAE,CAAC;IAC9D;IACA,MAAMM,YAAY,GAAG,MAAM,IAAI,CAACX,UAAU,CAACA,UAAU,EAAE;IACvD,MAAMY,KAAK,GAAG,2CAA2C;IACzD,MAAMC,MAAM,GAAGF,YAAY,CAACG,GAAG,CAAEC,GAAG,IAAM,OAAMA,GAAI,EAAC,CAAC,CAACC,IAAI,CAAC,IAAI,CAAC;IACjE,OAAOR,gBAAK,CAACC,KAAK,CAAE,GAAED,gBAAK,CAACS,IAAI,CAACL,KAAK,CAAE,KAAIC,MAAO,EAAC,CAAC;EACvD;AACF;AAAC"}
|
|
@@ -4,21 +4,16 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.ClearCacheAspect = void 0;
|
|
7
|
-
|
|
8
7
|
function _harmony() {
|
|
9
8
|
const data = require("@teambit/harmony");
|
|
10
|
-
|
|
11
9
|
_harmony = function () {
|
|
12
10
|
return data;
|
|
13
11
|
};
|
|
14
|
-
|
|
15
12
|
return data;
|
|
16
13
|
}
|
|
17
|
-
|
|
18
14
|
const ClearCacheAspect = _harmony().Aspect.create({
|
|
19
15
|
id: 'teambit.bit/clear-cache'
|
|
20
16
|
});
|
|
21
|
-
|
|
22
17
|
exports.ClearCacheAspect = ClearCacheAspect;
|
|
23
18
|
|
|
24
19
|
//# sourceMappingURL=clear-cache.aspect.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["ClearCacheAspect","Aspect","create","id"],"sources":["clear-cache.aspect.ts"],"sourcesContent":["import { Aspect } from '@teambit/harmony';\n\nexport const ClearCacheAspect = Aspect.create({\n id: 'teambit.bit/clear-cache',\n});\n"],"mappings":"
|
|
1
|
+
{"version":3,"names":["ClearCacheAspect","Aspect","create","id"],"sources":["clear-cache.aspect.ts"],"sourcesContent":["import { Aspect } from '@teambit/harmony';\n\nexport const ClearCacheAspect = Aspect.create({\n id: 'teambit.bit/clear-cache',\n});\n"],"mappings":";;;;;;AAAA;EAAA;EAAA;IAAA;EAAA;EAAA;AAAA;AAEO,MAAMA,gBAAgB,GAAGC,iBAAM,CAACC,MAAM,CAAC;EAC5CC,EAAE,EAAE;AACN,CAAC,CAAC;AAAC"}
|
|
@@ -1,22 +1,17 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
-
|
|
5
4
|
Object.defineProperty(exports, "__esModule", {
|
|
6
5
|
value: true
|
|
7
6
|
});
|
|
8
7
|
exports.Logo = void 0;
|
|
9
|
-
|
|
10
8
|
function _react() {
|
|
11
9
|
const data = _interopRequireDefault(require("react"));
|
|
12
|
-
|
|
13
10
|
_react = function () {
|
|
14
11
|
return data;
|
|
15
12
|
};
|
|
16
|
-
|
|
17
13
|
return data;
|
|
18
14
|
}
|
|
19
|
-
|
|
20
15
|
const Logo = () => /*#__PURE__*/_react().default.createElement("div", {
|
|
21
16
|
style: {
|
|
22
17
|
height: '100%',
|
|
@@ -29,7 +24,6 @@ const Logo = () => /*#__PURE__*/_react().default.createElement("div", {
|
|
|
29
24
|
},
|
|
30
25
|
src: "https://static.bit.dev/extensions-icons/clean-cache.svg"
|
|
31
26
|
}));
|
|
32
|
-
|
|
33
27
|
exports.Logo = Logo;
|
|
34
28
|
|
|
35
29
|
//# sourceMappingURL=clear-cache.composition.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["Logo","height","display","justifyContent","width"],"sources":["clear-cache.composition.tsx"],"sourcesContent":["import React from 'react';\n\nexport const Logo = () => (\n <div style={{ height: '100%', display: 'flex', justifyContent: 'center' }}>\n <img style={{ width: 70 }} src=\"https://static.bit.dev/extensions-icons/clean-cache.svg\" />\n </div>\n);\n"],"mappings":"
|
|
1
|
+
{"version":3,"names":["Logo","height","display","justifyContent","width"],"sources":["clear-cache.composition.tsx"],"sourcesContent":["import React from 'react';\n\nexport const Logo = () => (\n <div style={{ height: '100%', display: 'flex', justifyContent: 'center' }}>\n <img style={{ width: 70 }} src=\"https://static.bit.dev/extensions-icons/clean-cache.svg\" />\n </div>\n);\n"],"mappings":";;;;;;;AAAA;EAAA;EAAA;IAAA;EAAA;EAAA;AAAA;AAEO,MAAMA,IAAI,GAAG,mBAClB;EAAK,KAAK,EAAE;IAAEC,MAAM,EAAE,MAAM;IAAEC,OAAO,EAAE,MAAM;IAAEC,cAAc,EAAE;EAAS;AAAE,gBACxE;EAAK,KAAK,EAAE;IAAEC,KAAK,EAAE;EAAG,CAAE;EAAC,GAAG,EAAC;AAAyD,EAAG,CAE9F;AAAC"}
|
|
@@ -1,159 +1,113 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
-
|
|
5
4
|
require("core-js/modules/es.array.iterator.js");
|
|
6
|
-
|
|
7
5
|
require("core-js/modules/es.promise.js");
|
|
8
|
-
|
|
9
6
|
Object.defineProperty(exports, "__esModule", {
|
|
10
7
|
value: true
|
|
11
8
|
});
|
|
12
9
|
exports.ClearCacheMain = void 0;
|
|
13
|
-
|
|
14
10
|
function _defineProperty2() {
|
|
15
11
|
const data = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
16
|
-
|
|
17
12
|
_defineProperty2 = function () {
|
|
18
13
|
return data;
|
|
19
14
|
};
|
|
20
|
-
|
|
21
15
|
return data;
|
|
22
16
|
}
|
|
23
|
-
|
|
24
17
|
function _cli() {
|
|
25
18
|
const data = require("@teambit/cli");
|
|
26
|
-
|
|
27
19
|
_cli = function () {
|
|
28
20
|
return data;
|
|
29
21
|
};
|
|
30
|
-
|
|
31
22
|
return data;
|
|
32
23
|
}
|
|
33
|
-
|
|
34
24
|
function _workspace() {
|
|
35
25
|
const data = _interopRequireDefault(require("@teambit/workspace"));
|
|
36
|
-
|
|
37
26
|
_workspace = function () {
|
|
38
27
|
return data;
|
|
39
28
|
};
|
|
40
|
-
|
|
41
29
|
return data;
|
|
42
30
|
}
|
|
43
|
-
|
|
44
31
|
function _scope() {
|
|
45
32
|
const data = _interopRequireDefault(require("@teambit/scope"));
|
|
46
|
-
|
|
47
33
|
_scope = function () {
|
|
48
34
|
return data;
|
|
49
35
|
};
|
|
50
|
-
|
|
51
36
|
return data;
|
|
52
37
|
}
|
|
53
|
-
|
|
54
38
|
function _consumer() {
|
|
55
39
|
const data = require("@teambit/legacy/dist/api/consumer");
|
|
56
|
-
|
|
57
40
|
_consumer = function () {
|
|
58
41
|
return data;
|
|
59
42
|
};
|
|
60
|
-
|
|
61
43
|
return data;
|
|
62
44
|
}
|
|
63
|
-
|
|
64
45
|
function _action() {
|
|
65
46
|
const data = require("@teambit/legacy/dist/api/scope/lib/action");
|
|
66
|
-
|
|
67
47
|
_action = function () {
|
|
68
48
|
return data;
|
|
69
49
|
};
|
|
70
|
-
|
|
71
50
|
return data;
|
|
72
51
|
}
|
|
73
|
-
|
|
74
52
|
function _community() {
|
|
75
53
|
const data = require("@teambit/community");
|
|
76
|
-
|
|
77
54
|
_community = function () {
|
|
78
55
|
return data;
|
|
79
56
|
};
|
|
80
|
-
|
|
81
57
|
return data;
|
|
82
58
|
}
|
|
83
|
-
|
|
84
59
|
function _getRemoteByName() {
|
|
85
60
|
const data = _interopRequireDefault(require("@teambit/legacy/dist/remotes/get-remote-by-name"));
|
|
86
|
-
|
|
87
61
|
_getRemoteByName = function () {
|
|
88
62
|
return data;
|
|
89
63
|
};
|
|
90
|
-
|
|
91
64
|
return data;
|
|
92
65
|
}
|
|
93
|
-
|
|
94
66
|
function _clearCacheCmd() {
|
|
95
67
|
const data = _interopRequireDefault(require("./clear-cache-cmd"));
|
|
96
|
-
|
|
97
68
|
_clearCacheCmd = function () {
|
|
98
69
|
return data;
|
|
99
70
|
};
|
|
100
|
-
|
|
101
71
|
return data;
|
|
102
72
|
}
|
|
103
|
-
|
|
104
73
|
function _clearCache() {
|
|
105
74
|
const data = require("./clear-cache.aspect");
|
|
106
|
-
|
|
107
75
|
_clearCache = function () {
|
|
108
76
|
return data;
|
|
109
77
|
};
|
|
110
|
-
|
|
111
78
|
return data;
|
|
112
79
|
}
|
|
113
|
-
|
|
114
80
|
function _clearCacheAction() {
|
|
115
81
|
const data = require("./clear-cache-action");
|
|
116
|
-
|
|
117
82
|
_clearCacheAction = function () {
|
|
118
83
|
return data;
|
|
119
84
|
};
|
|
120
|
-
|
|
121
85
|
return data;
|
|
122
86
|
}
|
|
123
|
-
|
|
124
87
|
class ClearCacheMain {
|
|
125
88
|
constructor(workspace) {
|
|
126
89
|
this.workspace = workspace;
|
|
127
90
|
}
|
|
128
|
-
|
|
129
91
|
async clearCache() {
|
|
130
92
|
return (0, _consumer().clearCache)();
|
|
131
93
|
}
|
|
132
|
-
|
|
133
94
|
async clearRemoteCache(remote) {
|
|
134
95
|
var _this$workspace;
|
|
135
|
-
|
|
136
96
|
const remoteObj = await (0, _getRemoteByName().default)(remote, (_this$workspace = this.workspace) === null || _this$workspace === void 0 ? void 0 : _this$workspace.consumer);
|
|
137
97
|
const result = await remoteObj.action(_clearCacheAction().ClearCacheAction.name, {});
|
|
138
98
|
return result;
|
|
139
99
|
}
|
|
140
|
-
|
|
141
100
|
static async provider([workspace, cli, scope, community]) {
|
|
142
101
|
const clearCacheMain = new ClearCacheMain(workspace);
|
|
143
102
|
cli.register(new (_clearCacheCmd().default)(clearCacheMain, community.getDocsDomain()));
|
|
144
|
-
|
|
145
103
|
_action().ExternalActions.externalActions.push(new (_clearCacheAction().ClearCacheAction)(scope));
|
|
146
|
-
|
|
147
104
|
return clearCacheMain;
|
|
148
105
|
}
|
|
149
|
-
|
|
150
106
|
}
|
|
151
|
-
|
|
152
107
|
exports.ClearCacheMain = ClearCacheMain;
|
|
153
108
|
(0, _defineProperty2().default)(ClearCacheMain, "slots", []);
|
|
154
109
|
(0, _defineProperty2().default)(ClearCacheMain, "dependencies", [_workspace().default, _cli().CLIAspect, _scope().default, _community().CommunityAspect]);
|
|
155
110
|
(0, _defineProperty2().default)(ClearCacheMain, "runtime", _cli().MainRuntime);
|
|
156
|
-
|
|
157
111
|
_clearCache().ClearCacheAspect.addRuntime(ClearCacheMain);
|
|
158
112
|
|
|
159
113
|
//# sourceMappingURL=clear-cache.main.runtime.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["ClearCacheMain","constructor","workspace","clearCache","clearRemoteCache","remote","remoteObj","getRemoteByName","consumer","result","action","ClearCacheAction","name","provider","cli","scope","community","clearCacheMain","register","ClearCacheCmd","getDocsDomain","ExternalActions","externalActions","push","WorkspaceAspect","CLIAspect","ScopeAspect","CommunityAspect","MainRuntime","ClearCacheAspect","addRuntime"],"sources":["clear-cache.main.runtime.ts"],"sourcesContent":["import { CLIAspect, CLIMain, MainRuntime } from '@teambit/cli';\nimport WorkspaceAspect, { Workspace } from '@teambit/workspace';\nimport ScopeAspect, { ScopeMain } from '@teambit/scope';\nimport { clearCache } from '@teambit/legacy/dist/api/consumer';\nimport { ExternalActions } from '@teambit/legacy/dist/api/scope/lib/action';\nimport { CommunityAspect } from '@teambit/community';\nimport type { CommunityMain } from '@teambit/community';\n\nimport getRemoteByName from '@teambit/legacy/dist/remotes/get-remote-by-name';\nimport ClearCacheCmd from './clear-cache-cmd';\nimport { ClearCacheAspect } from './clear-cache.aspect';\nimport { ClearCacheAction } from './clear-cache-action';\n\nexport class ClearCacheMain {\n constructor(private workspace?: Workspace) {}\n\n async clearCache(): Promise<string[]> {\n return clearCache();\n }\n\n async clearRemoteCache(remote: string) {\n const remoteObj = await getRemoteByName(remote, this.workspace?.consumer);\n const result = await remoteObj.action(ClearCacheAction.name, {});\n return result;\n }\n\n static slots = [];\n static dependencies = [WorkspaceAspect, CLIAspect, ScopeAspect, CommunityAspect];\n static runtime = MainRuntime;\n static async provider([workspace, cli, scope, community]: [Workspace, CLIMain, ScopeMain, CommunityMain]) {\n const clearCacheMain = new ClearCacheMain(workspace);\n cli.register(new ClearCacheCmd(clearCacheMain, community.getDocsDomain()));\n ExternalActions.externalActions.push(new ClearCacheAction(scope));\n\n return clearCacheMain;\n }\n}\n\nClearCacheAspect.addRuntime(ClearCacheMain);\n"],"mappings":"
|
|
1
|
+
{"version":3,"names":["ClearCacheMain","constructor","workspace","clearCache","clearRemoteCache","remote","remoteObj","getRemoteByName","consumer","result","action","ClearCacheAction","name","provider","cli","scope","community","clearCacheMain","register","ClearCacheCmd","getDocsDomain","ExternalActions","externalActions","push","WorkspaceAspect","CLIAspect","ScopeAspect","CommunityAspect","MainRuntime","ClearCacheAspect","addRuntime"],"sources":["clear-cache.main.runtime.ts"],"sourcesContent":["import { CLIAspect, CLIMain, MainRuntime } from '@teambit/cli';\nimport WorkspaceAspect, { Workspace } from '@teambit/workspace';\nimport ScopeAspect, { ScopeMain } from '@teambit/scope';\nimport { clearCache } from '@teambit/legacy/dist/api/consumer';\nimport { ExternalActions } from '@teambit/legacy/dist/api/scope/lib/action';\nimport { CommunityAspect } from '@teambit/community';\nimport type { CommunityMain } from '@teambit/community';\n\nimport getRemoteByName from '@teambit/legacy/dist/remotes/get-remote-by-name';\nimport ClearCacheCmd from './clear-cache-cmd';\nimport { ClearCacheAspect } from './clear-cache.aspect';\nimport { ClearCacheAction } from './clear-cache-action';\n\nexport class ClearCacheMain {\n constructor(private workspace?: Workspace) {}\n\n async clearCache(): Promise<string[]> {\n return clearCache();\n }\n\n async clearRemoteCache(remote: string) {\n const remoteObj = await getRemoteByName(remote, this.workspace?.consumer);\n const result = await remoteObj.action(ClearCacheAction.name, {});\n return result;\n }\n\n static slots = [];\n static dependencies = [WorkspaceAspect, CLIAspect, ScopeAspect, CommunityAspect];\n static runtime = MainRuntime;\n static async provider([workspace, cli, scope, community]: [Workspace, CLIMain, ScopeMain, CommunityMain]) {\n const clearCacheMain = new ClearCacheMain(workspace);\n cli.register(new ClearCacheCmd(clearCacheMain, community.getDocsDomain()));\n ExternalActions.externalActions.push(new ClearCacheAction(scope));\n\n return clearCacheMain;\n }\n}\n\nClearCacheAspect.addRuntime(ClearCacheMain);\n"],"mappings":";;;;;;;;;;;;;;;;AAAA;EAAA;EAAA;IAAA;EAAA;EAAA;AAAA;AACA;EAAA;EAAA;IAAA;EAAA;EAAA;AAAA;AACA;EAAA;EAAA;IAAA;EAAA;EAAA;AAAA;AACA;EAAA;EAAA;IAAA;EAAA;EAAA;AAAA;AACA;EAAA;EAAA;IAAA;EAAA;EAAA;AAAA;AACA;EAAA;EAAA;IAAA;EAAA;EAAA;AAAA;AAGA;EAAA;EAAA;IAAA;EAAA;EAAA;AAAA;AACA;EAAA;EAAA;IAAA;EAAA;EAAA;AAAA;AACA;EAAA;EAAA;IAAA;EAAA;EAAA;AAAA;AACA;EAAA;EAAA;IAAA;EAAA;EAAA;AAAA;AAEO,MAAMA,cAAc,CAAC;EAC1BC,WAAW,CAASC,SAAqB,EAAE;IAAA,KAAvBA,SAAqB,GAArBA,SAAqB;EAAG;EAE5C,MAAMC,UAAU,GAAsB;IACpC,OAAO,IAAAA,sBAAU,GAAE;EACrB;EAEA,MAAMC,gBAAgB,CAACC,MAAc,EAAE;IAAA;IACrC,MAAMC,SAAS,GAAG,MAAM,IAAAC,0BAAe,EAACF,MAAM,qBAAE,IAAI,CAACH,SAAS,oDAAd,gBAAgBM,QAAQ,CAAC;IACzE,MAAMC,MAAM,GAAG,MAAMH,SAAS,CAACI,MAAM,CAACC,oCAAgB,CAACC,IAAI,EAAE,CAAC,CAAC,CAAC;IAChE,OAAOH,MAAM;EACf;EAKA,aAAaI,QAAQ,CAAC,CAACX,SAAS,EAAEY,GAAG,EAAEC,KAAK,EAAEC,SAAS,CAAiD,EAAE;IACxG,MAAMC,cAAc,GAAG,IAAIjB,cAAc,CAACE,SAAS,CAAC;IACpDY,GAAG,CAACI,QAAQ,CAAC,KAAIC,wBAAa,EAACF,cAAc,EAAED,SAAS,CAACI,aAAa,EAAE,CAAC,CAAC;IAC1EC,yBAAe,CAACC,eAAe,CAACC,IAAI,CAAC,KAAIZ,oCAAgB,EAACI,KAAK,CAAC,CAAC;IAEjE,OAAOE,cAAc;EACvB;AACF;AAAC;AAAA,gCAvBYjB,cAAc,WAaV,EAAE;AAAA,gCAbNA,cAAc,kBAcH,CAACwB,oBAAe,EAAEC,gBAAS,EAAEC,gBAAW,EAAEC,4BAAe,CAAC;AAAA,gCAdrE3B,cAAc,aAeR4B,kBAAW;AAU9BC,8BAAgB,CAACC,UAAU,CAAC9B,cAAc,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -10,19 +10,14 @@ Object.defineProperty(exports, "ClearCacheAspect", {
|
|
|
10
10
|
}
|
|
11
11
|
});
|
|
12
12
|
exports.default = void 0;
|
|
13
|
-
|
|
14
13
|
function _clearCache() {
|
|
15
14
|
const data = require("./clear-cache.aspect");
|
|
16
|
-
|
|
17
15
|
_clearCache = function () {
|
|
18
16
|
return data;
|
|
19
17
|
};
|
|
20
|
-
|
|
21
18
|
return data;
|
|
22
19
|
}
|
|
23
|
-
|
|
24
20
|
var _default = _clearCache().ClearCacheAspect;
|
|
25
|
-
|
|
26
21
|
exports.default = _default;
|
|
27
22
|
|
|
28
23
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["ClearCacheAspect"],"sources":["index.ts"],"sourcesContent":["import { ClearCacheAspect } from './clear-cache.aspect';\n\nexport type { ClearCacheMain } from './clear-cache.main.runtime';\nexport default ClearCacheAspect;\nexport { ClearCacheAspect };\n"],"mappings":"
|
|
1
|
+
{"version":3,"names":["ClearCacheAspect"],"sources":["index.ts"],"sourcesContent":["import { ClearCacheAspect } from './clear-cache.aspect';\n\nexport type { ClearCacheMain } from './clear-cache.main.runtime';\nexport default ClearCacheAspect;\nexport { ClearCacheAspect };\n"],"mappings":";;;;;;;;;;;;AAAA;EAAA;EAAA;IAAA;EAAA;EAAA;AAAA;AAAwD,eAGzCA,8BAAgB;AAAA"}
|
|
Binary file
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@teambit/clear-cache",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.153",
|
|
4
4
|
"homepage": "https://bit.dev/teambit/workspace/clear-cache",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"componentId": {
|
|
7
7
|
"scope": "teambit.workspace",
|
|
8
8
|
"name": "clear-cache",
|
|
9
|
-
"version": "0.0.
|
|
9
|
+
"version": "0.0.153"
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"chalk": "2.4.2",
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
"@types/node": "12.20.4"
|
|
24
24
|
},
|
|
25
25
|
"peerDependencies": {
|
|
26
|
-
"@teambit/legacy": "1.0.
|
|
26
|
+
"@teambit/legacy": "1.0.375",
|
|
27
27
|
"react-dom": "^16.8.0 || ^17.0.0",
|
|
28
28
|
"react": "^16.8.0 || ^17.0.0"
|
|
29
29
|
},
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import * as compositions_0 from '/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.workspace_clear-cache@0.0.
|
|
2
|
-
import * as overview_0 from '/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.workspace_clear-cache@0.0.
|
|
1
|
+
import * as compositions_0 from '/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.workspace_clear-cache@0.0.153/dist/clear-cache.composition.js';
|
|
2
|
+
import * as overview_0 from '/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.workspace_clear-cache@0.0.153/dist/clear-cache.docs.mdx';
|
|
3
3
|
|
|
4
4
|
export const compositions = [compositions_0];
|
|
5
5
|
export const overview = [overview_0];
|
|
Binary file
|