@cumulusds/aws-apig-bypass 0.2.4-reusableworkflow.16.gbe881dc → 0.2.4

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.
@@ -0,0 +1,15 @@
1
+ version: 2
2
+
3
+ updates:
4
+ - package-ecosystem: "github-actions"
5
+ directory: "/"
6
+ schedule:
7
+ interval: "daily"
8
+ time: "07:00"
9
+ timezone: "America/New_York"
10
+ labels:
11
+ - "actions"
12
+ assignees:
13
+ - "jeffsays"
14
+ reviewers:
15
+ - "jeffsays"
@@ -0,0 +1,18 @@
1
+ ## Summary
2
+ What does this PR do?
3
+
4
+ ## Dependencies
5
+ - [Name of the change](https://link-to-PR-or-commit)
6
+
7
+ ## Changes
8
+ ### Interface
9
+ - Is there a change to the package's interface?
10
+
11
+ ### Developer
12
+ - What are the other changes that are not directly visible to the user ?
13
+
14
+ ## Details
15
+ Why did you make this change? What does it affect?
16
+
17
+ ## Testing
18
+ How can the other reviewers check that your change works?
@@ -0,0 +1,88 @@
1
+ name: ci-cd
2
+
3
+ on:
4
+ push:
5
+ branches:
6
+ - '**/*'
7
+ pull_request:
8
+ release:
9
+ types: [released]
10
+
11
+ jobs:
12
+ unit:
13
+ runs-on: ubuntu-18.04
14
+ strategy:
15
+ matrix:
16
+ node: [10, 12, 13, 14, 15]
17
+ steps:
18
+ - name: Checkout
19
+ uses: actions/checkout@v2
20
+ - name: Install Node ${{ matrix.node }}
21
+ uses: actions/setup-node@v2
22
+ with:
23
+ node-version: ${{ matrix.node }}
24
+ - name: Install NPM credentials
25
+ run: echo "//registry.npmjs.org/:_authToken=$NPM_TOKEN" >> ~/.npmrc
26
+ env:
27
+ NPM_TOKEN: ${{ secrets.NODE_AUTH_TOKEN }}
28
+ - name: Get yarn cache
29
+ id: yarn-cache
30
+ run: echo "::set-output name=dir::$(yarn cache dir)"
31
+ - name: Restore yarn cache
32
+ uses: actions/cache@v2
33
+ with:
34
+ path: ${{ steps.yarn-cache.outputs.dir }}
35
+ key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
36
+ restore-keys: |
37
+ ${{ runner.os }}-yarn-
38
+ - name: Install NPM Packages
39
+ run: yarn install --frozen-lockfile
40
+ - name: Check licenses
41
+ run: yarn build:license-checker
42
+ - name: Test
43
+ run: yarn test
44
+ - uses: 8398a7/action-slack@v2
45
+ with:
46
+ status: ${{ job.status }}
47
+ author_name: ${{ github.repository }} ${{ github.workflow }}
48
+ env:
49
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
50
+ SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK }}
51
+ if: always()
52
+ - name: Upload artifacts
53
+ uses: actions/upload-artifact@v2
54
+ with:
55
+ name: var
56
+ path: var
57
+ if: always()
58
+ publish:
59
+ runs-on: ubuntu-18.04
60
+ needs: unit
61
+ if: github.event_name == 'release'
62
+ steps:
63
+ - name: Checkout
64
+ uses: actions/checkout@v2
65
+ - name: Install Node 14
66
+ uses: actions/setup-node@v2
67
+ with:
68
+ node-version: 14
69
+ - name: Install NPM credentials
70
+ run: echo "//registry.npmjs.org/:_authToken=$NPM_TOKEN" >> ~/.npmrc
71
+ env:
72
+ NPM_TOKEN: ${{ secrets.NODE_AUTH_TOKEN }}
73
+ - name: Get yarn cache
74
+ id: yarn-cache
75
+ run: echo "::set-output name=dir::$(yarn cache dir)"
76
+ - name: Restore yarn cache
77
+ uses: actions/cache@v2
78
+ with:
79
+ path: ${{ steps.yarn-cache.outputs.dir }}
80
+ key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
81
+ restore-keys: |
82
+ ${{ runner.os }}-yarn-
83
+ - name: Install NPM Packages
84
+ run: yarn install --frozen-lockfile
85
+ - name: Build
86
+ run: yarn build
87
+ - name: Publish
88
+ run: npm publish
@@ -0,0 +1,59 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = createAPIGatewayEvent;
7
+ const defaultRequestContext = {
8
+ accountId: "",
9
+ apiId: "",
10
+ httpMethod: "",
11
+ identity: {
12
+ accessKey: null,
13
+ accountId: null,
14
+ apiKey: null,
15
+ caller: null,
16
+ cognitoAuthenticationProvider: null,
17
+ cognitoAuthenticationType: null,
18
+ cognitoIdentityId: null,
19
+ cognitoIdentityPoolId: null,
20
+ sourceIp: "",
21
+ user: null,
22
+ userAgent: null,
23
+ userArn: null
24
+ },
25
+ stage: "",
26
+ requestId: "",
27
+ resourceId: "",
28
+ resourcePath: ""
29
+ };
30
+
31
+ function createAPIGatewayEvent({
32
+ body = null,
33
+ headers = {},
34
+ multiValueHeaders = {},
35
+ httpMethod = "",
36
+ isBase64Encoded = false,
37
+ pathParameters = null,
38
+ path = "",
39
+ queryStringParameters = null,
40
+ multiValueQueryStringParameters = null,
41
+ stageVariables = null,
42
+ requestContext = defaultRequestContext,
43
+ resource = ""
44
+ } = {}) {
45
+ return {
46
+ body,
47
+ headers,
48
+ multiValueHeaders,
49
+ httpMethod,
50
+ isBase64Encoded,
51
+ path,
52
+ pathParameters,
53
+ queryStringParameters,
54
+ multiValueQueryStringParameters,
55
+ stageVariables,
56
+ requestContext,
57
+ resource
58
+ };
59
+ }
@@ -0,0 +1,75 @@
1
+ // @flow
2
+
3
+ import type { APIGatewayEvent } from "@cumulusds/flow-aws-lambda";
4
+
5
+ export type PathParameters = { [name: string]: string } | null;
6
+ export type QueryStringParameters = { [name: string]: string } | null;
7
+
8
+ const defaultRequestContext = {
9
+ accountId: "",
10
+ apiId: "",
11
+ httpMethod: "",
12
+ identity: {
13
+ accessKey: null,
14
+ accountId: null,
15
+ apiKey: null,
16
+ caller: null,
17
+ cognitoAuthenticationProvider: null,
18
+ cognitoAuthenticationType: null,
19
+ cognitoIdentityId: null,
20
+ cognitoIdentityPoolId: null,
21
+ sourceIp: "",
22
+ user: null,
23
+ userAgent: null,
24
+ userArn: null
25
+ },
26
+ stage: "",
27
+ requestId: "",
28
+ resourceId: "",
29
+ resourcePath: ""
30
+ };
31
+
32
+ export type CreateAPIGatewayEventOptions = {
33
+ body?: string,
34
+ headers?: { [name: string]: string },
35
+ multiValueHeaders?: { [name: string]: string[] },
36
+ httpMethod?: string,
37
+ isBase64Encoded?: boolean,
38
+ path?: string,
39
+ pathParameters?: PathParameters,
40
+ queryStringParameters?: QueryStringParameters,
41
+ multiValueQueryStringParameters?: { [name: string]: string[] },
42
+ stageVariables?: { [name: string]: string },
43
+ requestContext?: typeof defaultRequestContext,
44
+ resource?: string
45
+ };
46
+
47
+ export default function createAPIGatewayEvent({
48
+ body = null,
49
+ headers = {},
50
+ multiValueHeaders = {},
51
+ httpMethod = "",
52
+ isBase64Encoded = false,
53
+ pathParameters = null,
54
+ path = "",
55
+ queryStringParameters = null,
56
+ multiValueQueryStringParameters = null,
57
+ stageVariables = null,
58
+ requestContext = defaultRequestContext,
59
+ resource = ""
60
+ }: CreateAPIGatewayEventOptions = {}): APIGatewayEvent<string> {
61
+ return {
62
+ body,
63
+ headers,
64
+ multiValueHeaders,
65
+ httpMethod,
66
+ isBase64Encoded,
67
+ path,
68
+ pathParameters,
69
+ queryStringParameters,
70
+ multiValueQueryStringParameters,
71
+ stageVariables,
72
+ requestContext,
73
+ resource
74
+ };
75
+ }
@@ -0,0 +1,25 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = createClient;
7
+
8
+ var _createLambdaClient = _interopRequireDefault(require("./create-lambda-client"));
9
+
10
+ var _jsonStringify = _interopRequireDefault(require("./json-stringify"));
11
+
12
+ var _parsePayload = _interopRequireDefault(require("./parse-payload"));
13
+
14
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
15
+
16
+ /**
17
+ * Create an APIGatewayHandlerClient. The client invokes an API Gateway handler, bypassing the gateway. It adapts the AWS SDK by packing and unpacking messages for invoking the handler.
18
+ *
19
+ * @param options
20
+ * @returns {APIGatewayHandlerClient<T>}
21
+ */
22
+ function createClient(options) {
23
+ const client = (0, _createLambdaClient.default)(options);
24
+ return async event => (0, _parsePayload.default)((await client((0, _jsonStringify.default)(event))));
25
+ }
@@ -0,0 +1,30 @@
1
+ // @flow
2
+
3
+ import type { APIGatewayEvent } from "@cumulusds/flow-aws-lambda";
4
+ import createLambdaClient from "./create-lambda-client";
5
+ import type { Response } from "./response";
6
+ import jsonStringify from "./json-stringify";
7
+ import parsePayload from "./parse-payload";
8
+ import type { LambdaInvoke } from "./lambda-invoke";
9
+
10
+ /**
11
+ * Client that directly invokes an API Gateway handler, bypassing the gateway. The client handles packing and unpacking messages for invoking the handler.
12
+ */
13
+ export type APIGatewayHandlerClient<T> = (event: APIGatewayEvent<string>) => Promise<Response<T>>;
14
+
15
+ export type CreateClientOptions<T> = {
16
+ Lambda: LambdaInvoke,
17
+ FunctionName: string,
18
+ Validate?: T => void
19
+ };
20
+
21
+ /**
22
+ * Create an APIGatewayHandlerClient. The client invokes an API Gateway handler, bypassing the gateway. It adapts the AWS SDK by packing and unpacking messages for invoking the handler.
23
+ *
24
+ * @param options
25
+ * @returns {APIGatewayHandlerClient<T>}
26
+ */
27
+ export default function createClient<T>(options: CreateClientOptions<T>): APIGatewayHandlerClient<T> {
28
+ const client = createLambdaClient(options);
29
+ return async (event: APIGatewayEvent<string>) => parsePayload<T>(await client(jsonStringify(event)));
30
+ }
@@ -0,0 +1,45 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = createLambdaClient;
7
+ exports.LambdaInvokeError = void 0;
8
+
9
+ class LambdaInvokeError extends Error {
10
+ constructor(response) {
11
+ var _response$FunctionErr;
12
+
13
+ super(["Invocation Failed", response.ExecutedVersion, response.StatusCode, response.FunctionError, response.Payload, response.LogResult != null ? Buffer.from(response.LogResult, "base64").toString("utf-8") : null].filter(x => x != null).join(": "));
14
+ this.code = (_response$FunctionErr = response.FunctionError) !== null && _response$FunctionErr !== void 0 ? _response$FunctionErr : "";
15
+ }
16
+
17
+ }
18
+ /**
19
+ * AWS Lambda SDK adapter for createClient.
20
+ */
21
+
22
+
23
+ exports.LambdaInvokeError = LambdaInvokeError;
24
+
25
+ function createLambdaClient({
26
+ Lambda,
27
+ FunctionName
28
+ }) {
29
+ return async Payload => {
30
+ const invocationResponse = await Lambda.invoke({
31
+ FunctionName,
32
+ Payload
33
+ }).promise();
34
+
35
+ if (invocationResponse.StatusCode !== 200 || invocationResponse.FunctionError != null) {
36
+ throw new LambdaInvokeError(invocationResponse);
37
+ }
38
+
39
+ if (typeof invocationResponse.Payload !== "string") {
40
+ throw new Error(`AWS Lambda invocation API returned the wrong payload type '${typeof invocationResponse.Payload}'; expected 'string'`);
41
+ }
42
+
43
+ return invocationResponse.Payload;
44
+ };
45
+ }
@@ -0,0 +1,80 @@
1
+ // @flow
2
+
3
+ import type { LambdaInvoke } from "./lambda-invoke";
4
+
5
+ interface Blob {}
6
+ type _Blob = Buffer | Uint8Array | Blob | string;
7
+ type LambdaClientType = (event: _Blob) => Promise<string>;
8
+
9
+ export type CreateLambdaClientOptions = {
10
+ Lambda: LambdaInvoke,
11
+ FunctionName: string
12
+ };
13
+
14
+ export type Lambda$InvocationResponse = {
15
+ /**
16
+ * The HTTP status code is in the 200 range for a successful request. For the RequestResponse invocation type, this status code is 200. For the Event invocation type, this status code is 202. For the DryRun invocation type, the status code is 204.
17
+ */
18
+ StatusCode?: number,
19
+
20
+ /**
21
+ * If present, indicates that an error occurred during function execution. Details about the error are included in the response payload.
22
+ */
23
+ FunctionError?: string,
24
+
25
+ /**
26
+ * The last 4 KB of the execution log, which is base64 encoded.
27
+ */
28
+ LogResult?: string,
29
+
30
+ /**
31
+ * The response from the function, or an error object.
32
+ */
33
+ Payload?: Buffer | Uint8Array | Blob | string,
34
+
35
+ /**
36
+ * The version of the function that executed. When you invoke a function with an alias, this indicates which version the alias resolved to.
37
+ */
38
+ ExecutedVersion?: string
39
+ };
40
+
41
+ export class LambdaInvokeError extends Error {
42
+ code: string;
43
+
44
+ constructor(response: Lambda$InvocationResponse) {
45
+ super(
46
+ [
47
+ "Invocation Failed",
48
+ response.ExecutedVersion,
49
+ response.StatusCode,
50
+ response.FunctionError,
51
+ response.Payload,
52
+ response.LogResult != null ? Buffer.from(response.LogResult, "base64").toString("utf-8") : null
53
+ ]
54
+ .filter(x => x != null)
55
+ .join(": ")
56
+ );
57
+ this.code = response.FunctionError ?? "";
58
+ }
59
+ }
60
+
61
+ /**
62
+ * AWS Lambda SDK adapter for createClient.
63
+ */
64
+ export default function createLambdaClient({ Lambda, FunctionName }: CreateLambdaClientOptions): LambdaClientType {
65
+ return async (Payload: _Blob) => {
66
+ const invocationResponse = await Lambda.invoke({
67
+ FunctionName,
68
+ Payload
69
+ }).promise();
70
+ if (invocationResponse.StatusCode !== 200 || invocationResponse.FunctionError != null) {
71
+ throw new LambdaInvokeError(invocationResponse);
72
+ }
73
+ if (typeof invocationResponse.Payload !== "string") {
74
+ throw new Error(
75
+ `AWS Lambda invocation API returned the wrong payload type '${typeof invocationResponse.Payload}'; expected 'string'`
76
+ );
77
+ }
78
+ return invocationResponse.Payload;
79
+ };
80
+ }
package/lib/index.js ADDED
@@ -0,0 +1,23 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ Object.defineProperty(exports, "createClient", {
7
+ enumerable: true,
8
+ get: function () {
9
+ return _createClient.default;
10
+ }
11
+ });
12
+ Object.defineProperty(exports, "createAPIGatewayEvent", {
13
+ enumerable: true,
14
+ get: function () {
15
+ return _createApiGatewayEvent.default;
16
+ }
17
+ });
18
+
19
+ var _createClient = _interopRequireDefault(require("./create-client"));
20
+
21
+ var _createApiGatewayEvent = _interopRequireDefault(require("./create-api-gateway-event"));
22
+
23
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
@@ -0,0 +1,4 @@
1
+ // @flow
2
+
3
+ export { default as createClient } from "./create-client";
4
+ export { default as createAPIGatewayEvent } from "./create-api-gateway-event";
@@ -0,0 +1,23 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = jsonStringify;
7
+
8
+ /**
9
+ * Stringify to JSON, returning a string or else throwing an exception because of unserializable input.
10
+ *
11
+ * @param value
12
+ * @returns {string}
13
+ */
14
+ // flowlint-next-line unclear-type:off
15
+ function jsonStringify(value) {
16
+ const result = JSON.stringify(value);
17
+
18
+ if (result == null) {
19
+ throw new Error("Cannot stringify value");
20
+ }
21
+
22
+ return result;
23
+ }
@@ -0,0 +1,16 @@
1
+ // @flow
2
+
3
+ /**
4
+ * Stringify to JSON, returning a string or else throwing an exception because of unserializable input.
5
+ *
6
+ * @param value
7
+ * @returns {string}
8
+ */
9
+ // flowlint-next-line unclear-type:off
10
+ export default function jsonStringify(value: any): string {
11
+ const result = JSON.stringify(value);
12
+ if (result == null) {
13
+ throw new Error("Cannot stringify value");
14
+ }
15
+ return result;
16
+ }
@@ -0,0 +1 @@
1
+ "use strict";
@@ -0,0 +1,10 @@
1
+ // @flow
2
+
3
+ import type { Lambda } from "aws-sdk";
4
+
5
+ /**
6
+ * This library only needs the invoke method from aws-sdk Lambda client.
7
+ */
8
+ export type LambdaInvoke = {
9
+ +invoke: $PropertyType<Lambda, "invoke">
10
+ };
@@ -0,0 +1,31 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = parsePayload;
7
+
8
+ /**
9
+ * Decode the handler response
10
+ *
11
+ * @param payload
12
+ * @param validate if given, the validate function is called on the parsed response body. The function should throw an exception if the response is invalid.
13
+ * @returns {{headers: {[p: string]: boolean|number|string}, data: *, status: number}}
14
+ */
15
+ function parsePayload(payload, validate) {
16
+ var _proxyResult$headers;
17
+
18
+ const proxyResult = JSON.parse(payload);
19
+
20
+ if (proxyResult.isBase64Encoded === true) {
21
+ throw new Error("A base64 encoded response from API Gateway handler was received, but is not supported.");
22
+ }
23
+
24
+ const data = JSON.parse(proxyResult.body);
25
+ validate === null || validate === void 0 ? void 0 : validate(data);
26
+ return {
27
+ data,
28
+ status: proxyResult.statusCode,
29
+ headers: (_proxyResult$headers = proxyResult.headers) !== null && _proxyResult$headers !== void 0 ? _proxyResult$headers : {}
30
+ };
31
+ }
@@ -0,0 +1,25 @@
1
+ // @flow
2
+
3
+ import type { ProxyResult } from "@cumulusds/flow-aws-lambda";
4
+ import type { Response } from "./response";
5
+
6
+ /**
7
+ * Decode the handler response
8
+ *
9
+ * @param payload
10
+ * @param validate if given, the validate function is called on the parsed response body. The function should throw an exception if the response is invalid.
11
+ * @returns {{headers: {[p: string]: boolean|number|string}, data: *, status: number}}
12
+ */
13
+ export default function parsePayload<T>(payload: string, validate?: T => void): Response<T> {
14
+ const proxyResult: ProxyResult = JSON.parse(payload);
15
+ if (proxyResult.isBase64Encoded === true) {
16
+ throw new Error("A base64 encoded response from API Gateway handler was received, but is not supported.");
17
+ }
18
+ const data: T = JSON.parse(proxyResult.body);
19
+ validate?.(data);
20
+ return {
21
+ data,
22
+ status: proxyResult.statusCode,
23
+ headers: proxyResult.headers ?? {}
24
+ };
25
+ }
@@ -0,0 +1 @@
1
+ "use strict";
@@ -0,0 +1,15 @@
1
+ // @flow
2
+
3
+ /**
4
+ * Decoded handler response
5
+ */
6
+ export type Response<T> = {|
7
+ // the response provided by the handler
8
+ data: T,
9
+
10
+ // the HTTP status code
11
+ status: number,
12
+
13
+ // response headers
14
+ headers: { [header: string]: boolean | number | string }
15
+ |};
package/package.json CHANGED
@@ -1,12 +1,13 @@
1
1
  {
2
2
  "name": "@cumulusds/aws-apig-bypass",
3
- "version": "0.2.4-reusableworkflow.16.gbe881dc",
3
+ "version": "0.2.4",
4
4
  "description": "Client for API Gateway handlers, bypassing API Gateway by directly invoking the Lambda",
5
5
  "repository": "https://github.com/CumulusDS/aws-apig-bypass",
6
6
  "author": "Cumulus Digital Systems",
7
7
  "license": "MIT",
8
+ "private": false,
8
9
  "engines": {
9
- "node": "^14.15.0 || ^16.0.0 || ^18.0.0 || ^19.0.0"
10
+ "node": ">=10"
10
11
  },
11
12
  "main": "lib/index.js",
12
13
  "src": [
@@ -14,27 +15,17 @@
14
15
  "package.json"
15
16
  ],
16
17
  "scripts": {
17
- "build": "yarn run build:babel && yarn run build:flow-copy-source && yarn run build:license-checker",
18
+ "build": "run-p build:babel build:flow-copy-source build:license-checker",
18
19
  "build:babel": "babel src --out-dir lib --ignore test.js",
19
20
  "build:flow-copy-source": "flow-copy-source --ignore test.js src lib",
20
21
  "build:license-checker": "license-checker --csv --out var/licenses.csv",
21
22
  "clean": "shx rm -rf lib",
22
- "git:commit": "git add package.json .yarn/versions && git commit -m v${npm_package_version}",
23
- "git:commit:publish": "git add package.json .yarn/versions/* && git commit -m v${npm_package_version}",
24
- "git:commit:version": "git add .yarn/versions/* && git commit -m 'Deferred version bump'",
25
23
  "git:push": "git push --follow-tags",
26
- "git:tag": "git tag -a v${npm_package_version} -m v${npm_package_version}",
27
- "npm:tag:remove": "yarn npm tag remove ${npm_package_name} $0",
28
- "prerelease": "yarn version apply && yarn run version:feature $0",
29
- "publish:patch": "yarn version patch && yarn publish:sync",
30
- "publish:minor": "yarn version minor && yarn publish:sync",
31
- "publish:major": "yarn version major && yarn publish:sync",
32
- "publish:prepatch": "yarn run version:prepatch && yarn run git:push",
33
- "publish:prerelease": "yarn npm publish",
34
- "publish:sync": "yarn run git:commit && yarn run git:tag && yarn git:push",
24
+ "publish:patch": "run-s version:patch git:push",
25
+ "publish:minor": "run-s version:minor git:push",
26
+ "publish:major": "run-s version:major git:push",
35
27
  "sites": "node bin/sites.js",
36
- "test": "yarn run test:flow && yarn run test:jest && yarn run test:lint && yarn run test:prettier",
37
- "test:flow": "yarn run test:flow:coverage-report && yarn run test:flow:status",
28
+ "test": "run-p --aggregate-output test:**",
38
29
  "test:flow:coverage-report": "flow-coverage-report -i '{src,test}/**/*.js' -t html -t text --threshold 99 --output-dir var/coverage/flow",
39
30
  "test:flow:status": "flow status",
40
31
  "test:jest": "jest --color",
@@ -42,10 +33,7 @@
42
33
  "test:prettier": "prettier --list-different \"{src,test}/**/*.{js,jsx,yml}\" \"*.{js,yml}\"",
43
34
  "version:patch": "yarn version --new-version patch",
44
35
  "version:minor": "yarn version --new-version minor",
45
- "version:major": "yarn version --new-version major",
46
- "version:feature": "yarn version ${npm_package_version}-$0.$(git describe | rev | cut -d '-' -f 2 | rev).g$(git rev-parse --short HEAD)",
47
- "version:prepatch": "yarn version --new-version prepatch",
48
- "version:prerelease": "yarn version ${npm_package_version}"
36
+ "version:major": "yarn version --new-version major"
49
37
  },
50
38
  "jest": {
51
39
  "verbose": true,
@@ -92,9 +80,8 @@
92
80
  "git-describe": "^4.0.4",
93
81
  "jest": "^26.0.0",
94
82
  "license-checker": "^25.0.1",
83
+ "npm-run-all": "^4.1.3",
95
84
  "prettier": "^1.14.0",
96
85
  "shx": "^0.3.2"
97
- },
98
- "packageManager": "yarn@3.5.0",
99
- "stableVersion": "0.2.4"
100
- }
86
+ }
87
+ }