@znemz/cft-utils 0.1.14 → 0.1.16
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@znemz/cft-utils",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.16",
|
|
4
4
|
"description": "AWS CFT Utilities to fill the gaps for Cloud Formation",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"cft",
|
|
@@ -37,23 +37,22 @@
|
|
|
37
37
|
"unused:dependencies": "depcheck --ignore-bin-package --ignores @znemz/skip-npm-task,sort-package-json"
|
|
38
38
|
},
|
|
39
39
|
"dependencies": {
|
|
40
|
-
"debug-fabulous": "2.0.
|
|
41
|
-
"glob": "11.0.
|
|
40
|
+
"debug-fabulous": "2.0.11",
|
|
41
|
+
"glob": "11.0.3"
|
|
42
42
|
},
|
|
43
43
|
"devDependencies": {
|
|
44
44
|
"@commitlint/cli": "^19",
|
|
45
45
|
"@commitlint/config-conventional": "^19",
|
|
46
46
|
"@znemz/skip-npm-task": "0.1.0",
|
|
47
|
-
"aws-cdk-lib": "2.
|
|
47
|
+
"aws-cdk-lib": "2.202.0",
|
|
48
48
|
"commit-and-tag-version": "12",
|
|
49
49
|
"commitlint": "19",
|
|
50
50
|
"depcheck": "1.4.7",
|
|
51
|
-
"eslint": "
|
|
51
|
+
"eslint": "9",
|
|
52
52
|
"eslint-config-prettier": "10",
|
|
53
|
-
"eslint-
|
|
54
|
-
"eslint-plugin-mocha": "10",
|
|
53
|
+
"eslint-plugin-mocha": "11",
|
|
55
54
|
"eslint-plugin-prettier": "5",
|
|
56
55
|
"mocha": "11",
|
|
57
|
-
"sort-package-json": "3.
|
|
56
|
+
"sort-package-json": "3.3"
|
|
58
57
|
}
|
|
59
58
|
}
|
|
@@ -43,7 +43,7 @@ const getResourcesFromAwsCdk = async () => {
|
|
|
43
43
|
];
|
|
44
44
|
const paths = await glob(globPaths);
|
|
45
45
|
const nestedResourceNames = await Promise.all(
|
|
46
|
-
paths.map((file) => fileToTaggableResourceNames(file))
|
|
46
|
+
paths.map((file) => fileToTaggableResourceNames(file)),
|
|
47
47
|
);
|
|
48
48
|
return nestedResourceNames.flat();
|
|
49
49
|
};
|
|
@@ -109,7 +109,7 @@ async function getCachedFile(cacheFile) {
|
|
|
109
109
|
if (cached && cached.length > 0) {
|
|
110
110
|
return cached;
|
|
111
111
|
}
|
|
112
|
-
} catch
|
|
112
|
+
} catch {
|
|
113
113
|
// do nothing
|
|
114
114
|
}
|
|
115
115
|
}
|
|
@@ -117,10 +117,10 @@ async function getCachedFile(cacheFile) {
|
|
|
117
117
|
async function mkCacheDir() {
|
|
118
118
|
try {
|
|
119
119
|
await fs.access(cachePath);
|
|
120
|
-
} catch
|
|
120
|
+
} catch {
|
|
121
121
|
try {
|
|
122
122
|
await fs.mkdir(cachePath, { recursive: true });
|
|
123
|
-
} catch
|
|
123
|
+
} catch {
|
|
124
124
|
// --force
|
|
125
125
|
}
|
|
126
126
|
}
|
|
@@ -1,16 +1,17 @@
|
|
|
1
1
|
const taggable = require('./taggable');
|
|
2
2
|
const assert = require('assert');
|
|
3
3
|
|
|
4
|
-
describe(taggable.isTaggableResource.name, ()
|
|
5
|
-
['AWS::IAM::Role'].forEach((resourceName)
|
|
6
|
-
it(`${resourceName} is taggable`, async ()
|
|
4
|
+
describe(taggable.isTaggableResource.name, function () {
|
|
5
|
+
['AWS::IAM::Role'].forEach(function (resourceName) {
|
|
6
|
+
it(`${resourceName} is taggable`, async function () {
|
|
7
7
|
const isTag = await taggable.isTaggableResource(resourceName);
|
|
8
8
|
assert.ok(isTag);
|
|
9
9
|
});
|
|
10
10
|
});
|
|
11
11
|
|
|
12
|
-
['AWS::IAM::Policy', 'AWS::IAM::ManagedPolicy'].forEach((resourceName)
|
|
13
|
-
|
|
12
|
+
['AWS::IAM::Policy', 'AWS::IAM::ManagedPolicy'].forEach(function (resourceName) {
|
|
13
|
+
|
|
14
|
+
it(`${resourceName} is NOT taggable`, async function () {
|
|
14
15
|
const isTag = await taggable.isTaggableResource(resourceName);
|
|
15
16
|
assert.ok(!isTag);
|
|
16
17
|
});
|