jsii-release 0.2.178 → 0.2.182
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/.gitattributes +21 -20
- package/README.md +1 -0
- package/bin/jsii-release-npm +7 -0
- package/package.json +2 -2
package/.gitattributes
CHANGED
|
@@ -1,22 +1,23 @@
|
|
|
1
1
|
# ~~ Generated by projen. To modify, edit .projenrc.js and run "npx projen".
|
|
2
2
|
|
|
3
|
-
*.snap
|
|
4
|
-
/.eslintrc.json
|
|
5
|
-
/.gitattributes
|
|
6
|
-
/.github/pull_request_template.md
|
|
7
|
-
/.github/workflows/auto-approve.yml
|
|
8
|
-
/.github/workflows/build.yml
|
|
9
|
-
/.github/workflows/
|
|
10
|
-
/.github/workflows/
|
|
11
|
-
/.github/workflows/
|
|
12
|
-
/.
|
|
13
|
-
/.
|
|
14
|
-
/.
|
|
15
|
-
/.
|
|
16
|
-
/.projen
|
|
17
|
-
/.projen/
|
|
18
|
-
/
|
|
19
|
-
/
|
|
20
|
-
/
|
|
21
|
-
/tsconfig.json
|
|
22
|
-
/
|
|
3
|
+
*.snap linguist-generated
|
|
4
|
+
/.eslintrc.json linguist-generated
|
|
5
|
+
/.gitattributes linguist-generated
|
|
6
|
+
/.github/pull_request_template.md linguist-generated
|
|
7
|
+
/.github/workflows/auto-approve.yml linguist-generated
|
|
8
|
+
/.github/workflows/build.yml linguist-generated
|
|
9
|
+
/.github/workflows/pull-request-lint.yml linguist-generated
|
|
10
|
+
/.github/workflows/release.yml linguist-generated
|
|
11
|
+
/.github/workflows/stale.yml linguist-generated
|
|
12
|
+
/.github/workflows/upgrade-master.yml linguist-generated
|
|
13
|
+
/.gitignore linguist-generated
|
|
14
|
+
/.mergify.yml linguist-generated
|
|
15
|
+
/.npmignore linguist-generated
|
|
16
|
+
/.projen/** linguist-generated
|
|
17
|
+
/.projen/deps.json linguist-generated
|
|
18
|
+
/.projen/tasks.json linguist-generated
|
|
19
|
+
/LICENSE linguist-generated
|
|
20
|
+
/package.json linguist-generated
|
|
21
|
+
/tsconfig.dev.json linguist-generated
|
|
22
|
+
/tsconfig.json linguist-generated
|
|
23
|
+
/yarn.lock linguist-generated
|
package/README.md
CHANGED
|
@@ -64,6 +64,7 @@ npx jsii-release-npm [DIR]
|
|
|
64
64
|
|`NPM_DIST_TAG`|Optional|Registers the published package with the given [dist-tag](https://docs.npmjs.com/cli/dist-tag) (e.g. `next`, default is `latest`)|
|
|
65
65
|
|`AWS_ACCESS_KEY_ID`|Optional|If AWS CodeArtifact is used as registry, an AWS access key can be spedified.|
|
|
66
66
|
|`AWS_SECRET_ACCESS_KEY`|Optional|Secret access key that belongs to the AWS access key.|
|
|
67
|
+
|`AWS_ROLE_TO_ASSUME`|Optional|If AWS CodeArtifact is used as registry, an AWS role ARN to assume before authorizing.|
|
|
67
68
|
|
|
68
69
|
## Maven
|
|
69
70
|
|
package/bin/jsii-release-npm
CHANGED
|
@@ -13,6 +13,7 @@ set -eu
|
|
|
13
13
|
# NPM_REGISTRY (optional): the registry URL (defaults to "registry.npmjs.org")
|
|
14
14
|
# AWS_ACCESS_KEY_ID (optional): If AWS CodeArtifact is used as registry, an AWS access key can be spedified.
|
|
15
15
|
# AWS_SECRET_ACCESS_KEY (optional): Secret access key that belongs to the AWS access key.
|
|
16
|
+
# AWS_ROLE_TO_ASSUME (optional): If AWS CodeArtifact is used as registry and need to assume role.
|
|
16
17
|
#
|
|
17
18
|
###
|
|
18
19
|
|
|
@@ -24,6 +25,12 @@ if ! [ -z "${NPM_REGISTRY:-}" ] && [[ $NPM_REGISTRY =~ .codeartifact.*.amazonaws
|
|
|
24
25
|
codeartifact_subdomain="$(echo $NPM_REGISTRY | cut -d. -f1)"
|
|
25
26
|
codeartifact_domain="$(echo $codeartifact_subdomain | cut -b -$((${#codeartifact_subdomain}-${#codeartifact_account}-1)))"
|
|
26
27
|
codeartifact_region="$(echo $NPM_REGISTRY | cut -d. -f4)"
|
|
28
|
+
if [ -n "${AWS_ROLE_TO_ASSUME:-}" ]; then
|
|
29
|
+
credentials=`aws sts assume-role --role-session-name "jsii-release-code-artifact" --role-arn ${AWS_ROLE_TO_ASSUME} --output text | sed -n '2 p'`
|
|
30
|
+
AWS_ACCESS_KEY_ID="$(echo $credentials | cut -d' ' -f2)"
|
|
31
|
+
AWS_SECRET_ACCESS_KEY="$(echo $credentials | cut -d' ' -f4)"
|
|
32
|
+
AWS_SESSION_TOKEN="$(echo $credentials | cut -d' ' -f5)"
|
|
33
|
+
fi
|
|
27
34
|
NPM_TOKEN=`aws codeartifact get-authorization-token --domain $codeartifact_domain --domain-owner $codeartifact_account --region $codeartifact_region --query authorizationToken --output text`
|
|
28
35
|
elif [ -z "${NPM_TOKEN:-}" ]; then
|
|
29
36
|
echo "NPM_TOKEN is required"
|
package/package.json
CHANGED
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
"jest-junit": "^12",
|
|
53
53
|
"json-schema": "^0.4.0",
|
|
54
54
|
"npm-check-updates": "^11",
|
|
55
|
-
"projen": "^0.
|
|
55
|
+
"projen": "^0.34.0",
|
|
56
56
|
"standard-version": "^9",
|
|
57
57
|
"ts-jest": "^27.0.7",
|
|
58
58
|
"typescript": "^3.9.10"
|
|
@@ -69,7 +69,7 @@
|
|
|
69
69
|
"main": "lib/index.js",
|
|
70
70
|
"license": "Apache-2.0",
|
|
71
71
|
"homepage": "https://github.com/aws/jsii-release",
|
|
72
|
-
"version": "0.2.
|
|
72
|
+
"version": "0.2.182",
|
|
73
73
|
"jest": {
|
|
74
74
|
"testMatch": [
|
|
75
75
|
"**/__tests__/**/*.ts?(x)",
|