@aws-sdk/find-v2 0.0.2 → 0.1.0
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/README.md +1 -1
- package/dist/scanLambdaFunctions.js +3 -2
- package/package.json +3 -1
package/README.md
CHANGED
|
@@ -39,7 +39,7 @@ Note about output:
|
|
|
39
39
|
- [N] means "aws-sdk" is not found in Lambda function.
|
|
40
40
|
- [?] means script was not able to proceed, and it emits reason.
|
|
41
41
|
|
|
42
|
-
Reading 4 functions.
|
|
42
|
+
Reading 4 functions from "us-east-2" region.
|
|
43
43
|
[N] fn-without-aws-sdk-in-bundle
|
|
44
44
|
[Y] fn-with-aws-sdk-in-bundle
|
|
45
45
|
[Y] fn-with-aws-sdk-in-package-json-deps
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Lambda, paginateListFunctions
|
|
1
|
+
import { Lambda, paginateListFunctions } from "@aws-sdk/client-lambda";
|
|
2
2
|
import { JS_SDK_V2_MARKER } from "./constants.js";
|
|
3
3
|
import { scanLambdaFunction } from "./scanLambdaFunction.js";
|
|
4
4
|
const client = new Lambda();
|
|
@@ -21,7 +21,8 @@ export const scanLambdaFunctions = async () => {
|
|
|
21
21
|
console.log(`- ${JS_SDK_V2_MARKER.Y} means "aws-sdk" is found in Lambda function, and migration is recommended.`);
|
|
22
22
|
console.log(`- ${JS_SDK_V2_MARKER.N} means "aws-sdk" is not found in Lambda function.`);
|
|
23
23
|
console.log(`- ${JS_SDK_V2_MARKER.UNKNOWN} means script was not able to proceed, and it emits reason.\n`);
|
|
24
|
-
|
|
24
|
+
const region = await client.config.region();
|
|
25
|
+
console.log(`Reading ${functionsLength} function${functionsLength > 1 ? "s" : ""} from "${region}" region.`);
|
|
25
26
|
for (const functionName of functions) {
|
|
26
27
|
await scanLambdaFunction(client, functionName);
|
|
27
28
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aws-sdk/find-v2",
|
|
3
|
-
"version": "0.0
|
|
3
|
+
"version": "0.1.0",
|
|
4
4
|
"description": "CLI to find resources which call AWS using JavaScript SDK v2",
|
|
5
5
|
"main": "dist/cli.js",
|
|
6
6
|
"types": "dist/cli.d.ts",
|
|
@@ -23,6 +23,7 @@
|
|
|
23
23
|
"@types/unzipper": "^0.10.11",
|
|
24
24
|
"aws-sdk": "^2.1692.0",
|
|
25
25
|
"esbuild": "~0.27.1",
|
|
26
|
+
"oxfmt": "^0.18.0",
|
|
26
27
|
"rolldown": "1.0.0-beta.54",
|
|
27
28
|
"rollup": "^4.53.3",
|
|
28
29
|
"typescript": "^5.9.3",
|
|
@@ -32,6 +33,7 @@
|
|
|
32
33
|
},
|
|
33
34
|
"scripts": {
|
|
34
35
|
"build": "tsc",
|
|
36
|
+
"format": "oxfmt",
|
|
35
37
|
"test": "vitest",
|
|
36
38
|
"test:generate:bundles": "node scripts/generateBundles.ts",
|
|
37
39
|
"release": "yarn build && changeset publish"
|