278 Commits

Author SHA1 Message Date
326c8f3f4b update dependency after merge from master 2022-03-31 18:15:50 +02:00
b65b257275 Merge remote-tracking branch 'origin/master' into releases/v2 2022-03-31 18:13:34 +02:00
e3018b0429 prepare release 2.6.0 2022-03-31 18:10:47 +02:00
0152070931 dependency updates 2022-03-31 18:07:59 +02:00
19f1eb4ca3 Fix #199 by adding new repo url https://s01.oss.sonatype.org to sonatype repo list (#201) 2022-03-31 17:30:09 +02:00
80b6b5f3ec Bump eslint from 8.11.0 to 8.12.0
Bumps [eslint](https://github.com/eslint/eslint) from 8.11.0 to 8.12.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v8.11.0...v8.12.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-03-28 11:03:07 +02:00
6e4b242aa4 Bump minimist from 1.2.5 to 1.2.6
Bumps [minimist](https://github.com/substack/minimist) from 1.2.5 to 1.2.6.
- [Release notes](https://github.com/substack/minimist/releases)
- [Commits](https://github.com/substack/minimist/compare/1.2.5...1.2.6)

---
updated-dependencies:
- dependency-name: minimist
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-03-24 19:37:09 +01:00
64ecccbb55 Bump eslint from 8.10.0 to 8.11.0
Bumps [eslint](https://github.com/eslint/eslint) from 8.10.0 to 8.11.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v8.10.0...v8.11.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-03-14 10:03:08 +01:00
76229a5532 Bump release-drafter/release-drafter from 5.18.1 to 5.19.0
Bumps [release-drafter/release-drafter](https://github.com/release-drafter/release-drafter) from 5.18.1 to 5.19.0.
- [Release notes](https://github.com/release-drafter/release-drafter/releases)
- [Commits](https://github.com/release-drafter/release-drafter/compare/v5.18.1...v5.19.0)

---
updated-dependencies:
- dependency-name: release-drafter/release-drafter
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-03-08 10:02:53 +01:00
540ba3b50e Bump actions/checkout from 2.4.0 to 3
Bumps [actions/checkout](https://github.com/actions/checkout) from 2.4.0 to 3.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v2.4.0...v3)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-03-02 10:12:27 +01:00
c693a73511 Bump actions/setup-java from 2.5.0 to 3
Bumps [actions/setup-java](https://github.com/actions/setup-java) from 2.5.0 to 3.
- [Release notes](https://github.com/actions/setup-java/releases)
- [Commits](https://github.com/actions/setup-java/compare/v2.5.0...v3)

---
updated-dependencies:
- dependency-name: actions/setup-java
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-03-02 08:31:17 +01:00
d75fc920f9 Bump actions/setup-node from 2.5.1 to 3
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 2.5.1 to 3.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](https://github.com/actions/setup-node/compare/v2.5.1...v3)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-03-02 08:31:05 +01:00
0e98e0b6d8 Bump eslint from 8.9.0 to 8.10.0
Bumps [eslint](https://github.com/eslint/eslint) from 8.9.0 to 8.10.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v8.9.0...v8.10.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-02-28 10:02:10 +01:00
f7431fd287 File sync from s4u/.github - Shared auto approve 2022-02-23 19:18:36 +00:00
289caf3566 File sync from s4u/.github - Shared auto approve 2022-02-23 19:06:46 +00:00
1e4e99ed4f File sync from s4u/.github - disable auto approve 2022-02-23 17:30:05 +00:00
5ab8e31792 Bump dependabot/fetch-metadata from 1.2.0 to 1.2.1
Bumps [dependabot/fetch-metadata](https://github.com/dependabot/fetch-metadata) from 1.2.0 to 1.2.1.
- [Release notes](https://github.com/dependabot/fetch-metadata/releases)
- [Commits](https://github.com/dependabot/fetch-metadata/compare/v1.2.0...v1.2.1)

---
updated-dependencies:
- dependency-name: dependabot/fetch-metadata
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-02-23 10:02:43 +01:00
725deec62e Bump @xmldom/xmldom from 0.8.0 to 0.8.1
Bumps [@xmldom/xmldom](https://github.com/xmldom/xmldom) from 0.8.0 to 0.8.1.
- [Release notes](https://github.com/xmldom/xmldom/releases)
- [Changelog](https://github.com/xmldom/xmldom/blob/master/CHANGELOG.md)
- [Commits](https://github.com/xmldom/xmldom/compare/0.8.0...0.8.1)

---
updated-dependencies:
- dependency-name: "@xmldom/xmldom"
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-02-15 10:02:45 +01:00
b94f36708b Bump dependabot/fetch-metadata from 1.1.1 to 1.2.0
Bumps [dependabot/fetch-metadata](https://github.com/dependabot/fetch-metadata) from 1.1.1 to 1.2.0.
- [Release notes](https://github.com/dependabot/fetch-metadata/releases)
- [Commits](https://github.com/dependabot/fetch-metadata/compare/v1.1.1...v1.2.0)

---
updated-dependencies:
- dependency-name: dependabot/fetch-metadata
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-02-15 10:02:33 +01:00
86745f73a7 Bump eslint from 8.8.0 to 8.9.0
Bumps [eslint](https://github.com/eslint/eslint) from 8.8.0 to 8.9.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v8.8.0...v8.9.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-02-14 10:02:37 +01:00
419b62e685 Bump jest from 27.5.0 to 27.5.1
Bumps [jest](https://github.com/facebook/jest) from 27.5.0 to 27.5.1.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.5.0...v27.5.1)

---
updated-dependencies:
- dependency-name: jest
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-02-09 10:03:22 +01:00
29a7ebbc13 Bump release-drafter/release-drafter from 5.18.0 to 5.18.1
Bumps [release-drafter/release-drafter](https://github.com/release-drafter/release-drafter) from 5.18.0 to 5.18.1.
- [Release notes](https://github.com/release-drafter/release-drafter/releases)
- [Commits](https://github.com/release-drafter/release-drafter/compare/v5.18.0...v5.18.1)

---
updated-dependencies:
- dependency-name: release-drafter/release-drafter
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-02-08 10:04:12 +01:00
fd308b5c65 File sync from s4u/.github - Bump release-drafter/release-drafter in /common-files 2022-02-07 10:17:00 +00:00
225e9b49d6 Bump jest from 27.4.7 to 27.5.0
Bumps [jest](https://github.com/facebook/jest) from 27.4.7 to 27.5.0.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.4.7...v27.5.0)

---
updated-dependencies:
- dependency-name: jest
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-02-07 10:03:47 +01:00
2b24cc18ff Bump release-drafter/release-drafter from 5.18.0 to 5.18.1
Bumps [release-drafter/release-drafter](https://github.com/release-drafter/release-drafter) from 5.18.0 to 5.18.1.
- [Release notes](https://github.com/release-drafter/release-drafter/releases)
- [Commits](https://github.com/release-drafter/release-drafter/compare/v5.18.0...v5.18.1)

---
updated-dependencies:
- dependency-name: release-drafter/release-drafter
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-02-07 10:02:42 +01:00
88ff0798c9 update dependency after merge from master 2022-02-04 19:19:19 +01:00
5373de8caf Merge remote-tracking branch 'origin/master' into releases/v2 2022-02-04 19:14:41 +01:00
1b2ece1047 prepare release 2.5.0 2022-02-04 19:13:48 +01:00
3fffa3a1a5 update transitive dependencies 2022-02-04 18:57:53 +01:00
654e1efa2a Add path argument so we can customize where settings.xml will be stored 2022-02-04 18:46:26 +01:00
99450b69de Bump release-drafter/release-drafter from 5.17.6 to 5.18.0
Bumps [release-drafter/release-drafter](https://github.com/release-drafter/release-drafter) from 5.17.6 to 5.18.0.
- [Release notes](https://github.com/release-drafter/release-drafter/releases)
- [Commits](https://github.com/release-drafter/release-drafter/compare/v5.17.6...v5.18.0)

---
updated-dependencies:
- dependency-name: release-drafter/release-drafter
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-02-04 10:02:35 +01:00
7b2aa2d1a4 Bump eslint from 8.7.0 to 8.8.0
Bumps [eslint](https://github.com/eslint/eslint) from 8.7.0 to 8.8.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v8.7.0...v8.8.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-01-31 10:02:24 +01:00
ecbd68aae8 Bump release-drafter/release-drafter from 5.17.5 to 5.17.6
Bumps [release-drafter/release-drafter](https://github.com/release-drafter/release-drafter) from 5.17.5 to 5.17.6.
- [Release notes](https://github.com/release-drafter/release-drafter/releases)
- [Commits](https://github.com/release-drafter/release-drafter/compare/v5.17.5...v5.17.6)

---
updated-dependencies:
- dependency-name: release-drafter/release-drafter
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-01-20 10:05:24 +01:00
adc67270c4 Bump eslint from 8.6.0 to 8.7.0
Bumps [eslint](https://github.com/eslint/eslint) from 8.6.0 to 8.7.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v8.6.0...v8.7.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-01-17 10:03:02 +01:00
5d30033c73 Bump release-drafter/release-drafter from 5.16.1 to 5.17.5
Bumps [release-drafter/release-drafter](https://github.com/release-drafter/release-drafter) from 5.16.1 to 5.17.5.
- [Release notes](https://github.com/release-drafter/release-drafter/releases)
- [Commits](https://github.com/release-drafter/release-drafter/compare/v5.16.1...v5.17.5)

---
updated-dependencies:
- dependency-name: release-drafter/release-drafter
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-01-17 10:02:49 +01:00
ce51c25fb3 Bump release-drafter/release-drafter from 5.15.0 to 5.16.1
Bumps [release-drafter/release-drafter](https://github.com/release-drafter/release-drafter) from 5.15.0 to 5.16.1.
- [Release notes](https://github.com/release-drafter/release-drafter/releases)
- [Commits](https://github.com/release-drafter/release-drafter/compare/v5.15.0...v5.16.1)

---
updated-dependencies:
- dependency-name: release-drafter/release-drafter
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-01-13 10:02:02 +01:00
3e95bcc617 Bump jest from 27.4.6 to 27.4.7
Bumps [jest](https://github.com/facebook/jest) from 27.4.6 to 27.4.7.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.4.6...v27.4.7)

---
updated-dependencies:
- dependency-name: jest
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-01-06 10:04:25 +01:00
5738bc53ee Bump jest from 27.4.5 to 27.4.6
Bumps [jest](https://github.com/facebook/jest) from 27.4.5 to 27.4.6.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.4.5...v27.4.6)

---
updated-dependencies:
- dependency-name: jest
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-01-05 10:06:32 +01:00
82bb003fcd Bump eslint from 8.5.0 to 8.6.0
Bumps [eslint](https://github.com/eslint/eslint) from 8.5.0 to 8.6.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v8.5.0...v8.6.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-01-03 10:02:22 +01:00
75f170191f Bump actions/setup-node from 2.5.0 to 2.5.1
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 2.5.0 to 2.5.1.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](https://github.com/actions/setup-node/compare/v2.5.0...v2.5.1)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-12-29 10:02:09 +01:00
6f5b6fbaab Bump @xmldom/xmldom from 0.7.5 to 0.8.0
Bumps [@xmldom/xmldom](https://github.com/xmldom/xmldom) from 0.7.5 to 0.8.0.
- [Release notes](https://github.com/xmldom/xmldom/releases)
- [Changelog](https://github.com/xmldom/xmldom/blob/master/CHANGELOG.md)
- [Commits](https://github.com/xmldom/xmldom/compare/0.7.5...0.8.0)

---
updated-dependencies:
- dependency-name: "@xmldom/xmldom"
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-12-23 10:01:57 +01:00
feb3088148 Bump actions/setup-java from 2.4.0 to 2.5.0
Bumps [actions/setup-java](https://github.com/actions/setup-java) from 2.4.0 to 2.5.0.
- [Release notes](https://github.com/actions/setup-java/releases)
- [Commits](https://github.com/actions/setup-java/compare/v2.4.0...v2.5.0)

---
updated-dependencies:
- dependency-name: actions/setup-java
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-12-22 10:02:35 +01:00
7329cb6a46 Bump eslint from 8.4.1 to 8.5.0
Bumps [eslint](https://github.com/eslint/eslint) from 8.4.1 to 8.5.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v8.4.1...v8.5.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-12-20 10:02:18 +01:00
51c4bad48c Bump jest from 27.4.4 to 27.4.5
Bumps [jest](https://github.com/facebook/jest) from 27.4.4 to 27.4.5.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.4.4...v27.4.5)

---
updated-dependencies:
- dependency-name: jest
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-12-14 10:04:30 +01:00
42af4127c2 Bump jest from 27.4.3 to 27.4.4
Bumps [jest](https://github.com/facebook/jest) from 27.4.3 to 27.4.4.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.4.3...v27.4.4)

---
updated-dependencies:
- dependency-name: jest
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-12-10 10:03:06 +01:00
7b38eeb324 Bump eslint from 8.4.0 to 8.4.1
Bumps [eslint](https://github.com/eslint/eslint) from 8.4.0 to 8.4.1.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v8.4.0...v8.4.1)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-12-07 10:02:28 +01:00
867d0c0745 Bump eslint from 8.3.0 to 8.4.0
Bumps [eslint](https://github.com/eslint/eslint) from 8.3.0 to 8.4.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v8.3.0...v8.4.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-12-06 10:02:13 +01:00
c9c15c64e0 Bump jest from 27.4.2 to 27.4.3
Bumps [jest](https://github.com/facebook/jest) from 27.4.2 to 27.4.3.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.4.2...v27.4.3)

---
updated-dependencies:
- dependency-name: jest
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-12-02 10:03:28 +01:00
6de8e2452a Bump jest from 27.4.1 to 27.4.2
Bumps [jest](https://github.com/facebook/jest) from 27.4.1 to 27.4.2.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.4.1...v27.4.2)

---
updated-dependencies:
- dependency-name: jest
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-12-01 10:04:29 +01:00
5de6451692 Bump jest from 27.3.1 to 27.4.1
Bumps [jest](https://github.com/facebook/jest) from 27.3.1 to 27.4.1.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.3.1...v27.4.1)

---
updated-dependencies:
- dependency-name: jest
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-11-30 10:03:32 +01:00
a9e6c9c41f Bump actions/setup-java from 2.3.1 to 2.4.0
Bumps [actions/setup-java](https://github.com/actions/setup-java) from 2.3.1 to 2.4.0.
- [Release notes](https://github.com/actions/setup-java/releases)
- [Commits](https://github.com/actions/setup-java/compare/v2.3.1...v2.4.0)

---
updated-dependencies:
- dependency-name: actions/setup-java
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-11-30 10:02:36 +01:00
47c8d321e3 Bump actions/setup-node from 2.4.1 to 2.5.0
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 2.4.1 to 2.5.0.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](https://github.com/actions/setup-node/compare/v2.4.1...v2.5.0)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-11-30 10:02:25 +01:00
8cb72385b3 Bump eslint from 8.2.0 to 8.3.0
Bumps [eslint](https://github.com/eslint/eslint) from 8.2.0 to 8.3.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v8.2.0...v8.3.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-11-22 10:02:10 +01:00
3a980c19bf Bump eslint from 8.1.0 to 8.2.0
Bumps [eslint](https://github.com/eslint/eslint) from 8.1.0 to 8.2.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v8.1.0...v8.2.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-11-08 10:02:11 +01:00
7ea3acccf3 Bump actions/checkout from 2.3.5 to 2.4.0
Bumps [actions/checkout](https://github.com/actions/checkout) from 2.3.5 to 2.4.0.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v2.3.5...v2.4.0)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-11-03 10:04:54 +01:00
340fb57bde Bump eslint from 8.0.1 to 8.1.0
Bumps [eslint](https://github.com/eslint/eslint) from 8.0.1 to 8.1.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v8.0.1...v8.1.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-10-25 11:02:02 +02:00
5de8781894 Bump jest from 27.3.0 to 27.3.1
Bumps [jest](https://github.com/facebook/jest) from 27.3.0 to 27.3.1.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.3.0...v27.3.1)

---
updated-dependencies:
- dependency-name: jest
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-10-19 11:03:23 +02:00
325887fbac Bump jest from 27.2.5 to 27.3.0
Bumps [jest](https://github.com/facebook/jest) from 27.2.5 to 27.3.0.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.2.5...v27.3.0)

---
updated-dependencies:
- dependency-name: jest
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-10-18 11:03:21 +02:00
59f0fc1839 Bump actions/checkout from 2.3.4 to 2.3.5
Bumps [actions/checkout](https://github.com/actions/checkout) from 2.3.4 to 2.3.5.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v2.3.4...v2.3.5)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-10-18 11:02:12 +02:00
8501f24f2e Bump eslint from 7.32.0 to 8.0.1
Bumps [eslint](https://github.com/eslint/eslint) from 7.32.0 to 8.0.1.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.32.0...v8.0.1)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-10-17 21:16:50 +02:00
795681b63f Bump jest from 27.2.4 to 27.2.5
Bumps [jest](https://github.com/facebook/jest) from 27.2.4 to 27.2.5.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.2.4...v27.2.5)

---
updated-dependencies:
- dependency-name: jest
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-10-11 11:03:03 +02:00
962b72b668 Bump jest from 27.2.3 to 27.2.4
Bumps [jest](https://github.com/facebook/jest) from 27.2.3 to 27.2.4.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.2.3...v27.2.4)

---
updated-dependencies:
- dependency-name: jest
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-09-30 11:02:32 +02:00
93e13a8041 Bump actions/setup-java from 2.3.0 to 2.3.1
Bumps [actions/setup-java](https://github.com/actions/setup-java) from 2.3.0 to 2.3.1.
- [Release notes](https://github.com/actions/setup-java/releases)
- [Commits](https://github.com/actions/setup-java/compare/v2.3.0...v2.3.1)

---
updated-dependencies:
- dependency-name: actions/setup-java
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-09-30 11:02:16 +02:00
84b0c6e443 Bump jest from 27.2.2 to 27.2.3
Bumps [jest](https://github.com/facebook/jest) from 27.2.2 to 27.2.3.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.2.2...v27.2.3)

---
updated-dependencies:
- dependency-name: jest
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-09-29 11:02:21 +02:00
4725c2bf1d Bump @actions/core from 1.5.0 to 1.6.0
Bumps [@actions/core](https://github.com/actions/toolkit/tree/HEAD/packages/core) from 1.5.0 to 1.6.0.
- [Release notes](https://github.com/actions/toolkit/releases)
- [Changelog](https://github.com/actions/toolkit/blob/main/packages/core/RELEASES.md)
- [Commits](https://github.com/actions/toolkit/commits/HEAD/packages/core)

---
updated-dependencies:
- dependency-name: "@actions/core"
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-09-29 11:01:40 +02:00
492e0b5646 Bump actions/setup-node from 2.4.0 to 2.4.1
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 2.4.0 to 2.4.1.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](https://github.com/actions/setup-node/compare/v2.4.0...v2.4.1)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-09-28 11:02:32 +02:00
1bf3a84fa8 Bump jest from 27.2.1 to 27.2.2
Bumps [jest](https://github.com/facebook/jest) from 27.2.1 to 27.2.2.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.2.1...v27.2.2)

---
updated-dependencies:
- dependency-name: jest
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-09-27 11:02:27 +02:00
96797eff7a Bump jest from 27.2.0 to 27.2.1
Bumps [jest](https://github.com/facebook/jest) from 27.2.0 to 27.2.1.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.2.0...v27.2.1)

---
updated-dependencies:
- dependency-name: jest
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-09-21 11:02:51 +02:00
2c300bd1b5 Bump @xmldom/xmldom from 0.7.4 to 0.7.5
Bumps [@xmldom/xmldom](https://github.com/xmldom/xmldom) from 0.7.4 to 0.7.5.
- [Release notes](https://github.com/xmldom/xmldom/releases)
- [Changelog](https://github.com/xmldom/xmldom/blob/master/CHANGELOG.md)
- [Commits](https://github.com/xmldom/xmldom/compare/0.7.4...0.7.5)

---
updated-dependencies:
- dependency-name: "@xmldom/xmldom"
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-09-14 11:01:55 +02:00
c25e9f11a2 Bump jest from 27.1.1 to 27.2.0
Bumps [jest](https://github.com/facebook/jest) from 27.1.1 to 27.2.0.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.1.1...v27.2.0)

---
updated-dependencies:
- dependency-name: jest
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-09-13 11:03:11 +02:00
342ff43418 Bump jest from 27.1.0 to 27.1.1
Bumps [jest](https://github.com/facebook/jest) from 27.1.0 to 27.1.1.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/main/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.1.0...v27.1.1)

---
updated-dependencies:
- dependency-name: jest
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-09-09 11:03:13 +02:00
65afe6e642 Bump @xmldom/xmldom from 0.7.3 to 0.7.4
Bumps [@xmldom/xmldom](https://github.com/xmldom/xmldom) from 0.7.3 to 0.7.4.
- [Release notes](https://github.com/xmldom/xmldom/releases)
- [Changelog](https://github.com/xmldom/xmldom/blob/0.7.4/CHANGELOG.md)
- [Commits](https://github.com/xmldom/xmldom/compare/0.7.3...0.7.4)

---
updated-dependencies:
- dependency-name: "@xmldom/xmldom"
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-09-01 11:02:43 +02:00
f6c76cd373 fix setup maven action name 2021-08-31 08:32:20 +02:00
98247d0ae9 Bump jest from 27.0.6 to 27.1.0
Bumps [jest](https://github.com/facebook/jest) from 27.0.6 to 27.1.0.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.0.6...v27.1.0)

---
updated-dependencies:
- dependency-name: jest
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-08-30 11:04:08 +02:00
925227526f Bump @xmldom/xmldom from 0.7.2 to 0.7.3
Bumps [@xmldom/xmldom](https://github.com/xmldom/xmldom) from 0.7.2 to 0.7.3.
- [Release notes](https://github.com/xmldom/xmldom/releases)
- [Changelog](https://github.com/xmldom/xmldom/blob/master/CHANGELOG.md)
- [Commits](https://github.com/xmldom/xmldom/compare/0.7.2...0.7.3)

---
updated-dependencies:
- dependency-name: "@xmldom/xmldom"
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-08-30 11:02:25 +02:00
10acc8417d Info about Setup Maven in readme 2021-08-29 23:06:28 +02:00
e1f1777848 File sync from s4u/.github - include main branch in builds 2021-08-29 19:48:10 +00:00
0a46b0e7e2 File sync from s4u/.github - Use Tech Token for Auto Approve 2021-08-29 19:39:10 +00:00
105d52a082 File sync from s4u/.github - Auto merge patch and minor updates 2021-08-28 21:42:14 +00:00
fa0828fa00 File sync from s4u/.github - Auto Approve by gh cli 2021-08-28 21:32:29 +00:00
bf27dabd7d Bump actions/setup-java from 2.2.0 to 2.3.0
Bumps [actions/setup-java](https://github.com/actions/setup-java) from 2.2.0 to 2.3.0.
- [Release notes](https://github.com/actions/setup-java/releases)
- [Commits](https://github.com/actions/setup-java/compare/v2.2.0...v2.3.0)

---
updated-dependencies:
- dependency-name: actions/setup-java
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-08-24 11:02:00 +02:00
9a09df6b9f Bump @xmldom/xmldom from 0.7.1 to 0.7.2
Bumps [@xmldom/xmldom](https://github.com/xmldom/xmldom) from 0.7.1 to 0.7.2.
- [Release notes](https://github.com/xmldom/xmldom/releases)
- [Changelog](https://github.com/xmldom/xmldom/blob/master/CHANGELOG.md)
- [Commits](https://github.com/xmldom/xmldom/compare/0.7.1...0.7.2)

---
updated-dependencies:
- dependency-name: "@xmldom/xmldom"
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-08-23 11:01:57 +02:00
902651b0f8 update dependency after merge from masterupdate dependency after merge from master 2021-08-20 13:33:39 +02:00
9d88753cb7 Merge remote-tracking branch 'origin/master' into releases/v2 2021-08-20 13:29:55 +02:00
9ecac33057 prepare release 2.4.1 2021-08-20 13:28:18 +02:00
a71cff0af4 Merge pull request #136 from s4u/update-readme-by-npm
update readme during npm version runs
2021-08-20 13:26:50 +02:00
74b488d6b5 update readme during npm version runs 2021-08-20 13:20:03 +02:00
0679058832 Merge pull request #135 from s4u/npm-update
update transitive dependencies
2021-08-20 11:58:44 +02:00
4e79deaadf update transitive dependencies 2021-08-20 11:54:36 +02:00
b071b0592f Bump actions/setup-java from 2.1.0 to 2.2.0
Bumps [actions/setup-java](https://github.com/actions/setup-java) from 2.1.0 to 2.2.0.
- [Release notes](https://github.com/actions/setup-java/releases)
- [Commits](https://github.com/actions/setup-java/compare/v2.1.0...v2.2.0)

---
updated-dependencies:
- dependency-name: actions/setup-java
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-08-20 11:49:45 +02:00
e087497fdf Bump actions/setup-node from 2.3.0 to 2.4.0
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 2.3.0 to 2.4.0.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](https://github.com/actions/setup-node/compare/v2.3.0...v2.4.0)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-08-20 11:49:09 +02:00
ae3ee5e171 Bump @actions/core from 1.4.0 to 1.5.0
Bumps [@actions/core](https://github.com/actions/toolkit/tree/HEAD/packages/core) from 1.4.0 to 1.5.0.
- [Release notes](https://github.com/actions/toolkit/releases)
- [Changelog](https://github.com/actions/toolkit/blob/main/packages/core/RELEASES.md)
- [Commits](https://github.com/actions/toolkit/commits/HEAD/packages/core)

---
updated-dependencies:
- dependency-name: "@actions/core"
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-08-20 11:46:18 +02:00
6c0723a451 Merge pull request #133 from s4u/fix-xmldom
Update xmldom to @xmldom/xmldom
2021-08-20 11:44:29 +02:00
1c0881314a Update xmldom to @xmldom/xmldom 2021-08-20 11:39:29 +02:00
3d30ad6b13 Bump eslint from 7.31.0 to 7.32.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.31.0 to 7.32.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.31.0...v7.32.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-08-02 11:02:13 +02:00
09765986ab Bump actions/setup-node from 2.2.0 to 2.3.0
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 2.2.0 to 2.3.0.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](https://github.com/actions/setup-node/compare/v2.2.0...v2.3.0)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-07-21 11:01:58 +02:00
3a0220074b Bump eslint from 7.30.0 to 7.31.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.30.0 to 7.31.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.30.0...v7.31.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-07-19 11:01:56 +02:00
e2b4671ab7 Bump eslint from 7.29.0 to 7.30.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.29.0 to 7.30.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.29.0...v7.30.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-07-05 11:02:03 +02:00
503fafc2f9 Bump actions/setup-node from 2.1.5 to 2.2.0
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 2.1.5 to 2.2.0.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](https://github.com/actions/setup-node/compare/v2.1.5...v2.2.0)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-07-01 11:02:26 +02:00
b8ae32e043 File sync from s4u/.github - enable auto merge 2021-06-30 23:49:15 +00:00
9ad80eb4e3 Bump jest from 27.0.4 to 27.0.6
Bumps [jest](https://github.com/facebook/jest) from 27.0.4 to 27.0.6.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.0.4...v27.0.6)

---
updated-dependencies:
- dependency-name: jest
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-06-30 20:26:33 +00:00
f44510e5ab enable auto merge 2021-06-30 22:23:36 +02:00
0de22f6a26 Bump eslint from 7.28.0 to 7.29.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.28.0 to 7.29.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.28.0...v7.29.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-06-30 21:17:09 +02:00
1615e72b3a Bump @actions/core from 1.3.0 to 1.4.0
Bumps [@actions/core](https://github.com/actions/toolkit/tree/HEAD/packages/core) from 1.3.0 to 1.4.0.
- [Release notes](https://github.com/actions/toolkit/releases)
- [Changelog](https://github.com/actions/toolkit/blob/main/packages/core/RELEASES.md)
- [Commits](https://github.com/actions/toolkit/commits/HEAD/packages/core)

---
updated-dependencies:
- dependency-name: "@actions/core"
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-06-18 08:32:30 +02:00
24a1a88f1e Bump eslint from 7.27.0 to 7.28.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.27.0 to 7.28.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.27.0...v7.28.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-06-07 23:01:02 +02:00
5878d2e8e2 Bump jest from 27.0.3 to 27.0.4
Bumps [jest](https://github.com/facebook/jest) from 27.0.3 to 27.0.4.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.0.3...v27.0.4)

---
updated-dependencies:
- dependency-name: jest
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-06-07 22:50:46 +02:00
2c9c4267b8 Bump jest from 27.0.1 to 27.0.3
Bumps [jest](https://github.com/facebook/jest) from 27.0.1 to 27.0.3.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.0.1...v27.0.3)

Signed-off-by: dependabot[bot] <support@github.com>
2021-06-02 18:41:23 +02:00
273dffbe20 Bump jest from 27.0.0 to 27.0.1
Bumps [jest](https://github.com/facebook/jest) from 27.0.0 to 27.0.1.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v27.0.0...v27.0.1)

Signed-off-by: dependabot[bot] <support@github.com>
2021-05-27 21:40:37 +02:00
a29bb45705 Bump @actions/core from 1.2.7 to 1.3.0
Bumps [@actions/core](https://github.com/actions/toolkit/tree/HEAD/packages/core) from 1.2.7 to 1.3.0.
- [Release notes](https://github.com/actions/toolkit/releases)
- [Changelog](https://github.com/actions/toolkit/blob/main/packages/core/RELEASES.md)
- [Commits](https://github.com/actions/toolkit/commits/HEAD/packages/core)

Signed-off-by: dependabot[bot] <support@github.com>
2021-05-25 11:53:34 +02:00
cc53414d90 Bump eslint from 7.26.0 to 7.27.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.26.0 to 7.27.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.26.0...v7.27.0)

Signed-off-by: dependabot[bot] <support@github.com>
2021-05-25 11:37:57 +02:00
6fd30a11d2 Bump jest from 26.6.3 to 27.0.0
Bumps [jest](https://github.com/facebook/jest) from 26.6.3 to 27.0.0.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v26.6.3...v27.0.0)

Signed-off-by: dependabot[bot] <support@github.com>
2021-05-25 11:24:44 +02:00
86c0b9f97d organization wide release-drafter configuration 2021-05-18 23:12:33 +02:00
11c40ea0e1 Bump eslint from 7.25.0 to 7.26.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.25.0 to 7.26.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.25.0...v7.26.0)

Signed-off-by: dependabot[bot] <support@github.com>
2021-05-18 22:47:13 +02:00
c451ddf0ee Bump actions/setup-java from 2.0.0 to 2.1.0
Bumps [actions/setup-java](https://github.com/actions/setup-java) from 2.0.0 to 2.1.0.
- [Release notes](https://github.com/actions/setup-java/releases)
- [Commits](https://github.com/actions/setup-java/compare/v2.0.0...v2.1.0)

Signed-off-by: dependabot[bot] <support@github.com>
2021-05-18 22:46:15 +02:00
5935b2506f Merge pull request #111 from s4u/fix-audit-1677
bump hosted-git-info to fix security issue
2021-05-18 22:41:03 +02:00
6c6439978a bump hosted-git-info to fix security issue
https://npmjs.com/advisories/1677
2021-05-18 22:33:56 +02:00
cc60484bd8 Bump eslint from 7.24.0 to 7.25.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.24.0 to 7.25.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.24.0...v7.25.0)

Signed-off-by: dependabot[bot] <support@github.com>
2021-04-26 23:55:19 +02:00
51e9e89b47 Bump xmldom from 0.5.0 to 0.6.0
Bumps [xmldom](https://github.com/xmldom/xmldom) from 0.5.0 to 0.6.0.
- [Release notes](https://github.com/xmldom/xmldom/releases)
- [Changelog](https://github.com/xmldom/xmldom/blob/master/CHANGELOG.md)
- [Commits](https://github.com/xmldom/xmldom/compare/0.5.0...0.6.0)

Signed-off-by: dependabot[bot] <support@github.com>
2021-04-23 13:57:21 +02:00
2c41469899 File sync from s4u/.github 2021-04-19 21:03:48 +00:00
8636f71a85 Bump @actions/core from 1.2.6 to 1.2.7
Bumps [@actions/core](https://github.com/actions/toolkit/tree/HEAD/packages/core) from 1.2.6 to 1.2.7.
- [Release notes](https://github.com/actions/toolkit/releases)
- [Changelog](https://github.com/actions/toolkit/blob/main/packages/core/RELEASES.md)
- [Commits](https://github.com/actions/toolkit/commits/HEAD/packages/core)

Signed-off-by: dependabot[bot] <support@github.com>
2021-04-14 11:53:05 +02:00
02b233c563 Bump eslint from 7.23.0 to 7.24.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.23.0 to 7.24.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.23.0...v7.24.0)

Signed-off-by: dependabot[bot] <support@github.com>
2021-04-13 19:17:19 +02:00
fc211602ad File sync from s4u/.github 2021-04-10 07:32:49 +00:00
b6682b450c File sync from s4u/.github 2021-04-09 17:59:49 +00:00
7ded67fa42 Merge pull request #104 from s4u/dependabot/github_actions/actions/setup-java-v2
Bump actions/setup-java from v1 to v2
2021-04-06 19:17:14 +02:00
fbbf52f12f actions/setup-java@v2 - migration 2021-04-06 19:14:10 +02:00
9feb081430 Bump actions/setup-java from v1 to v2
Bumps [actions/setup-java](https://github.com/actions/setup-java) from v1 to v2.
- [Release notes](https://github.com/actions/setup-java/releases)
- [Commits](https://github.com/actions/setup-java/compare/v1...8764a52df183aa0ccea74521dfd9d506ffc7a19a)

Signed-off-by: dependabot[bot] <support@github.com>
2021-04-06 09:00:30 +00:00
7c53eac0ad Bump eslint from 7.22.0 to 7.23.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.22.0 to 7.23.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.22.0...v7.23.0)

Signed-off-by: dependabot[bot] <support@github.com>
2021-03-29 22:27:38 +02:00
49d8434231 Grammar fixes 2021-03-29 22:27:14 +02:00
189ee46453 Bump eslint from 7.21.0 to 7.22.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.21.0 to 7.22.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.21.0...v7.22.0)

Signed-off-by: dependabot[bot] <support@github.com>
2021-03-26 14:59:53 +01:00
59c3eb5376 File sync from s4u/.github 2021-03-17 21:42:20 +00:00
4723e93063 File sync from s4u/.github 2021-03-17 21:24:20 +00:00
8bb0fda6df Bump xmldom from 0.4.0 to 0.5.0
Bumps [xmldom](https://github.com/xmldom/xmldom) from 0.4.0 to 0.5.0.
- [Release notes](https://github.com/xmldom/xmldom/releases)
- [Changelog](https://github.com/xmldom/xmldom/blob/master/CHANGELOG.md)
- [Commits](https://github.com/xmldom/xmldom/compare/0.4.0...0.5.0)

Signed-off-by: dependabot[bot] <support@github.com>
2021-03-09 22:09:24 +01:00
5e8470faff File sync from s4u/.github 2021-03-06 11:18:14 +00:00
e967605742 update dependency after merge from master 2021-02-28 20:25:07 +01:00
e65dc96bde Merge remote-tracking branch 'origin/master' into releases/v2 2021-02-28 20:22:43 +01:00
b742fc533f prepare release 2.4.0 2021-02-28 20:20:35 +01:00
d1f8f65870 Merge pull request #97 from s4u/dependabot/github_actions/actions/setup-node-v2.1.5
Bump actions/setup-node from v2.1.4 to v2.1.5
2021-02-28 11:42:22 +01:00
de53ea431e Bump actions/setup-node from v2.1.4 to v2.1.5
Bumps [actions/setup-node](https://github.com/actions/setup-node) from v2.1.4 to v2.1.5.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](https://github.com/actions/setup-node/compare/v2.1.4...46071b5c7a2e0c34e49c3cb8a0e792e86e18d5ea)

Signed-off-by: dependabot[bot] <support@github.com>
2021-02-23 09:00:30 +00:00
cd16d8406c Completed the attribute support for servers. (#95)
* Completed the attribute support for servers, and password is optional. Resolves #92.

* Updated oracleServers.xml template to match new servers.xml template.

* Revised tests to match code and template changes.

* Added documentation for server attributes.

* Added additional use cases to exercise server attribute handling.
2021-02-16 22:46:27 +01:00
abf1253b29 Merge pull request #94 from awhitford/typos
Corrected typos. Resolves #93.
2021-02-16 08:29:57 +01:00
7a5cb7ba33 Merge pull request #91 from s4u/dependabot/npm_and_yarn/eslint-7.20.0
Bump eslint from 7.19.0 to 7.20.0
2021-02-16 08:27:27 +01:00
7799be5210 Bump eslint from 7.19.0 to 7.20.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.19.0 to 7.20.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.19.0...v7.20.0)

Signed-off-by: dependabot[bot] <support@github.com>
2021-02-16 07:19:24 +00:00
82e778d8d7 File sync from s4u/.github 2021-02-16 07:05:18 +00:00
175b85e48d Corrected typos. Resolves #93. 2021-02-15 14:23:05 -08:00
40cb7c6ba4 Merge pull request #89 from s4u/dependabot/npm_and_yarn/eslint-7.19.0
Bump eslint from 7.18.0 to 7.19.0
2021-02-07 14:43:44 +01:00
a154ae5bb3 Bump eslint from 7.18.0 to 7.19.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.18.0 to 7.19.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.18.0...v7.19.0)

Signed-off-by: dependabot[bot] <support@github.com>
2021-02-01 09:06:12 +00:00
26b06607c7 Merge pull request #88 from s4u/dependabot/npm_and_yarn/eslint-7.18.0
Bump eslint from 7.17.0 to 7.18.0
2021-01-18 20:00:27 +01:00
5391894326 Bump eslint from 7.17.0 to 7.18.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.17.0 to 7.18.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.17.0...v7.18.0)

Signed-off-by: dependabot[bot] <support@github.com>
2021-01-18 09:01:10 +00:00
a9c25dcc48 Merge pull request #87 from s4u/dependabot/npm_and_yarn/eslint-7.17.0
Bump eslint from 7.16.0 to 7.17.0
2021-01-04 11:22:39 +01:00
6240d8dec2 Bump eslint from 7.16.0 to 7.17.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.16.0 to 7.17.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.16.0...v7.17.0)

Signed-off-by: dependabot[bot] <support@github.com>
2021-01-04 09:01:04 +00:00
0ae2055ed1 File sync from s4u/.github 2020-12-29 18:32:24 +00:00
eb98cf558d File sync from s4u/.github 2020-12-28 00:31:56 +00:00
df02243d71 update dependency after merge from master 2020-12-21 23:49:59 +01:00
a2731cf297 Merge remote-tracking branch 'origin/master' into releases/v2 2020-12-21 23:46:41 +01:00
fe12eba098 prepare release 2.3.0 2020-12-21 23:44:58 +01:00
fa0be5f968 refresh package-lock.json 2020-12-21 23:38:49 +01:00
2a1bf9c27e Merge pull request #86 from s4u/fix-84
Allow defining custom configuration for server
2020-12-21 23:35:13 +01:00
060e4442b5 Allow defining custom configuration for server
fix #84
2020-12-21 23:28:12 +01:00
4309eaf1f7 Merge pull request #85 from s4u/dependabot/npm_and_yarn/eslint-7.16.0
Bump eslint from 7.15.0 to 7.16.0
2020-12-21 15:56:32 +01:00
530d13699b Bump eslint from 7.15.0 to 7.16.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.15.0 to 7.16.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.15.0...v7.16.0)

Signed-off-by: dependabot[bot] <support@github.com>
2020-12-21 09:01:10 +00:00
78af212661 Merge pull request #83 from s4u/dependabot/github_actions/actions/setup-node-v2.1.4
Bump actions/setup-node from v2.1.3 to v2.1.4
2020-12-18 14:01:45 +01:00
6781626242 Bump actions/setup-node from v2.1.3 to v2.1.4
Bumps [actions/setup-node](https://github.com/actions/setup-node) from v2.1.3 to v2.1.4.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](https://github.com/actions/setup-node/compare/v2.1.3...c46424eee26de4078d34105d3de3cc4992202b1e)

Signed-off-by: dependabot[bot] <support@github.com>
2020-12-17 09:00:28 +00:00
c2d71a67ea Merge pull request #82 from jimmyd-be/master
Add note to explain situation with actions/cache
2020-12-15 10:49:53 +01:00
25300b87d9 Add note to explain situation with actions/cache 2020-12-14 21:01:26 +01:00
75f172be63 Merge pull request #80 from s4u/dependabot/github_actions/actions/setup-node-v2.1.3
Bump actions/setup-node from v2.1.2 to v2.1.3
2020-12-12 20:47:49 +01:00
7e15ec568d Bump actions/setup-node from v2.1.2 to v2.1.3
Bumps [actions/setup-node](https://github.com/actions/setup-node) from v2.1.2 to v2.1.3.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](https://github.com/actions/setup-node/compare/v2.1.2...27082cecf3ff7a1742dbd5e12605f0cb59dce2d9)

Signed-off-by: dependabot[bot] <support@github.com>
2020-12-12 19:43:35 +00:00
a8a028af57 File sync from s4u/.github 2020-12-12 11:38:50 +00:00
2426826ebc File sync from s4u/.github 2020-12-12 11:32:50 +00:00
b1f588d74f Merge pull request #79 from s4u/dependabot/npm_and_yarn/eslint-7.15.0
Bump eslint from 7.14.0 to 7.15.0
2020-12-10 01:22:34 +01:00
bfee59b12a Bump eslint from 7.14.0 to 7.15.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.14.0 to 7.15.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.14.0...v7.15.0)

Signed-off-by: dependabot[bot] <support@github.com>
2020-12-07 09:01:15 +00:00
d016a0cc3c Merge pull request #78 from rnc/BR1
Issue #77 : Clarify documentation for secrets
2020-12-02 23:08:08 +01:00
fbff164add Issue #77 : Clarify documentation for secrets 2020-12-02 15:58:33 +00:00
96e7617cbc Merge pull request #76 from s4u/dependabot/npm_and_yarn/eslint-7.14.0
Bump eslint from 7.13.0 to 7.14.0
2020-11-23 16:33:35 +01:00
e970e3e5f9 Bump eslint from 7.13.0 to 7.14.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.13.0 to 7.14.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.13.0...v7.14.0)

Signed-off-by: dependabot[bot] <support@github.com>
2020-11-23 09:01:17 +00:00
07702512f4 Merge pull request #75 from s4u/dependabot/npm_and_yarn/eslint-7.13.0
Bump eslint from 7.12.1 to 7.13.0
2020-11-10 15:58:30 +01:00
d07365e2cd Bump eslint from 7.12.1 to 7.13.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.12.1 to 7.13.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.12.1...v7.13.0)

Signed-off-by: dependabot[bot] <support@github.com>
2020-11-10 07:49:31 +00:00
7b2fa81b55 Merge pull request #74 from s4u/dependabot/npm_and_yarn/jest-26.6.3
Bump jest from 26.6.1 to 26.6.3
2020-11-10 08:48:26 +01:00
772d1cd04c Bump jest from 26.6.1 to 26.6.3
Bumps [jest](https://github.com/facebook/jest) from 26.6.1 to 26.6.3.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v26.6.1...v26.6.3)

Signed-off-by: dependabot[bot] <support@github.com>
2020-11-10 07:45:40 +00:00
3d63f86fbc Merge pull request #73 from s4u/dependabot/github_actions/actions/checkout-v2.3.4
Bump actions/checkout from v2.3.3 to v2.3.4
2020-11-10 08:44:33 +01:00
54bf9b072d Bump actions/checkout from v2.3.3 to v2.3.4
Bumps [actions/checkout](https://github.com/actions/checkout) from v2.3.3 to v2.3.4.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v2.3.3...5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f)

Signed-off-by: dependabot[bot] <support@github.com>
2020-11-05 22:19:11 +00:00
bda41227d8 File sync from s4u/.github 2020-11-05 22:11:09 +00:00
9c42cb38ac Merge pull request #70 from s4u/dependabot/npm_and_yarn/xmldom-0.4.0
Bump xmldom from 0.3.0 to 0.4.0
2020-11-01 20:51:35 +01:00
b034b76077 Bump xmldom from 0.3.0 to 0.4.0
Bumps [xmldom](https://github.com/xmldom/xmldom) from 0.3.0 to 0.4.0.
- [Release notes](https://github.com/xmldom/xmldom/releases)
- [Changelog](https://github.com/xmldom/xmldom/blob/master/CHANGELOG.md)
- [Commits](https://github.com/xmldom/xmldom/compare/0.3.0...0.4.0)

Signed-off-by: dependabot[bot] <support@github.com>
2020-11-01 19:46:59 +00:00
ed5f8cf141 Merge pull request #69 from s4u/dependabot/npm_and_yarn/eslint-7.12.1
Bump eslint from 7.11.0 to 7.12.1
2020-11-01 20:45:51 +01:00
ae0dfdae9b Bump eslint from 7.11.0 to 7.12.1
Bumps [eslint](https://github.com/eslint/eslint) from 7.11.0 to 7.12.1.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.11.0...v7.12.1)

Signed-off-by: dependabot[bot] <support@github.com>
2020-11-01 19:22:05 +00:00
f033cb9cb6 File sync from s4u/.github 2020-11-01 19:20:46 +00:00
e7ad595eea Merge pull request #68 from s4u/dependabot/npm_and_yarn/jest-26.6.1
Bump jest from 26.6.0 to 26.6.1
2020-10-27 22:35:55 +01:00
4037eb19d4 Bump jest from 26.6.0 to 26.6.1
Bumps [jest](https://github.com/facebook/jest) from 26.6.0 to 26.6.1.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v26.6.0...v26.6.1)

Signed-off-by: dependabot[bot] <support@github.com>
2020-10-26 09:01:08 +00:00
c5205056ba Merge pull request #66 from s4u/dependabot/npm_and_yarn/jest-26.6.0
Bump jest from 26.5.3 to 26.6.0
2020-10-21 14:26:06 +02:00
cdd3549d27 Bump jest from 26.5.3 to 26.6.0
Bumps [jest](https://github.com/facebook/jest) from 26.5.3 to 26.6.0.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v26.5.3...v26.6.0)

Signed-off-by: dependabot[bot] <support@github.com>
2020-10-20 09:01:18 +00:00
92800f80ea update dependency after merge from master 2020-10-16 17:22:32 +02:00
ff8dced6da Merge remote-tracking branch 'origin/master' into releases/v2 2020-10-16 17:20:39 +02:00
a55e80ab14 New release prepare 2020-10-16 17:07:11 +02:00
27b9fae681 Merge pull request #65 from s4u/apache-snapshot
Apache snapshots repository
2020-10-16 16:32:00 +02:00
71886e4f1b Apache snapshots repository 2020-10-16 16:12:11 +02:00
468da7c285 Merge pull request #64 from s4u/fix-62
Oracle Maven repository
2020-10-16 15:59:42 +02:00
c36b106668 Oracle Maven repository
fix: #62
2020-10-16 15:03:09 +02:00
ea8b3d6660 Merge pull request #63 from s4u/dependabot/npm_and_yarn/xpath-0.0.30
Bump xpath from 0.0.29 to 0.0.30
2020-10-15 18:45:30 +02:00
65892feef6 Bump xpath from 0.0.29 to 0.0.30
Bumps [xpath](https://github.com/goto100/xpath) from 0.0.29 to 0.0.30.
- [Release notes](https://github.com/goto100/xpath/releases)
- [Commits](https://github.com/goto100/xpath/commits)

Signed-off-by: dependabot[bot] <support@github.com>
2020-10-15 09:01:01 +00:00
10548f9512 Merge pull request #61 from s4u/dependabot/npm_and_yarn/jest-26.5.3
Bump jest from 26.5.2 to 26.5.3
2020-10-13 18:39:42 +02:00
f5daf9accb Bump jest from 26.5.2 to 26.5.3
Bumps [jest](https://github.com/facebook/jest) from 26.5.2 to 26.5.3.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v26.5.2...v26.5.3)

Signed-off-by: dependabot[bot] <support@github.com>
2020-10-13 15:10:19 +00:00
7e525dcd8d Merge pull request #60 from s4u/dependabot/npm_and_yarn/eslint-7.11.0
Bump eslint from 7.10.0 to 7.11.0
2020-10-13 17:09:05 +02:00
4f7bcf53f4 Bump eslint from 7.10.0 to 7.11.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.10.0 to 7.11.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.10.0...v7.11.0)

Signed-off-by: dependabot[bot] <support@github.com>
2020-10-12 09:01:02 +00:00
8a445a2687 Merge pull request #59 from s4u/dependabot/npm_and_yarn/jest-26.5.2
Bump jest from 26.4.2 to 26.5.2
2020-10-07 20:27:14 +02:00
d9a39767e3 Bump jest from 26.4.2 to 26.5.2
Bumps [jest](https://github.com/facebook/jest) from 26.4.2 to 26.5.2.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v26.4.2...v26.5.2)

Signed-off-by: dependabot[bot] <support@github.com>
2020-10-07 09:01:13 +00:00
a3e52fbc15 Merge pull request #57 from s4u/dependabot/github_actions/actions/setup-node-v2.1.2
Bump actions/setup-node from v2.1.1 to v2.1.2
2020-10-04 15:00:17 +02:00
d10b249608 Bump actions/setup-node from v2.1.1 to v2.1.2
Bumps [actions/setup-node](https://github.com/actions/setup-node) from v2.1.1 to v2.1.2.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](https://github.com/actions/setup-node/compare/v2.1.1...c6fd00ceb9747fb23ffdf72987450a2664414867)

Signed-off-by: dependabot[bot] <support@github.com>
2020-10-04 12:53:14 +00:00
e357eee8b6 Merge pull request #56 from s4u/dependabot/npm_and_yarn/eslint-7.10.0
Bump eslint from 7.8.1 to 7.10.0
2020-10-04 14:52:32 +02:00
2a3de130be Bump eslint from 7.8.1 to 7.10.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.8.1 to 7.10.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.8.1...v7.10.0)

Signed-off-by: dependabot[bot] <support@github.com>
2020-09-29 16:52:40 +00:00
ac18e25d5d Merge pull request #55 from s4u/dependabot/npm_and_yarn/actions/core-1.2.6
Bump @actions/core from 1.2.5 to 1.2.6
2020-09-29 18:51:09 +02:00
6d2d96dbc0 Bump @actions/core from 1.2.5 to 1.2.6
Bumps [@actions/core](https://github.com/actions/toolkit/tree/HEAD/packages/core) from 1.2.5 to 1.2.6.
- [Release notes](https://github.com/actions/toolkit/releases)
- [Changelog](https://github.com/actions/toolkit/blob/main/packages/core/RELEASES.md)
- [Commits](https://github.com/actions/toolkit/commits/HEAD/packages/core)

Signed-off-by: dependabot[bot] <support@github.com>
2020-09-29 15:51:48 +00:00
7f8ec2fd15 Merge pull request #54 from s4u/dependabot/github_actions/actions/checkout-v2.3.3
Bump actions/checkout from v2.3.2 to v2.3.3
2020-09-29 17:50:41 +02:00
abac0c76e7 Bump actions/checkout from v2.3.2 to v2.3.3
Bumps [actions/checkout](https://github.com/actions/checkout) from v2.3.2 to v2.3.3.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v2.3.2...a81bbbf8298c0fa03ea29cdc473d45769f953675)

Signed-off-by: dependabot[bot] <support@github.com>
2020-09-24 09:00:25 +00:00
3c08118ca6 update dependency after merge from master 2020-09-05 13:15:58 +02:00
c61c04a8ed Merge remote-tracking branch 'origin/master' into releases/v2 2020-09-05 13:07:15 +02:00
4eefa8130f New release prepare 2020-09-05 13:00:10 +02:00
af860eb623 Merge pull request #52 from s4u/dependabot/npm_and_yarn/eslint-7.8.1
Bump eslint from 7.8.0 to 7.8.1
2020-09-05 12:21:31 +02:00
8224e70aa0 Bump eslint from 7.8.0 to 7.8.1
Bumps [eslint](https://github.com/eslint/eslint) from 7.8.0 to 7.8.1.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.8.0...v7.8.1)

Signed-off-by: dependabot[bot] <support@github.com>
2020-09-02 09:00:53 +00:00
b6dea48d5e Merge pull request #51 from s4u/dependabot/npm_and_yarn/eslint-7.8.0
Bump eslint from 7.7.0 to 7.8.0
2020-09-01 20:10:02 +02:00
81a559fbbc Bump eslint from 7.7.0 to 7.8.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.7.0 to 7.8.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.7.0...v7.8.0)

Signed-off-by: dependabot[bot] <support@github.com>
2020-09-01 18:06:52 +00:00
6f1342e18b Merge pull request #50 from s4u/dependabot/npm_and_yarn/actions/core-1.2.5
Bump @actions/core from 1.2.4 to 1.2.5
2020-09-01 20:05:47 +02:00
c6417d63a2 Bump @actions/core from 1.2.4 to 1.2.5
Bumps [@actions/core](https://github.com/actions/toolkit/tree/HEAD/packages/core) from 1.2.4 to 1.2.5.
- [Release notes](https://github.com/actions/toolkit/releases)
- [Changelog](https://github.com/actions/toolkit/blob/main/packages/core/RELEASES.md)
- [Commits](https://github.com/actions/toolkit/commits/HEAD/packages/core)

Signed-off-by: dependabot[bot] <support@github.com>
2020-08-27 09:00:56 +00:00
fcf49419d1 Merge pull request #49 from s4u/dependabot/npm_and_yarn/jest-26.4.2
Bump jest from 26.4.1 to 26.4.2
2020-08-24 18:06:49 +02:00
cf94a9ebeb Bump jest from 26.4.1 to 26.4.2
Bumps [jest](https://github.com/facebook/jest) from 26.4.1 to 26.4.2.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v26.4.1...v26.4.2)

Signed-off-by: dependabot[bot] <support@github.com>
2020-08-24 16:03:47 +00:00
93bd53060c Merge pull request #48 from s4u/dependabot/npm_and_yarn/xpath-0.0.29
Bump xpath from 0.0.27 to 0.0.29
2020-08-24 18:02:35 +02:00
c62d578537 Bump xpath from 0.0.27 to 0.0.29
Bumps [xpath](https://github.com/goto100/xpath) from 0.0.27 to 0.0.29.
- [Release notes](https://github.com/goto100/xpath/releases)
- [Commits](https://github.com/goto100/xpath/commits)

Signed-off-by: dependabot[bot] <support@github.com>
2020-08-24 09:00:47 +00:00
79dd6f6b44 Merge pull request #47 from s4u/dependabot/npm_and_yarn/jest-26.4.1
Bump jest from 26.4.0 to 26.4.1
2020-08-24 09:25:20 +02:00
633099f72a Bump jest from 26.4.0 to 26.4.1
Bumps [jest](https://github.com/facebook/jest) from 26.4.0 to 26.4.1.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v26.4.0...v26.4.1)

Signed-off-by: dependabot[bot] <support@github.com>
2020-08-20 09:00:56 +00:00
9422b33d6f Merge pull request #46 from s4u/dependabot/npm_and_yarn/eslint-7.7.0
Bump eslint from 7.5.0 to 7.7.0
2020-08-18 17:20:20 +02:00
4f51703755 Bump eslint from 7.5.0 to 7.7.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.5.0 to 7.7.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.5.0...v7.7.0)

Signed-off-by: dependabot[bot] <support@github.com>
2020-08-18 12:15:23 +00:00
d2be263333 Merge pull request #45 from s4u/dependabot/npm_and_yarn/jest-26.4.0
Bump jest from 26.2.1 to 26.4.0
2020-08-18 14:11:55 +02:00
b7c480a93e Bump jest from 26.2.1 to 26.4.0
Bumps [jest](https://github.com/facebook/jest) from 26.2.1 to 26.4.0.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v26.2.1...v26.4.0)

Signed-off-by: dependabot[bot] <support@github.com>
2020-08-18 09:42:02 +00:00
47076d1d48 Merge pull request #43 from s4u/dependabot/github_actions/actions/checkout-v2.3.2
Bump actions/checkout from v2.3.1 to v2.3.2
2020-08-18 11:39:18 +02:00
a7f883dd5f Bump actions/checkout from v2.3.1 to v2.3.2
Bumps [actions/checkout](https://github.com/actions/checkout) from v2.3.1 to v2.3.2.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v2.3.1...2036a08e25fa78bbd946711a407b529a0a1204bf)

Signed-off-by: dependabot[bot] <support@github.com>
2020-08-10 09:00:23 +00:00
783d40b5e0 Merge pull request #40 from s4u/dependabot/npm_and_yarn/jest-26.2.1
Bump jest from 26.1.0 to 26.2.1
2020-08-01 10:44:00 +02:00
6fb79721ff Bump jest from 26.1.0 to 26.2.1
Bumps [jest](https://github.com/facebook/jest) from 26.1.0 to 26.2.1.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v26.1.0...v26.2.1)

Signed-off-by: dependabot[bot] <support@github.com>
2020-07-31 09:02:38 +00:00
d2ab3a2771 Merge pull request #38 from s4u/dependabot/github_actions/actions/setup-node-v2.1.1
Bump actions/setup-node from v2.1.0 to v2.1.1
2020-07-25 21:41:47 +02:00
48be4c0ada Bump actions/setup-node from v2.1.0 to v2.1.1
Bumps [actions/setup-node](https://github.com/actions/setup-node) from v2.1.0 to v2.1.1.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](https://github.com/actions/setup-node/compare/v2.1.0...321b6ccb03083caa2ad22b27dc4b45335212e824)

Signed-off-by: dependabot[bot] <support@github.com>
2020-07-25 19:18:14 +00:00
94cb3ed880 Merge pull request #37 from s4u/dependabot/npm_and_yarn/eslint-7.5.0
Bump eslint from 7.3.1 to 7.5.0
2020-07-25 21:17:34 +02:00
055a005883 Bump eslint from 7.3.1 to 7.5.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.3.1 to 7.5.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.3.1...v7.5.0)

Signed-off-by: dependabot[bot] <support@github.com>
2020-07-22 16:33:46 +00:00
b09e5585eb Merge pull request #36 from s4u/dependabot/npm_and_yarn/lodash-4.17.19
Bump lodash from 4.17.15 to 4.17.19
2020-07-22 18:31:44 +02:00
256fa3ecf6 Bump lodash from 4.17.15 to 4.17.19
Bumps [lodash](https://github.com/lodash/lodash) from 4.17.15 to 4.17.19.
- [Release notes](https://github.com/lodash/lodash/releases)
- [Commits](https://github.com/lodash/lodash/compare/4.17.15...4.17.19)

Signed-off-by: dependabot[bot] <support@github.com>
2020-07-18 10:21:52 +00:00
2f4effcbc0 Merge pull request #33 from s4u/dependabot/github_actions/actions/setup-node-v2.1.0
Bump actions/setup-node from v2.0.0 to v2.1.0
2020-07-02 08:54:40 +02:00
32c0b34c7b Bump actions/setup-node from v2.0.0 to v2.1.0
Bumps [actions/setup-node](https://github.com/actions/setup-node) from v2.0.0 to v2.1.0.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](https://github.com/actions/setup-node/compare/v2.0.0...1ae8f4b1fd89676f69b55d3dd6932b6df089ff7b)

Signed-off-by: dependabot[bot] <support@github.com>
2020-06-30 09:01:08 +00:00
af0727c4dd Merge pull request #32 from s4u/dependabot/npm_and_yarn/jest-26.1.0
Bump jest from 26.0.1 to 26.1.0
2020-06-24 18:02:59 +02:00
a3c79af90d Bump jest from 26.0.1 to 26.1.0
Bumps [jest](https://github.com/facebook/jest) from 26.0.1 to 26.1.0.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v26.0.1...v26.1.0)

Signed-off-by: dependabot[bot] <support@github.com>
2020-06-24 09:02:00 +00:00
f06d610f38 Merge pull request #31 from s4u/dependabot/npm_and_yarn/eslint-7.3.1
Bump eslint from 7.2.0 to 7.3.1
2020-06-23 17:58:34 +02:00
0b82524ef7 Bump eslint from 7.2.0 to 7.3.1
Bumps [eslint](https://github.com/eslint/eslint) from 7.2.0 to 7.3.1.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.2.0...v7.3.1)

Signed-off-by: dependabot[bot] <support@github.com>
2020-06-23 09:01:48 +00:00
235574376d Merge pull request #29 from s4u/dependabot/github_actions/actions/checkout-v2.3.1
Bump actions/checkout from v2.3.0 to v2.3.1
2020-06-19 18:24:16 +02:00
2cd2aae853 Bump actions/checkout from v2.3.0 to v2.3.1
Bumps [actions/checkout](https://github.com/actions/checkout) from v2.3.0 to v2.3.1.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/master/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v2.3.0...28c7f3d2b5162b5ddd3dfd9a45aa55eaf396478b)

Signed-off-by: dependabot[bot] <support@github.com>
2020-06-19 09:00:44 +00:00
6438bb1dc9 Merge pull request #28 from s4u/dependabot/github_actions/actions/checkout-v2.3.0
Bump actions/checkout from v2.2.0 to v2.3.0
2020-06-17 16:26:24 +02:00
2bd1df6691 Bump actions/checkout from v2.2.0 to v2.3.0
Bumps [actions/checkout](https://github.com/actions/checkout) from v2.2.0 to v2.3.0.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/master/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v2.2.0...b4483adec309c0d01a5435c5e24eb40de5773ad9)

Signed-off-by: dependabot[bot] <support@github.com>
2020-06-17 14:20:45 +00:00
d5041555ff Merge pull request #27 from s4u/dependabot/npm_and_yarn/eslint-7.2.0
Bump eslint from 7.1.0 to 7.2.0
2020-06-17 16:20:05 +02:00
44e440d5a2 Bump eslint from 7.1.0 to 7.2.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.1.0 to 7.2.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.1.0...v7.2.0)

Signed-off-by: dependabot[bot] <support@github.com>
2020-06-08 09:00:53 +00:00
d8160953aa Merge pull request #25 from s4u/dependabot/github_actions/actions/setup-node-v2.0.0
Bump actions/setup-node from v1 to v2.0.0
2020-06-01 22:04:19 +02:00
f313f0ba42 Bump actions/setup-node from v1 to v2.0.0
Bumps [actions/setup-node](https://github.com/actions/setup-node) from v1 to v2.0.0.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](https://github.com/actions/setup-node/compare/v1...e434342e4e324065b1b19b24586c710a1a68d2d7)

Signed-off-by: dependabot[bot] <support@github.com>
2020-06-01 19:57:41 +00:00
8d8ad4fc4e add name to GA jobs 2020-06-01 21:52:58 +02:00
91a3862919 Merge pull request #26 from s4u/dependabot/github_actions/actions/checkout-v2.2.0
Bump actions/checkout from v1 to v2.2.0
2020-06-01 21:40:34 +02:00
5070591660 Bump actions/checkout from v1 to v2.2.0
Bumps [actions/checkout](https://github.com/actions/checkout) from v1 to v2.2.0.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/master/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v1...aabbfeb2ce60b5bd82389903509092c4648a9713)

Signed-off-by: dependabot[bot] <support@github.com>
2020-06-01 19:36:57 +00:00
c61209d1cb Merge pull request #24 from s4u/dependabot/add-v2-config-file
Create Dependabot config file
2020-06-01 21:36:34 +02:00
0e30ec546c Create Dependabot config file 2020-06-01 19:34:43 +00:00
09d6dddb17 Merge pull request #23 from s4u/dependabot/npm_and_yarn/eslint-7.1.0 2020-05-25 21:08:17 +00:00
844e084ed1 Bump eslint from 6.8.0 to 7.1.0
Bumps [eslint](https://github.com/eslint/eslint) from 6.8.0 to 7.1.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/master/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v6.8.0...v7.1.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-05-25 20:59:53 +00:00
3fd7e6914e fix branch ignore pattern 2020-05-25 22:55:10 +02:00
082d702c3a Merge pull request #21 from s4u/dependabot/npm_and_yarn/jest-26.0.1 2020-05-25 20:46:49 +00:00
7d928cbb6b Bump jest from 26.0.0 to 26.0.1
Bumps [jest](https://github.com/facebook/jest) from 26.0.0 to 26.0.1.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v26.0.0...v26.0.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-05-06 09:14:33 +00:00
89e2aa37f3 Merge pull request #20 from s4u/dependabot/npm_and_yarn/jest-26.0.0 2020-05-05 16:46:53 +00:00
be701aaad8 Bump jest from 25.5.3 to 26.0.0
Bumps [jest](https://github.com/facebook/jest) from 25.5.3 to 26.0.0.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v25.5.3...v26.0.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-05-05 09:14:27 +00:00
c18afafd7e Merge pull request #17 from s4u/dependabot/npm_and_yarn/jest-25.5.3 2020-05-01 15:50:16 +00:00
f94dfbd262 Bump jest from 25.4.0 to 25.5.3
Bumps [jest](https://github.com/facebook/jest) from 25.4.0 to 25.5.3.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v25.4.0...v25.5.3)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-05-01 15:48:19 +00:00
534b1b1076 Merge pull request #18 from s4u/dependabot/npm_and_yarn/actions/core-1.2.4 2020-05-01 15:46:33 +00:00
1dd5e0f3e7 Bump @actions/core from 1.2.3 to 1.2.4
Bumps [@actions/core](https://github.com/actions/toolkit/tree/HEAD/packages/core) from 1.2.3 to 1.2.4.
- [Release notes](https://github.com/actions/toolkit/releases)
- [Changelog](https://github.com/actions/toolkit/blob/master/packages/core/RELEASES.md)
- [Commits](https://github.com/actions/toolkit/commits/HEAD/packages/core)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-05-01 09:20:06 +00:00
5f6f6f6779 Merge pull request #14 from s4u/dependabot/npm_and_yarn/jest-25.4.0 2020-04-21 19:32:06 +00:00
2350e84f5b Bump jest from 25.3.0 to 25.4.0
Bumps [jest](https://github.com/facebook/jest) from 25.3.0 to 25.4.0.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v25.3.0...v25.4.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-04-20 10:26:37 +00:00
0e8d6036b1 Merge pull request #13 from s4u/dependabot/npm_and_yarn/jest-25.3.0 2020-04-09 18:41:20 +00:00
71b35fd976 Bump jest from 25.2.7 to 25.3.0
Bumps [jest](https://github.com/facebook/jest) from 25.2.7 to 25.3.0.
- [Release notes](https://github.com/facebook/jest/releases)
- [Changelog](https://github.com/facebook/jest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/facebook/jest/compare/v25.2.7...v25.3.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-04-09 09:15:00 +00:00
fcc46e4a85 update version in readme after release 2020-04-06 22:58:47 +02:00
41ac50e735 update version in readme after release 2020-04-06 22:58:18 +02:00
91 changed files with 11153 additions and 11634 deletions

3
.gitattributes vendored Normal file
View File

@ -0,0 +1,3 @@
*.js eol=lf
*.yml eol=lf
*.xml eol=lf

14
.github/dependabot.yml vendored Normal file
View File

@ -0,0 +1,14 @@
version: 2
updates:
- package-ecosystem: npm
directory: "/"
schedule:
interval: daily
time: '09:09'
open-pull-requests-limit: 10
- package-ecosystem: github-actions
directory: "/"
schedule:
interval: daily
time: '09:09'
open-pull-requests-limit: 10

View File

@ -1,14 +1,15 @@
name: "Audit"
name: Audit
on:
pull_request:
push:
branches-ignore:
- 'dependabot/*'
- 'dependabot/**'
schedule:
- cron: '09 22 * * *'
jobs:
test:
audit:
name: Audit
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macOS-latest]
@ -16,9 +17,9 @@ jobs:
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v1
- uses: actions/checkout@v3
- uses: actions/setup-node@v1
- uses: actions/setup-node@v3
with:
node-version: '12.x'

10
.github/workflows/auto-approve.yml vendored Normal file
View File

@ -0,0 +1,10 @@
name: Auto Approve
on:
pull_request_target
jobs:
auto-approve:
uses: s4u/.github/.github/workflows/auto-approve.yml@master
secrets:
TECH_TOKEN: ${{ secrets.TECH_TOKEN }}

22
.github/workflows/release-drafter.yml vendored Normal file
View File

@ -0,0 +1,22 @@
name: Release Drafter
on:
push:
branches:
- 'master'
- 'main'
jobs:
update_release_draft:
name: Update Release Draft
runs-on: ubuntu-latest
concurrency: release-drafter
if: >
github.repository_owner == 's4u'
&& !startsWith(github.event.head_commit.message , '[maven-release-plugin]')
steps:
- uses: release-drafter/release-drafter@v5.19.0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

View File

@ -1,14 +1,15 @@
name: "Test"
name: Test
on:
pull_request:
push:
branches-ignore:
- 'dependabot/*'
- 'dependabot/**'
schedule:
- cron: '22 22 * * 5'
jobs:
test:
name: Test
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macOS-latest]
@ -16,15 +17,17 @@ jobs:
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v1
- uses: actions/checkout@v3
- uses: actions/setup-node@v1
- uses: actions/setup-node@v3
with:
node-version: '12.x'
- uses: actions/setup-java@v1
- uses: actions/setup-java@v3
with:
java-version: '1.8'
distribution: 'adopt'
java-version: '8'
- run: npm version
- run: npm ci
@ -35,7 +38,10 @@ jobs:
servers: '[{"id": "serverId", "username": "username", "password": "password"}]'
properties: '[{"prop1": "value1"}, {"prop2": "value2"}]'
mirrors: '[{"id": "mirrorId", "name": "mirrorName", "mirrorOf": "mirrorOf", "url": "mirrorUrl"}]'
apacheSnapshots: true
sonatypeSnapshots: true
oracleServers: '[{"id": "oServerId", "username": "oUsername", "password": "oPassword"}]'
oracleRepo: true
- run: cat ~/.m2/settings.xml
shell: bash

160
README.md
View File

@ -3,7 +3,7 @@
[![Audit](https://github.com/s4u/maven-settings-action/workflows/Audit/badge.svg)](https://github.com/s4u/maven-settings-action/actions?query=workflow%3AAudit)
This action setup maven environment for use in action by:
This action sets up Maven environments for use in GitHub Actions by:
- create maven settings.xml
- set ```interactiveMode``` to false - useful in CI system
- after job finish generated settings.xml will be removed to prevent cache or left sensitive data on build system
@ -12,73 +12,195 @@ This action setup maven environment for use in action by:
# Contributions
- Contributions are welcome!
- Give :star: - if you want to encourage me to work on a project
- Don't hesitate create issue for new feature you dream of or if you suspect some bug
- Don't hesitate to create issues for new features you dream of or if you suspect some bug
# Project versioning
Project use [Semantic Versioning](https://semver.org/).
This project uses [Semantic Versioning](https://semver.org/).
We recommended to use the latest and specific release version.
In order to keep your project dependencies up to date you can watch this repository *(Releases only)*
or use automatic tools like [Dependabot](https://dependabot.com/).
or use automatic tools like [Dependabot](https://docs.github.com/en/code-security/supply-chain-security/keeping-your-dependencies-updated-automatically/about-dependabot-version-updates).
# Usage
You can try our action [Setup Maven Action](https://github.com/marketplace/actions/setup-maven-action) for completely maven environment setup.
See [action.yml](action.yml)
Create default ```settings.xml```:
## default ```settings.xml```
```yml
steps:
- uses: s4u/maven-settings-action@v2
- uses: s4u/maven-settings-action@v2.6.0
```
Create ```settings.xml``` with servers section:
## ```settings.xml``` with servers section
```yml
steps:
- uses: s4u/maven-settings-action@v2
- uses: s4u/maven-settings-action@v2.6.0
with:
servers: '[{"id": "serverId", "username": "username", "password": "password"}]'
```
Create ```settings.xml``` with mirrors section:
Also you can use `path` argument if your settings.xml is stored in different location.
All `server` attributes may be specified:
* `id` _(required)_
* `username`
* `password`
* `privateKey`
* `passphrase`
* `filePermissions`
* `directoryPermissions`
* `configuration`
Please refer to the [servers](http://maven.apache.org/settings.html#Servers) documentation for more information.
## ```settings.xml``` with servers section and additional configuration
``` yml
steps:
- uses: s4u/maven-settings-action@v2.6.0
with:
servers: |
[{
"id": "serverId",
"configuration": {
"item1": "value1",
"item2": {
"item21": "value21",
"item22": "value22"
}
}
}]
```
result will be:
```xml
<server>
<id>serverId</id>
<configuration>
<item1>value1</item1>
<item2>
<item21>value21</item21>
<item22>value22</item22>
</item1>
</configuration>
</server></servers>
```
## ```settings.xml``` with mirrors section
```yml
steps:
- uses: s4u/maven-settings-action@v2
- uses: s4u/maven-settings-action@v2.6.0
with:
mirrors: '[{"id": "mirrorId", "name": "mirrorName", "mirrorOf": "mirrorOf", "url": "mirrorUrl"}]'
```
Create ```settings.xml``` with maven properties:
## ```settings.xml``` with properties
```yml
steps:
- uses: s4u/maven-settings-action@v2
- uses: s4u/maven-settings-action@v2.6.0
with:
properties: '[{"propertyName1": "propertyValue1"}, {"propertyName2": "propertyValue2"}]'
```
Create ```settings.xml``` with https://oss.sonatype.org/content/repositories/snapshots in repository list
## ```settings.xml``` with https://oss.sonatype.org/content/repositories/snapshots in repository list
```yml
steps:
- uses: s4u/maven-settings-action@v2
- uses: s4u/maven-settings-action@v2.6.0
with:
sonatypeSnapshots: true
```
Do not override existing ```settings.xml```, from version 2.0 file is override by default :
## ```settings.xml``` with https://repository.apache.org/snapshots/ in repository list
```yml
steps:
- uses: s4u/maven-settings-action@v2
- uses: s4u/maven-settings-action@v2.6.0
with:
apacheSnapshots: true
```
## Do not override existing ```settings.xml```, from version **2.0** file is override by default :
```yml
steps:
- uses: s4u/maven-settings-action@v2.6.0
with:
override: false
```
Do not add github to server in ```settings.xml```, by default is added:
## Do not add github to server in ```settings.xml```, by default is added:
```yml
steps:
- uses: s4u/maven-settings-action@v2
- uses: s4u/maven-settings-action@v2.6.0
with:
githubServer: false
```
## ```settings.xml``` with special server item configuration for oracle repository [Oracle Maven Repository](https://docs.oracle.com/middleware/1213/core/MAVEN/config_maven_repo.htm#MAVEN9015)
```yml
steps:
- uses: s4u/maven-settings-action@v2.6.0
with:
oracleServers: '[{"id": "serverId", "username": "username", "password": "password"}]'
```
## ```settings.xml``` with [Oracle Maven Repository](https://docs.oracle.com/middleware/1213/core/MAVEN/config_maven_repo.htm#MAVEN9017)
```yml
steps:
- uses: s4u/maven-settings-action@v2.6.0
with:
oracleRepo: true
```
## GitHub actions secrets
It is also possible pass in Github Secrets e.g.
``` yml
steps:
- uses: s4u/maven-settings-action@v2.6.0
with:
servers: |
[{
"id": "sonatype-nexus-snapshots",
"username": "${{ secrets.SONATYPE_USERNAME }}",
"password": "${{ secrets.SONATYPE_PASSWORD }}"
}]
```
**Note**: secrets are *not* passed in if the workflow is triggered from a forked repository. See [here](https://docs.github.com/en/free-pro-team@latest/actions/reference/encrypted-secrets#using-encrypted-secrets-in-a-workflow) for further information. This can be avoided by using `if` triggers on the job e.g. `if: github.event_name == 'push'`.
# Notes
**maven-settings-action** should be put at the latest position before maven run in order to avoid override ```setting.xml``` by another action
```yml
steps:
- uses: actions/checkout@v2
- uses: actions/cache@v2
with:
path: ~/.m2/repository
key: maven-${{ hashFiles('**/pom.xml') }}
restore-keys: maven-
- uses: actions/setup-java@v1
with:
java-version: 8
- uses: s4u/maven-settings-action@v2.6.0
- run: mvn verify
```
# License
The scripts and documentation in this project are released under the [MIT License](LICENSE)
The scripts and documentation in this project are released under the [MIT License](LICENSE).

View File

@ -1,4 +1,4 @@
name: 'maven-setings-action'
name: 'maven-settings-action'
description: 'Prepare maven settings.xml'
branding:
@ -6,8 +6,11 @@ branding:
color: 'green'
inputs:
path:
description: 'override default path to settings.xml which is $HOME/.m2/settings.xml'
required: false
servers:
description: 'servers definition in joson array, eg: [{"id": "serverId", "username": "username", "password": "password"}]'
description: 'servers definition in json array, eg: [{"id": "serverId", "username": "username", "password": "password"}]'
required: false
mirrors:
description: 'mirrors definition in json array, eg: [{"id": "id", "name": "name", "mirrorOf": "mirrorOf", "url": "url"}]'
@ -19,6 +22,10 @@ inputs:
description: 'add https://oss.sonatype.org/content/repositories/snapshots to repository list - true or false'
default: "false"
required: false
apacheSnapshots:
description: 'add https://repository.apache.org/snapshots to repository list - true or false'
default: "false"
required: false
override:
description: 'override existing settings.xml file'
default: "true"
@ -27,8 +34,13 @@ inputs:
description: 'add to settings.xml servers server-id: github; username=$GITHUB_ACTOR and password=$GITHUB_TOKEN'
default: "true"
required: false
oracleServers:
description: 'servers definition in json array, eg: [{"id": "serverId", "username": "username", "password": "password"}] for Oracle repository'
required: false
oracleRepo:
description: 'add Oracle Maven Repository'
default: "false"
required: false
runs:
using: 'node12'

View File

@ -63,18 +63,184 @@ afterAll(() => {
test('run with all feature', () => {
process.env['INPUT_SERVERS'] = '[{"id": "serverId", "username": "username", "password": "password"}]';
process.env['INPUT_PROPERTIES'] = '[{"prop1": "value1"}, {"prop2": "value2"}]'
process.env['INPUT_SONATYPESNAPSHOT'] = true;
process.env['INPUT_SERVERS'] = '[{"id": "serverId", "username": "sUsername", "password": "sPassword", "configuration": {"props1": "value1"}}]';
process.env['INPUT_ORACLESERVERS'] = '[{"id": "oServerId", "username": "oUsername", "password": "oPassword"}]';
process.env['INPUT_GITHUBSERVER'] = true;
cp.execSync(`node ${indexPath}`, { env: process.env }).toString();
process.env['INPUT_MIRRORS'] = '[{"id": "mirrorId", "name": "mirror Name", "mirrorOf": "mirror Off *", "url": "mirror url"}]';
process.env['INPUT_PROPERTIES'] = '[{"prop1": "value1"}, {"prop2": "value2"}]'
process.env['INPUT_APACHESNAPSHOTS'] = true;
process.env['INPUT_SONATYPESNAPSHOTS'] = true;
process.env['INPUT_ORACLEREPO'] = true;
cp.execSync(`node ${indexPath}`, { env: process.env, stdio: 'inherit' });
const settingsStatus = fs.lstatSync(settingsPath);
expect(settingsStatus.isFile()).toBeTruthy();
expect(settingsStatus.size).toBeGreaterThan(0);
const settingsBody = fs.readFileSync(settingsPath).toString();
expect(settingsBody).toMatch('<settings>');
expect(settingsBody).toMatch('<servers><server><id>serverId</id><username>username</username><password>password</password></server></servers>');
expect(settingsBody).toMatch('prop1');
const settingsBody = fs.readFileSync(settingsPath).toString().replace(/^\s*$(?:\r\n?|\n)/gm, '');
expect(settingsBody).toBe(`<settings>
<interactiveMode>false</interactiveMode>
<profiles>
<profile>
<id>_properties_</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<properties><prop1>value1</prop1><prop2>value2</prop2></properties>
</profile>
<profile>
<id>_apache-snapshots_</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<repositories>
<repository>
<id>apache.snapshots.https</id>
<url>https://repository.apache.org/snapshots/</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>apache.snapshots.https</id>
<url>https://repository.apache.org/snapshots/</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</pluginRepository>
</pluginRepositories>
</profile>
<profile>
<id>_sonatype-snapshots_</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<repositories>
<repository>
<id>sonatype-snapshots</id>
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
<repository>
<id>ossrh</id>
<url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>sonatype-snapshots</id>
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</pluginRepository>
<pluginRepository>
<id>ossrh</id>
<url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</pluginRepository>
</pluginRepositories>
</profile>
<profile>
<id>_maven.oracle.com_</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<repositories>
<repository>
<id>maven.oracle.com</id>
<url>https://maven.oracle.com</url>
<releases>
<enabled>true</enabled>
</releases>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>maven.oracle.com</id>
<url>https://maven.oracle.com</url>
<releases>
<enabled>true</enabled>
</releases>
<snapshots>
<enabled>false</enabled>
</snapshots>
</pluginRepository>
</pluginRepositories>
</profile></profiles>
<servers>
<server>
<id>serverId</id>
<username>sUsername</username>
<password>sPassword</password>
<configuration><props1>value1</props1></configuration>
</server>
<server>
<id>oServerId</id>
<username>oUsername</username>
<password>oPassword</password>
<configuration>
<basicAuthScope>
<host>ANY</host>
<port>ANY</port>
<realm>OAM 11g</realm>
</basicAuthScope>
<httpConfiguration>
<all>
<params>
<property>
<name>http.protocol.allow-circular-redirects</name>
<value>%b,true</value>
</property>
</params>
</all>
</httpConfiguration>
</configuration>
</server>
<server>
<id>github</id>
<username>\${env.GITHUB_ACTOR}</username>
<password>\${env.GITHUB_TOKEN}</password>
</server></servers>
<mirrors>
<mirror>
<id>mirrorId</id>
<name>mirror Name</name>
<mirrorOf>mirror Off *</mirrorOf>
<url>mirror url</url>
</mirror></mirrors>
</settings>`);
})

40
node_modules/.package-lock.json generated vendored Normal file
View File

@ -0,0 +1,40 @@
{
"name": "maven-settings-action",
"version": "2.6.0",
"lockfileVersion": 2,
"requires": true,
"packages": {
"node_modules/@actions/core": {
"version": "1.6.0",
"resolved": "https://registry.npmjs.org/@actions/core/-/core-1.6.0.tgz",
"integrity": "sha512-NB1UAZomZlCV/LmJqkLhNTqtKfFXJZAUPcfl/zqG7EfsQdeUJtaWO98SGbuQ3pydJ3fHl2CvI/51OKYlCYYcaw==",
"dependencies": {
"@actions/http-client": "^1.0.11"
}
},
"node_modules/@actions/http-client": {
"version": "1.0.11",
"resolved": "https://registry.npmjs.org/@actions/http-client/-/http-client-1.0.11.tgz",
"integrity": "sha512-VRYHGQV1rqnROJqdMvGUbY/Kn8vriQe/F9HR2AlYHzmKuM/p3kjNuXhmdBfcVgsvRWTz5C5XW5xvndZrVBuAYg==",
"dependencies": {
"tunnel": "0.0.6"
}
},
"node_modules/@xmldom/xmldom": {
"version": "0.8.1",
"resolved": "https://registry.npmjs.org/@xmldom/xmldom/-/xmldom-0.8.1.tgz",
"integrity": "sha512-4wOae+5N2RZ+CZXd9ZKwkaDi55IxrSTOjHpxTvQQ4fomtOJmqVxbmICA9jE1jvnqNhpfgz8cnfFagG86wV/xLQ==",
"engines": {
"node": ">=10.0.0"
}
},
"node_modules/tunnel": {
"version": "0.0.6",
"resolved": "https://registry.npmjs.org/tunnel/-/tunnel-0.0.6.tgz",
"integrity": "sha512-1h/Lnq9yajKY2PEbBadPXj3VxsDDu844OnaAo52UVmIzIvwwtBPIuNvkjuzBlTWpfJyUbG3ez0KSBibQkj4ojg==",
"engines": {
"node": ">=0.6.11 <=0.7.0 || >=0.7.3"
}
}
}
}

9
node_modules/@actions/core/LICENSE.md generated vendored Normal file
View File

@ -0,0 +1,9 @@
The MIT License (MIT)
Copyright 2019 GitHub
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

178
node_modules/@actions/core/README.md generated vendored
View File

@ -16,11 +16,14 @@ import * as core from '@actions/core';
#### Inputs/Outputs
Action inputs can be read with `getInput`. Outputs can be set with `setOutput` which makes them available to be mapped into inputs of other actions to ensure they are decoupled.
Action inputs can be read with `getInput` which returns a `string` or `getBooleanInput` which parses a boolean based on the [yaml 1.2 specification](https://yaml.org/spec/1.2/spec.html#id2804923). If `required` set to be false, the input should have a default value in `action.yml`.
Outputs can be set with `setOutput` which makes them available to be mapped into inputs of other actions to ensure they are decoupled.
```js
const myInput = core.getInput('inputName', { required: true });
const myBooleanInput = core.getBooleanInput('booleanInputName', { required: true });
const myMultilineInput = core.getMultilineInput('multilineInputName', { required: true });
core.setOutput('outputKey', 'outputVal');
```
@ -62,11 +65,10 @@ catch (err) {
// setFailed logs the message and sets a failing exit code
core.setFailed(`Action failed with error ${err}`);
}
```
Note that `setNeutral` is not yet implemented in actions V2 but equivalent functionality is being planned.
```
#### Logging
Finally, this library provides some utilities for logging. Note that debug logging is hidden from the logs by default. This behavior can be toggled by enabling the [Step Debug Logs](../../docs/action-debugging.md#step-debug-logs).
@ -89,6 +91,9 @@ try {
}
// Do stuff
core.info('Output to the actions build log')
core.notice('This is a message that will also emit an annotation')
}
catch (err) {
core.error(`Error ${err}, action may still succeed though`);
@ -112,11 +117,123 @@ const result = await core.group('Do something async', async () => {
})
```
#### Annotations
This library has 3 methods that will produce [annotations](https://docs.github.com/en/rest/reference/checks#create-a-check-run).
```js
core.error('This is a bad error. This will also fail the build.')
core.warning('Something went wrong, but it\'s not bad enough to fail the build.')
core.notice('Something happened that you might want to know about.')
```
These will surface to the UI in the Actions page and on Pull Requests. They look something like this:
![Annotations Image](../../docs/assets/annotations.png)
These annotations can also be attached to particular lines and columns of your source files to show exactly where a problem is occuring.
These options are:
```typescript
export interface AnnotationProperties {
/**
* A title for the annotation.
*/
title?: string
/**
* The name of the file for which the annotation should be created.
*/
file?: string
/**
* The start line for the annotation.
*/
startLine?: number
/**
* The end line for the annotation. Defaults to `startLine` when `startLine` is provided.
*/
endLine?: number
/**
* The start column for the annotation. Cannot be sent when `startLine` and `endLine` are different values.
*/
startColumn?: number
/**
* The start column for the annotation. Cannot be sent when `startLine` and `endLine` are different values.
* Defaults to `startColumn` when `startColumn` is provided.
*/
endColumn?: number
}
```
#### Styling output
Colored output is supported in the Action logs via standard [ANSI escape codes](https://en.wikipedia.org/wiki/ANSI_escape_code). 3/4 bit, 8 bit and 24 bit colors are all supported.
Foreground colors:
```js
// 3/4 bit
core.info('\u001b[35mThis foreground will be magenta')
// 8 bit
core.info('\u001b[38;5;6mThis foreground will be cyan')
// 24 bit
core.info('\u001b[38;2;255;0;0mThis foreground will be bright red')
```
Background colors:
```js
// 3/4 bit
core.info('\u001b[43mThis background will be yellow');
// 8 bit
core.info('\u001b[48;5;6mThis background will be cyan')
// 24 bit
core.info('\u001b[48;2;255;0;0mThis background will be bright red')
```
Special styles:
```js
core.info('\u001b[1mBold text')
core.info('\u001b[3mItalic text')
core.info('\u001b[4mUnderlined text')
```
ANSI escape codes can be combined with one another:
```js
core.info('\u001b[31;46mRed foreground with a cyan background and \u001b[1mbold text at the end');
```
> Note: Escape codes reset at the start of each line
```js
core.info('\u001b[35mThis foreground will be magenta')
core.info('This foreground will reset to the default')
```
Manually typing escape codes can be a little difficult, but you can use third party modules such as [ansi-styles](https://github.com/chalk/ansi-styles).
```js
const style = require('ansi-styles');
core.info(style.color.ansi16m.hex('#abcdef') + 'Hello world!')
```
#### Action state
You can use this library to save state and get state for sharing information between a given wrapper action:
You can use this library to save state and get state for sharing information between a given wrapper action:
**action.yml**:
**action.yml**
```yaml
name: 'Wrapper action sample'
inputs:
@ -137,10 +254,59 @@ core.saveState("pidToKill", 12345);
```
In action's `cleanup.js`:
```js
const core = require('@actions/core');
var pid = core.getState("pidToKill");
process.kill(pid);
```
#### OIDC Token
You can use these methods to interact with the GitHub OIDC provider and get a JWT ID token which would help to get access token from third party cloud providers.
**Method Name**: getIDToken()
**Inputs**
audience : optional
**Outputs**
A [JWT](https://jwt.io/) ID Token
In action's `main.ts`:
```js
const core = require('@actions/core');
async function getIDTokenAction(): Promise<void> {
const audience = core.getInput('audience', {required: false})
const id_token1 = await core.getIDToken() // ID Token with default audience
const id_token2 = await core.getIDToken(audience) // ID token with custom audience
// this id_token can be used to get access token from third party cloud providers
}
getIDTokenAction()
```
In action's `actions.yml`:
```yaml
name: 'GetIDToken'
description: 'Get ID token from Github OIDC provider'
inputs:
audience:
description: 'Audience for which the ID token is intended for'
required: false
outputs:
id_token1:
description: 'ID token obtained from OIDC provider'
id_token2:
description: 'ID token obtained from OIDC provider'
runs:
using: 'node12'
main: 'dist/index.js'
```

View File

@ -1,5 +1,5 @@
interface CommandProperties {
[key: string]: string;
export interface CommandProperties {
[key: string]: any;
}
/**
* Commands
@ -11,6 +11,5 @@ interface CommandProperties {
* ::warning::This is the message
* ::set-env name=MY_VAR::some value
*/
export declare function issueCommand(command: string, properties: CommandProperties, message: string): void;
export declare function issueCommand(command: string, properties: CommandProperties, message: any): void;
export declare function issue(name: string, message?: string): void;
export {};

View File

@ -1,13 +1,27 @@
"use strict";
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
if (k2 === undefined) k2 = k;
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
}) : (function(o, m, k, k2) {
if (k2 === undefined) k2 = k;
o[k2] = m[k];
}));
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
Object.defineProperty(o, "default", { enumerable: true, value: v });
}) : function(o, v) {
o["default"] = v;
});
var __importStar = (this && this.__importStar) || function (mod) {
if (mod && mod.__esModule) return mod;
var result = {};
if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
result["default"] = mod;
if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
__setModuleDefault(result, mod);
return result;
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.issue = exports.issueCommand = void 0;
const os = __importStar(require("os"));
const utils_1 = require("./utils");
/**
* Commands
*
@ -62,13 +76,13 @@ class Command {
}
}
function escapeData(s) {
return (s || '')
return utils_1.toCommandValue(s)
.replace(/%/g, '%25')
.replace(/\r/g, '%0D')
.replace(/\n/g, '%0A');
}
function escapeProperty(s) {
return (s || '')
return utils_1.toCommandValue(s)
.replace(/%/g, '%25')
.replace(/\r/g, '%0D')
.replace(/\n/g, '%0A')

View File

@ -1 +1 @@
{"version":3,"file":"command.js","sourceRoot":"","sources":["../src/command.ts"],"names":[],"mappings":";;;;;;;;;AAAA,uCAAwB;AAQxB;;;;;;;;;GASG;AACH,SAAgB,YAAY,CAC1B,OAAe,EACf,UAA6B,EAC7B,OAAe;IAEf,MAAM,GAAG,GAAG,IAAI,OAAO,CAAC,OAAO,EAAE,UAAU,EAAE,OAAO,CAAC,CAAA;IACrD,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,GAAG,CAAC,QAAQ,EAAE,GAAG,EAAE,CAAC,GAAG,CAAC,CAAA;AAC/C,CAAC;AAPD,oCAOC;AAED,SAAgB,KAAK,CAAC,IAAY,EAAE,UAAkB,EAAE;IACtD,YAAY,CAAC,IAAI,EAAE,EAAE,EAAE,OAAO,CAAC,CAAA;AACjC,CAAC;AAFD,sBAEC;AAED,MAAM,UAAU,GAAG,IAAI,CAAA;AAEvB,MAAM,OAAO;IAKX,YAAY,OAAe,EAAE,UAA6B,EAAE,OAAe;QACzE,IAAI,CAAC,OAAO,EAAE;YACZ,OAAO,GAAG,iBAAiB,CAAA;SAC5B;QAED,IAAI,CAAC,OAAO,GAAG,OAAO,CAAA;QACtB,IAAI,CAAC,UAAU,GAAG,UAAU,CAAA;QAC5B,IAAI,CAAC,OAAO,GAAG,OAAO,CAAA;IACxB,CAAC;IAED,QAAQ;QACN,IAAI,MAAM,GAAG,UAAU,GAAG,IAAI,CAAC,OAAO,CAAA;QAEtC,IAAI,IAAI,CAAC,UAAU,IAAI,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,MAAM,GAAG,CAAC,EAAE;YAC9D,MAAM,IAAI,GAAG,CAAA;YACb,IAAI,KAAK,GAAG,IAAI,CAAA;YAChB,KAAK,MAAM,GAAG,IAAI,IAAI,CAAC,UAAU,EAAE;gBACjC,IAAI,IAAI,CAAC,UAAU,CAAC,cAAc,CAAC,GAAG,CAAC,EAAE;oBACvC,MAAM,GAAG,GAAG,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,CAAA;oBAChC,IAAI,GAAG,EAAE;wBACP,IAAI,KAAK,EAAE;4BACT,KAAK,GAAG,KAAK,CAAA;yBACd;6BAAM;4BACL,MAAM,IAAI,GAAG,CAAA;yBACd;wBAED,MAAM,IAAI,GAAG,GAAG,IAAI,cAAc,CAAC,GAAG,CAAC,EAAE,CAAA;qBAC1C;iBACF;aACF;SACF;QAED,MAAM,IAAI,GAAG,UAAU,GAAG,UAAU,CAAC,IAAI,CAAC,OAAO,CAAC,EAAE,CAAA;QACpD,OAAO,MAAM,CAAA;IACf,CAAC;CACF;AAED,SAAS,UAAU,CAAC,CAAS;IAC3B,OAAO,CAAC,CAAC,IAAI,EAAE,CAAC;SACb,OAAO,CAAC,IAAI,EAAE,KAAK,CAAC;SACpB,OAAO,CAAC,KAAK,EAAE,KAAK,CAAC;SACrB,OAAO,CAAC,KAAK,EAAE,KAAK,CAAC,CAAA;AAC1B,CAAC;AAED,SAAS,cAAc,CAAC,CAAS;IAC/B,OAAO,CAAC,CAAC,IAAI,EAAE,CAAC;SACb,OAAO,CAAC,IAAI,EAAE,KAAK,CAAC;SACpB,OAAO,CAAC,KAAK,EAAE,KAAK,CAAC;SACrB,OAAO,CAAC,KAAK,EAAE,KAAK,CAAC;SACrB,OAAO,CAAC,IAAI,EAAE,KAAK,CAAC;SACpB,OAAO,CAAC,IAAI,EAAE,KAAK,CAAC,CAAA;AACzB,CAAC"}
{"version":3,"file":"command.js","sourceRoot":"","sources":["../src/command.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAAA,uCAAwB;AACxB,mCAAsC;AAWtC;;;;;;;;;GASG;AACH,SAAgB,YAAY,CAC1B,OAAe,EACf,UAA6B,EAC7B,OAAY;IAEZ,MAAM,GAAG,GAAG,IAAI,OAAO,CAAC,OAAO,EAAE,UAAU,EAAE,OAAO,CAAC,CAAA;IACrD,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,GAAG,CAAC,QAAQ,EAAE,GAAG,EAAE,CAAC,GAAG,CAAC,CAAA;AAC/C,CAAC;AAPD,oCAOC;AAED,SAAgB,KAAK,CAAC,IAAY,EAAE,OAAO,GAAG,EAAE;IAC9C,YAAY,CAAC,IAAI,EAAE,EAAE,EAAE,OAAO,CAAC,CAAA;AACjC,CAAC;AAFD,sBAEC;AAED,MAAM,UAAU,GAAG,IAAI,CAAA;AAEvB,MAAM,OAAO;IAKX,YAAY,OAAe,EAAE,UAA6B,EAAE,OAAe;QACzE,IAAI,CAAC,OAAO,EAAE;YACZ,OAAO,GAAG,iBAAiB,CAAA;SAC5B;QAED,IAAI,CAAC,OAAO,GAAG,OAAO,CAAA;QACtB,IAAI,CAAC,UAAU,GAAG,UAAU,CAAA;QAC5B,IAAI,CAAC,OAAO,GAAG,OAAO,CAAA;IACxB,CAAC;IAED,QAAQ;QACN,IAAI,MAAM,GAAG,UAAU,GAAG,IAAI,CAAC,OAAO,CAAA;QAEtC,IAAI,IAAI,CAAC,UAAU,IAAI,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,MAAM,GAAG,CAAC,EAAE;YAC9D,MAAM,IAAI,GAAG,CAAA;YACb,IAAI,KAAK,GAAG,IAAI,CAAA;YAChB,KAAK,MAAM,GAAG,IAAI,IAAI,CAAC,UAAU,EAAE;gBACjC,IAAI,IAAI,CAAC,UAAU,CAAC,cAAc,CAAC,GAAG,CAAC,EAAE;oBACvC,MAAM,GAAG,GAAG,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,CAAA;oBAChC,IAAI,GAAG,EAAE;wBACP,IAAI,KAAK,EAAE;4BACT,KAAK,GAAG,KAAK,CAAA;yBACd;6BAAM;4BACL,MAAM,IAAI,GAAG,CAAA;yBACd;wBAED,MAAM,IAAI,GAAG,GAAG,IAAI,cAAc,CAAC,GAAG,CAAC,EAAE,CAAA;qBAC1C;iBACF;aACF;SACF;QAED,MAAM,IAAI,GAAG,UAAU,GAAG,UAAU,CAAC,IAAI,CAAC,OAAO,CAAC,EAAE,CAAA;QACpD,OAAO,MAAM,CAAA;IACf,CAAC;CACF;AAED,SAAS,UAAU,CAAC,CAAM;IACxB,OAAO,sBAAc,CAAC,CAAC,CAAC;SACrB,OAAO,CAAC,IAAI,EAAE,KAAK,CAAC;SACpB,OAAO,CAAC,KAAK,EAAE,KAAK,CAAC;SACrB,OAAO,CAAC,KAAK,EAAE,KAAK,CAAC,CAAA;AAC1B,CAAC;AAED,SAAS,cAAc,CAAC,CAAM;IAC5B,OAAO,sBAAc,CAAC,CAAC,CAAC;SACrB,OAAO,CAAC,IAAI,EAAE,KAAK,CAAC;SACpB,OAAO,CAAC,KAAK,EAAE,KAAK,CAAC;SACrB,OAAO,CAAC,KAAK,EAAE,KAAK,CAAC;SACrB,OAAO,CAAC,IAAI,EAAE,KAAK,CAAC;SACpB,OAAO,CAAC,IAAI,EAAE,KAAK,CAAC,CAAA;AACzB,CAAC"}

View File

@ -4,6 +4,8 @@
export interface InputOptions {
/** Optional. Whether the input is required. If required and not present, will throw. Defaults to false */
required?: boolean;
/** Optional. Whether leading/trailing whitespace will be trimmed for the input. Defaults to true */
trimWhitespace?: boolean;
}
/**
* The code to exit an action
@ -18,12 +20,43 @@ export declare enum ExitCode {
*/
Failure = 1
}
/**
* Optional properties that can be sent with annotatation commands (notice, error, and warning)
* See: https://docs.github.com/en/rest/reference/checks#create-a-check-run for more information about annotations.
*/
export interface AnnotationProperties {
/**
* A title for the annotation.
*/
title?: string;
/**
* The path of the file for which the annotation should be created.
*/
file?: string;
/**
* The start line for the annotation.
*/
startLine?: number;
/**
* The end line for the annotation. Defaults to `startLine` when `startLine` is provided.
*/
endLine?: number;
/**
* The start column for the annotation. Cannot be sent when `startLine` and `endLine` are different values.
*/
startColumn?: number;
/**
* The start column for the annotation. Cannot be sent when `startLine` and `endLine` are different values.
* Defaults to `startColumn` when `startColumn` is provided.
*/
endColumn?: number;
}
/**
* Sets env variable for this action and future actions in the job
* @param name the name of the variable to set
* @param val the value of the variable
* @param val the value of the variable. Non-string values will be converted to a string via JSON.stringify
*/
export declare function exportVariable(name: string, val: string): void;
export declare function exportVariable(name: string, val: any): void;
/**
* Registers a secret which will get masked from logs
* @param secret value of the secret
@ -35,26 +68,54 @@ export declare function setSecret(secret: string): void;
*/
export declare function addPath(inputPath: string): void;
/**
* Gets the value of an input. The value is also trimmed.
* Gets the value of an input.
* Unless trimWhitespace is set to false in InputOptions, the value is also trimmed.
* Returns an empty string if the value is not defined.
*
* @param name name of the input to get
* @param options optional. See InputOptions.
* @returns string
*/
export declare function getInput(name: string, options?: InputOptions): string;
/**
* Gets the values of an multiline input. Each value is also trimmed.
*
* @param name name of the input to get
* @param options optional. See InputOptions.
* @returns string[]
*
*/
export declare function getMultilineInput(name: string, options?: InputOptions): string[];
/**
* Gets the input value of the boolean type in the YAML 1.2 "core schema" specification.
* Support boolean input list: `true | True | TRUE | false | False | FALSE` .
* The return value is also in boolean type.
* ref: https://yaml.org/spec/1.2/spec.html#id2804923
*
* @param name name of the input to get
* @param options optional. See InputOptions.
* @returns boolean
*/
export declare function getBooleanInput(name: string, options?: InputOptions): boolean;
/**
* Sets the value of an output.
*
* @param name name of the output to set
* @param value value to store
* @param value value to store. Non-string values will be converted to a string via JSON.stringify
*/
export declare function setOutput(name: string, value: string): void;
export declare function setOutput(name: string, value: any): void;
/**
* Enables or disables the echoing of commands into stdout for the rest of the step.
* Echoing is disabled by default if ACTIONS_STEP_DEBUG is not set.
*
*/
export declare function setCommandEcho(enabled: boolean): void;
/**
* Sets the action status to failed.
* When the action exits it will be with an exit code of 1
* @param message add error issue message
*/
export declare function setFailed(message: string): void;
export declare function setFailed(message: string | Error): void;
/**
* Gets whether Actions Step Debug is on or not
*/
@ -66,14 +127,22 @@ export declare function isDebug(): boolean;
export declare function debug(message: string): void;
/**
* Adds an error issue
* @param message error issue message
* @param message error issue message. Errors will be converted to string via toString()
* @param properties optional properties to add to the annotation.
*/
export declare function error(message: string): void;
export declare function error(message: string | Error, properties?: AnnotationProperties): void;
/**
* Adds an warning issue
* @param message warning issue message
* Adds a warning issue
* @param message warning issue message. Errors will be converted to string via toString()
* @param properties optional properties to add to the annotation.
*/
export declare function warning(message: string): void;
export declare function warning(message: string | Error, properties?: AnnotationProperties): void;
/**
* Adds a notice issue
* @param message notice issue message. Errors will be converted to string via toString()
* @param properties optional properties to add to the annotation.
*/
export declare function notice(message: string | Error, properties?: AnnotationProperties): void;
/**
* Writes info to log with console.log.
* @param message info message
@ -104,9 +173,9 @@ export declare function group<T>(name: string, fn: () => Promise<T>): Promise<T>
* Saves state for current action, the state can only be retrieved by this action's post job execution.
*
* @param name name of the state to store
* @param value value to store
* @param value value to store. Non-string values will be converted to a string via JSON.stringify
*/
export declare function saveState(name: string, value: string): void;
export declare function saveState(name: string, value: any): void;
/**
* Gets the value of an state set by this action's main execution.
*
@ -114,3 +183,4 @@ export declare function saveState(name: string, value: string): void;
* @returns string
*/
export declare function getState(name: string): string;
export declare function getIDToken(aud?: string): Promise<string>;

View File

@ -1,4 +1,23 @@
"use strict";
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
if (k2 === undefined) k2 = k;
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
}) : (function(o, m, k, k2) {
if (k2 === undefined) k2 = k;
o[k2] = m[k];
}));
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
Object.defineProperty(o, "default", { enumerable: true, value: v });
}) : function(o, v) {
o["default"] = v;
});
var __importStar = (this && this.__importStar) || function (mod) {
if (mod && mod.__esModule) return mod;
var result = {};
if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
__setModuleDefault(result, mod);
return result;
};
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
return new (P || (P = Promise))(function (resolve, reject) {
@ -8,17 +27,14 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
step((generator = generator.apply(thisArg, _arguments || [])).next());
});
};
var __importStar = (this && this.__importStar) || function (mod) {
if (mod && mod.__esModule) return mod;
var result = {};
if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];
result["default"] = mod;
return result;
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.getIDToken = exports.getState = exports.saveState = exports.group = exports.endGroup = exports.startGroup = exports.info = exports.notice = exports.warning = exports.error = exports.debug = exports.isDebug = exports.setFailed = exports.setCommandEcho = exports.setOutput = exports.getBooleanInput = exports.getMultilineInput = exports.getInput = exports.addPath = exports.setSecret = exports.exportVariable = exports.ExitCode = void 0;
const command_1 = require("./command");
const file_command_1 = require("./file-command");
const utils_1 = require("./utils");
const os = __importStar(require("os"));
const path = __importStar(require("path"));
const oidc_utils_1 = require("./oidc-utils");
/**
* The code to exit an action
*/
@ -39,11 +55,21 @@ var ExitCode;
/**
* Sets env variable for this action and future actions in the job
* @param name the name of the variable to set
* @param val the value of the variable
* @param val the value of the variable. Non-string values will be converted to a string via JSON.stringify
*/
// eslint-disable-next-line @typescript-eslint/no-explicit-any
function exportVariable(name, val) {
process.env[name] = val;
command_1.issueCommand('set-env', { name }, val);
const convertedVal = utils_1.toCommandValue(val);
process.env[name] = convertedVal;
const filePath = process.env['GITHUB_ENV'] || '';
if (filePath) {
const delimiter = '_GitHubActionsFileCommandDelimeter_';
const commandValue = `${name}<<${delimiter}${os.EOL}${convertedVal}${os.EOL}${delimiter}`;
file_command_1.issueCommand('ENV', commandValue);
}
else {
command_1.issueCommand('set-env', { name }, convertedVal);
}
}
exports.exportVariable = exportVariable;
/**
@ -59,12 +85,20 @@ exports.setSecret = setSecret;
* @param inputPath
*/
function addPath(inputPath) {
command_1.issueCommand('add-path', {}, inputPath);
const filePath = process.env['GITHUB_PATH'] || '';
if (filePath) {
file_command_1.issueCommand('PATH', inputPath);
}
else {
command_1.issueCommand('add-path', {}, inputPath);
}
process.env['PATH'] = `${inputPath}${path.delimiter}${process.env['PATH']}`;
}
exports.addPath = addPath;
/**
* Gets the value of an input. The value is also trimmed.
* Gets the value of an input.
* Unless trimWhitespace is set to false in InputOptions, the value is also trimmed.
* Returns an empty string if the value is not defined.
*
* @param name name of the input to get
* @param options optional. See InputOptions.
@ -75,19 +109,70 @@ function getInput(name, options) {
if (options && options.required && !val) {
throw new Error(`Input required and not supplied: ${name}`);
}
if (options && options.trimWhitespace === false) {
return val;
}
return val.trim();
}
exports.getInput = getInput;
/**
* Gets the values of an multiline input. Each value is also trimmed.
*
* @param name name of the input to get
* @param options optional. See InputOptions.
* @returns string[]
*
*/
function getMultilineInput(name, options) {
const inputs = getInput(name, options)
.split('\n')
.filter(x => x !== '');
return inputs;
}
exports.getMultilineInput = getMultilineInput;
/**
* Gets the input value of the boolean type in the YAML 1.2 "core schema" specification.
* Support boolean input list: `true | True | TRUE | false | False | FALSE` .
* The return value is also in boolean type.
* ref: https://yaml.org/spec/1.2/spec.html#id2804923
*
* @param name name of the input to get
* @param options optional. See InputOptions.
* @returns boolean
*/
function getBooleanInput(name, options) {
const trueValue = ['true', 'True', 'TRUE'];
const falseValue = ['false', 'False', 'FALSE'];
const val = getInput(name, options);
if (trueValue.includes(val))
return true;
if (falseValue.includes(val))
return false;
throw new TypeError(`Input does not meet YAML 1.2 "Core Schema" specification: ${name}\n` +
`Support boolean input list: \`true | True | TRUE | false | False | FALSE\``);
}
exports.getBooleanInput = getBooleanInput;
/**
* Sets the value of an output.
*
* @param name name of the output to set
* @param value value to store
* @param value value to store. Non-string values will be converted to a string via JSON.stringify
*/
// eslint-disable-next-line @typescript-eslint/no-explicit-any
function setOutput(name, value) {
process.stdout.write(os.EOL);
command_1.issueCommand('set-output', { name }, value);
}
exports.setOutput = setOutput;
/**
* Enables or disables the echoing of commands into stdout for the rest of the step.
* Echoing is disabled by default if ACTIONS_STEP_DEBUG is not set.
*
*/
function setCommandEcho(enabled) {
command_1.issue('echo', enabled ? 'on' : 'off');
}
exports.setCommandEcho = setCommandEcho;
//-----------------------------------------------------------------------
// Results
//-----------------------------------------------------------------------
@ -121,20 +206,31 @@ function debug(message) {
exports.debug = debug;
/**
* Adds an error issue
* @param message error issue message
* @param message error issue message. Errors will be converted to string via toString()
* @param properties optional properties to add to the annotation.
*/
function error(message) {
command_1.issue('error', message);
function error(message, properties = {}) {
command_1.issueCommand('error', utils_1.toCommandProperties(properties), message instanceof Error ? message.toString() : message);
}
exports.error = error;
/**
* Adds an warning issue
* @param message warning issue message
* Adds a warning issue
* @param message warning issue message. Errors will be converted to string via toString()
* @param properties optional properties to add to the annotation.
*/
function warning(message) {
command_1.issue('warning', message);
function warning(message, properties = {}) {
command_1.issueCommand('warning', utils_1.toCommandProperties(properties), message instanceof Error ? message.toString() : message);
}
exports.warning = warning;
/**
* Adds a notice issue
* @param message notice issue message. Errors will be converted to string via toString()
* @param properties optional properties to add to the annotation.
*/
function notice(message, properties = {}) {
command_1.issueCommand('notice', utils_1.toCommandProperties(properties), message instanceof Error ? message.toString() : message);
}
exports.notice = notice;
/**
* Writes info to log with console.log.
* @param message info message
@ -190,8 +286,9 @@ exports.group = group;
* Saves state for current action, the state can only be retrieved by this action's post job execution.
*
* @param name name of the state to store
* @param value value to store
* @param value value to store. Non-string values will be converted to a string via JSON.stringify
*/
// eslint-disable-next-line @typescript-eslint/no-explicit-any
function saveState(name, value) {
command_1.issueCommand('save-state', { name }, value);
}
@ -206,4 +303,10 @@ function getState(name) {
return process.env[`STATE_${name}`] || '';
}
exports.getState = getState;
function getIDToken(aud) {
return __awaiter(this, void 0, void 0, function* () {
return yield oidc_utils_1.OidcClient.getIDToken(aud);
});
}
exports.getIDToken = getIDToken;
//# sourceMappingURL=core.js.map

View File

@ -1 +1 @@
{"version":3,"file":"core.js","sourceRoot":"","sources":["../src/core.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AAAA,uCAA6C;AAE7C,uCAAwB;AACxB,2CAA4B;AAU5B;;GAEG;AACH,IAAY,QAUX;AAVD,WAAY,QAAQ;IAClB;;OAEG;IACH,6CAAW,CAAA;IAEX;;OAEG;IACH,6CAAW,CAAA;AACb,CAAC,EAVW,QAAQ,GAAR,gBAAQ,KAAR,gBAAQ,QAUnB;AAED,yEAAyE;AACzE,YAAY;AACZ,yEAAyE;AAEzE;;;;GAIG;AACH,SAAgB,cAAc,CAAC,IAAY,EAAE,GAAW;IACtD,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,GAAG,GAAG,CAAA;IACvB,sBAAY,CAAC,SAAS,EAAE,EAAC,IAAI,EAAC,EAAE,GAAG,CAAC,CAAA;AACtC,CAAC;AAHD,wCAGC;AAED;;;GAGG;AACH,SAAgB,SAAS,CAAC,MAAc;IACtC,sBAAY,CAAC,UAAU,EAAE,EAAE,EAAE,MAAM,CAAC,CAAA;AACtC,CAAC;AAFD,8BAEC;AAED;;;GAGG;AACH,SAAgB,OAAO,CAAC,SAAiB;IACvC,sBAAY,CAAC,UAAU,EAAE,EAAE,EAAE,SAAS,CAAC,CAAA;IACvC,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,GAAG,GAAG,SAAS,GAAG,IAAI,CAAC,SAAS,GAAG,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,EAAE,CAAA;AAC7E,CAAC;AAHD,0BAGC;AAED;;;;;;GAMG;AACH,SAAgB,QAAQ,CAAC,IAAY,EAAE,OAAsB;IAC3D,MAAM,GAAG,GACP,OAAO,CAAC,GAAG,CAAC,SAAS,IAAI,CAAC,OAAO,CAAC,IAAI,EAAE,GAAG,CAAC,CAAC,WAAW,EAAE,EAAE,CAAC,IAAI,EAAE,CAAA;IACrE,IAAI,OAAO,IAAI,OAAO,CAAC,QAAQ,IAAI,CAAC,GAAG,EAAE;QACvC,MAAM,IAAI,KAAK,CAAC,oCAAoC,IAAI,EAAE,CAAC,CAAA;KAC5D;IAED,OAAO,GAAG,CAAC,IAAI,EAAE,CAAA;AACnB,CAAC;AARD,4BAQC;AAED;;;;;GAKG;AACH,SAAgB,SAAS,CAAC,IAAY,EAAE,KAAa;IACnD,sBAAY,CAAC,YAAY,EAAE,EAAC,IAAI,EAAC,EAAE,KAAK,CAAC,CAAA;AAC3C,CAAC;AAFD,8BAEC;AAED,yEAAyE;AACzE,UAAU;AACV,yEAAyE;AAEzE;;;;GAIG;AACH,SAAgB,SAAS,CAAC,OAAe;IACvC,OAAO,CAAC,QAAQ,GAAG,QAAQ,CAAC,OAAO,CAAA;IACnC,KAAK,CAAC,OAAO,CAAC,CAAA;AAChB,CAAC;AAHD,8BAGC;AAED,yEAAyE;AACzE,mBAAmB;AACnB,yEAAyE;AAEzE;;GAEG;AACH,SAAgB,OAAO;IACrB,OAAO,OAAO,CAAC,GAAG,CAAC,cAAc,CAAC,KAAK,GAAG,CAAA;AAC5C,CAAC;AAFD,0BAEC;AAED;;;GAGG;AACH,SAAgB,KAAK,CAAC,OAAe;IACnC,sBAAY,CAAC,OAAO,EAAE,EAAE,EAAE,OAAO,CAAC,CAAA;AACpC,CAAC;AAFD,sBAEC;AAED;;;GAGG;AACH,SAAgB,KAAK,CAAC,OAAe;IACnC,eAAK,CAAC,OAAO,EAAE,OAAO,CAAC,CAAA;AACzB,CAAC;AAFD,sBAEC;AAED;;;GAGG;AACH,SAAgB,OAAO,CAAC,OAAe;IACrC,eAAK,CAAC,SAAS,EAAE,OAAO,CAAC,CAAA;AAC3B,CAAC;AAFD,0BAEC;AAED;;;GAGG;AACH,SAAgB,IAAI,CAAC,OAAe;IAClC,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,OAAO,GAAG,EAAE,CAAC,GAAG,CAAC,CAAA;AACxC,CAAC;AAFD,oBAEC;AAED;;;;;;GAMG;AACH,SAAgB,UAAU,CAAC,IAAY;IACrC,eAAK,CAAC,OAAO,EAAE,IAAI,CAAC,CAAA;AACtB,CAAC;AAFD,gCAEC;AAED;;GAEG;AACH,SAAgB,QAAQ;IACtB,eAAK,CAAC,UAAU,CAAC,CAAA;AACnB,CAAC;AAFD,4BAEC;AAED;;;;;;;GAOG;AACH,SAAsB,KAAK,CAAI,IAAY,EAAE,EAAoB;;QAC/D,UAAU,CAAC,IAAI,CAAC,CAAA;QAEhB,IAAI,MAAS,CAAA;QAEb,IAAI;YACF,MAAM,GAAG,MAAM,EAAE,EAAE,CAAA;SACpB;gBAAS;YACR,QAAQ,EAAE,CAAA;SACX;QAED,OAAO,MAAM,CAAA;IACf,CAAC;CAAA;AAZD,sBAYC;AAED,yEAAyE;AACzE,uBAAuB;AACvB,yEAAyE;AAEzE;;;;;GAKG;AACH,SAAgB,SAAS,CAAC,IAAY,EAAE,KAAa;IACnD,sBAAY,CAAC,YAAY,EAAE,EAAC,IAAI,EAAC,EAAE,KAAK,CAAC,CAAA;AAC3C,CAAC;AAFD,8BAEC;AAED;;;;;GAKG;AACH,SAAgB,QAAQ,CAAC,IAAY;IACnC,OAAO,OAAO,CAAC,GAAG,CAAC,SAAS,IAAI,EAAE,CAAC,IAAI,EAAE,CAAA;AAC3C,CAAC;AAFD,4BAEC"}
{"version":3,"file":"core.js","sourceRoot":"","sources":["../src/core.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,uCAA6C;AAC7C,iDAA+D;AAC/D,mCAA2D;AAE3D,uCAAwB;AACxB,2CAA4B;AAE5B,6CAAuC;AAavC;;GAEG;AACH,IAAY,QAUX;AAVD,WAAY,QAAQ;IAClB;;OAEG;IACH,6CAAW,CAAA;IAEX;;OAEG;IACH,6CAAW,CAAA;AACb,CAAC,EAVW,QAAQ,GAAR,gBAAQ,KAAR,gBAAQ,QAUnB;AAuCD,yEAAyE;AACzE,YAAY;AACZ,yEAAyE;AAEzE;;;;GAIG;AACH,8DAA8D;AAC9D,SAAgB,cAAc,CAAC,IAAY,EAAE,GAAQ;IACnD,MAAM,YAAY,GAAG,sBAAc,CAAC,GAAG,CAAC,CAAA;IACxC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,GAAG,YAAY,CAAA;IAEhC,MAAM,QAAQ,GAAG,OAAO,CAAC,GAAG,CAAC,YAAY,CAAC,IAAI,EAAE,CAAA;IAChD,IAAI,QAAQ,EAAE;QACZ,MAAM,SAAS,GAAG,qCAAqC,CAAA;QACvD,MAAM,YAAY,GAAG,GAAG,IAAI,KAAK,SAAS,GAAG,EAAE,CAAC,GAAG,GAAG,YAAY,GAAG,EAAE,CAAC,GAAG,GAAG,SAAS,EAAE,CAAA;QACzF,2BAAgB,CAAC,KAAK,EAAE,YAAY,CAAC,CAAA;KACtC;SAAM;QACL,sBAAY,CAAC,SAAS,EAAE,EAAC,IAAI,EAAC,EAAE,YAAY,CAAC,CAAA;KAC9C;AACH,CAAC;AAZD,wCAYC;AAED;;;GAGG;AACH,SAAgB,SAAS,CAAC,MAAc;IACtC,sBAAY,CAAC,UAAU,EAAE,EAAE,EAAE,MAAM,CAAC,CAAA;AACtC,CAAC;AAFD,8BAEC;AAED;;;GAGG;AACH,SAAgB,OAAO,CAAC,SAAiB;IACvC,MAAM,QAAQ,GAAG,OAAO,CAAC,GAAG,CAAC,aAAa,CAAC,IAAI,EAAE,CAAA;IACjD,IAAI,QAAQ,EAAE;QACZ,2BAAgB,CAAC,MAAM,EAAE,SAAS,CAAC,CAAA;KACpC;SAAM;QACL,sBAAY,CAAC,UAAU,EAAE,EAAE,EAAE,SAAS,CAAC,CAAA;KACxC;IACD,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,GAAG,GAAG,SAAS,GAAG,IAAI,CAAC,SAAS,GAAG,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,EAAE,CAAA;AAC7E,CAAC;AARD,0BAQC;AAED;;;;;;;;GAQG;AACH,SAAgB,QAAQ,CAAC,IAAY,EAAE,OAAsB;IAC3D,MAAM,GAAG,GACP,OAAO,CAAC,GAAG,CAAC,SAAS,IAAI,CAAC,OAAO,CAAC,IAAI,EAAE,GAAG,CAAC,CAAC,WAAW,EAAE,EAAE,CAAC,IAAI,EAAE,CAAA;IACrE,IAAI,OAAO,IAAI,OAAO,CAAC,QAAQ,IAAI,CAAC,GAAG,EAAE;QACvC,MAAM,IAAI,KAAK,CAAC,oCAAoC,IAAI,EAAE,CAAC,CAAA;KAC5D;IAED,IAAI,OAAO,IAAI,OAAO,CAAC,cAAc,KAAK,KAAK,EAAE;QAC/C,OAAO,GAAG,CAAA;KACX;IAED,OAAO,GAAG,CAAC,IAAI,EAAE,CAAA;AACnB,CAAC;AAZD,4BAYC;AAED;;;;;;;GAOG;AACH,SAAgB,iBAAiB,CAC/B,IAAY,EACZ,OAAsB;IAEtB,MAAM,MAAM,GAAa,QAAQ,CAAC,IAAI,EAAE,OAAO,CAAC;SAC7C,KAAK,CAAC,IAAI,CAAC;SACX,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,KAAK,EAAE,CAAC,CAAA;IAExB,OAAO,MAAM,CAAA;AACf,CAAC;AATD,8CASC;AAED;;;;;;;;;GASG;AACH,SAAgB,eAAe,CAAC,IAAY,EAAE,OAAsB;IAClE,MAAM,SAAS,GAAG,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,CAAC,CAAA;IAC1C,MAAM,UAAU,GAAG,CAAC,OAAO,EAAE,OAAO,EAAE,OAAO,CAAC,CAAA;IAC9C,MAAM,GAAG,GAAG,QAAQ,CAAC,IAAI,EAAE,OAAO,CAAC,CAAA;IACnC,IAAI,SAAS,CAAC,QAAQ,CAAC,GAAG,CAAC;QAAE,OAAO,IAAI,CAAA;IACxC,IAAI,UAAU,CAAC,QAAQ,CAAC,GAAG,CAAC;QAAE,OAAO,KAAK,CAAA;IAC1C,MAAM,IAAI,SAAS,CACjB,6DAA6D,IAAI,IAAI;QACnE,4EAA4E,CAC/E,CAAA;AACH,CAAC;AAVD,0CAUC;AAED;;;;;GAKG;AACH,8DAA8D;AAC9D,SAAgB,SAAS,CAAC,IAAY,EAAE,KAAU;IAChD,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,EAAE,CAAC,GAAG,CAAC,CAAA;IAC5B,sBAAY,CAAC,YAAY,EAAE,EAAC,IAAI,EAAC,EAAE,KAAK,CAAC,CAAA;AAC3C,CAAC;AAHD,8BAGC;AAED;;;;GAIG;AACH,SAAgB,cAAc,CAAC,OAAgB;IAC7C,eAAK,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,CAAC,CAAA;AACvC,CAAC;AAFD,wCAEC;AAED,yEAAyE;AACzE,UAAU;AACV,yEAAyE;AAEzE;;;;GAIG;AACH,SAAgB,SAAS,CAAC,OAAuB;IAC/C,OAAO,CAAC,QAAQ,GAAG,QAAQ,CAAC,OAAO,CAAA;IAEnC,KAAK,CAAC,OAAO,CAAC,CAAA;AAChB,CAAC;AAJD,8BAIC;AAED,yEAAyE;AACzE,mBAAmB;AACnB,yEAAyE;AAEzE;;GAEG;AACH,SAAgB,OAAO;IACrB,OAAO,OAAO,CAAC,GAAG,CAAC,cAAc,CAAC,KAAK,GAAG,CAAA;AAC5C,CAAC;AAFD,0BAEC;AAED;;;GAGG;AACH,SAAgB,KAAK,CAAC,OAAe;IACnC,sBAAY,CAAC,OAAO,EAAE,EAAE,EAAE,OAAO,CAAC,CAAA;AACpC,CAAC;AAFD,sBAEC;AAED;;;;GAIG;AACH,SAAgB,KAAK,CACnB,OAAuB,EACvB,aAAmC,EAAE;IAErC,sBAAY,CACV,OAAO,EACP,2BAAmB,CAAC,UAAU,CAAC,EAC/B,OAAO,YAAY,KAAK,CAAC,CAAC,CAAC,OAAO,CAAC,QAAQ,EAAE,CAAC,CAAC,CAAC,OAAO,CACxD,CAAA;AACH,CAAC;AATD,sBASC;AAED;;;;GAIG;AACH,SAAgB,OAAO,CACrB,OAAuB,EACvB,aAAmC,EAAE;IAErC,sBAAY,CACV,SAAS,EACT,2BAAmB,CAAC,UAAU,CAAC,EAC/B,OAAO,YAAY,KAAK,CAAC,CAAC,CAAC,OAAO,CAAC,QAAQ,EAAE,CAAC,CAAC,CAAC,OAAO,CACxD,CAAA;AACH,CAAC;AATD,0BASC;AAED;;;;GAIG;AACH,SAAgB,MAAM,CACpB,OAAuB,EACvB,aAAmC,EAAE;IAErC,sBAAY,CACV,QAAQ,EACR,2BAAmB,CAAC,UAAU,CAAC,EAC/B,OAAO,YAAY,KAAK,CAAC,CAAC,CAAC,OAAO,CAAC,QAAQ,EAAE,CAAC,CAAC,CAAC,OAAO,CACxD,CAAA;AACH,CAAC;AATD,wBASC;AAED;;;GAGG;AACH,SAAgB,IAAI,CAAC,OAAe;IAClC,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,OAAO,GAAG,EAAE,CAAC,GAAG,CAAC,CAAA;AACxC,CAAC;AAFD,oBAEC;AAED;;;;;;GAMG;AACH,SAAgB,UAAU,CAAC,IAAY;IACrC,eAAK,CAAC,OAAO,EAAE,IAAI,CAAC,CAAA;AACtB,CAAC;AAFD,gCAEC;AAED;;GAEG;AACH,SAAgB,QAAQ;IACtB,eAAK,CAAC,UAAU,CAAC,CAAA;AACnB,CAAC;AAFD,4BAEC;AAED;;;;;;;GAOG;AACH,SAAsB,KAAK,CAAI,IAAY,EAAE,EAAoB;;QAC/D,UAAU,CAAC,IAAI,CAAC,CAAA;QAEhB,IAAI,MAAS,CAAA;QAEb,IAAI;YACF,MAAM,GAAG,MAAM,EAAE,EAAE,CAAA;SACpB;gBAAS;YACR,QAAQ,EAAE,CAAA;SACX;QAED,OAAO,MAAM,CAAA;IACf,CAAC;CAAA;AAZD,sBAYC;AAED,yEAAyE;AACzE,uBAAuB;AACvB,yEAAyE;AAEzE;;;;;GAKG;AACH,8DAA8D;AAC9D,SAAgB,SAAS,CAAC,IAAY,EAAE,KAAU;IAChD,sBAAY,CAAC,YAAY,EAAE,EAAC,IAAI,EAAC,EAAE,KAAK,CAAC,CAAA;AAC3C,CAAC;AAFD,8BAEC;AAED;;;;;GAKG;AACH,SAAgB,QAAQ,CAAC,IAAY;IACnC,OAAO,OAAO,CAAC,GAAG,CAAC,SAAS,IAAI,EAAE,CAAC,IAAI,EAAE,CAAA;AAC3C,CAAC;AAFD,4BAEC;AAED,SAAsB,UAAU,CAAC,GAAY;;QAC3C,OAAO,MAAM,uBAAU,CAAC,UAAU,CAAC,GAAG,CAAC,CAAA;IACzC,CAAC;CAAA;AAFD,gCAEC"}

1
node_modules/@actions/core/lib/file-command.d.ts generated vendored Normal file
View File

@ -0,0 +1 @@
export declare function issueCommand(command: string, message: any): void;

42
node_modules/@actions/core/lib/file-command.js generated vendored Normal file
View File

@ -0,0 +1,42 @@
"use strict";
// For internal use, subject to change.
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
if (k2 === undefined) k2 = k;
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
}) : (function(o, m, k, k2) {
if (k2 === undefined) k2 = k;
o[k2] = m[k];
}));
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
Object.defineProperty(o, "default", { enumerable: true, value: v });
}) : function(o, v) {
o["default"] = v;
});
var __importStar = (this && this.__importStar) || function (mod) {
if (mod && mod.__esModule) return mod;
var result = {};
if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
__setModuleDefault(result, mod);
return result;
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.issueCommand = void 0;
// We use any as a valid input type
/* eslint-disable @typescript-eslint/no-explicit-any */
const fs = __importStar(require("fs"));
const os = __importStar(require("os"));
const utils_1 = require("./utils");
function issueCommand(command, message) {
const filePath = process.env[`GITHUB_${command}`];
if (!filePath) {
throw new Error(`Unable to find environment variable for file command ${command}`);
}
if (!fs.existsSync(filePath)) {
throw new Error(`Missing file at path: ${filePath}`);
}
fs.appendFileSync(filePath, `${utils_1.toCommandValue(message)}${os.EOL}`, {
encoding: 'utf8'
});
}
exports.issueCommand = issueCommand;
//# sourceMappingURL=file-command.js.map

1
node_modules/@actions/core/lib/file-command.js.map generated vendored Normal file
View File

@ -0,0 +1 @@
{"version":3,"file":"file-command.js","sourceRoot":"","sources":["../src/file-command.ts"],"names":[],"mappings":";AAAA,uCAAuC;;;;;;;;;;;;;;;;;;;;;;AAEvC,mCAAmC;AACnC,uDAAuD;AAEvD,uCAAwB;AACxB,uCAAwB;AACxB,mCAAsC;AAEtC,SAAgB,YAAY,CAAC,OAAe,EAAE,OAAY;IACxD,MAAM,QAAQ,GAAG,OAAO,CAAC,GAAG,CAAC,UAAU,OAAO,EAAE,CAAC,CAAA;IACjD,IAAI,CAAC,QAAQ,EAAE;QACb,MAAM,IAAI,KAAK,CACb,wDAAwD,OAAO,EAAE,CAClE,CAAA;KACF;IACD,IAAI,CAAC,EAAE,CAAC,UAAU,CAAC,QAAQ,CAAC,EAAE;QAC5B,MAAM,IAAI,KAAK,CAAC,yBAAyB,QAAQ,EAAE,CAAC,CAAA;KACrD;IAED,EAAE,CAAC,cAAc,CAAC,QAAQ,EAAE,GAAG,sBAAc,CAAC,OAAO,CAAC,GAAG,EAAE,CAAC,GAAG,EAAE,EAAE;QACjE,QAAQ,EAAE,MAAM;KACjB,CAAC,CAAA;AACJ,CAAC;AAdD,oCAcC"}

7
node_modules/@actions/core/lib/oidc-utils.d.ts generated vendored Normal file
View File

@ -0,0 +1,7 @@
export declare class OidcClient {
private static createHttpClient;
private static getRequestToken;
private static getIDTokenUrl;
private static getCall;
static getIDToken(audience?: string): Promise<string>;
}

77
node_modules/@actions/core/lib/oidc-utils.js generated vendored Normal file
View File

@ -0,0 +1,77 @@
"use strict";
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
return new (P || (P = Promise))(function (resolve, reject) {
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
step((generator = generator.apply(thisArg, _arguments || [])).next());
});
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.OidcClient = void 0;
const http_client_1 = require("@actions/http-client");
const auth_1 = require("@actions/http-client/auth");
const core_1 = require("./core");
class OidcClient {
static createHttpClient(allowRetry = true, maxRetry = 10) {
const requestOptions = {
allowRetries: allowRetry,
maxRetries: maxRetry
};
return new http_client_1.HttpClient('actions/oidc-client', [new auth_1.BearerCredentialHandler(OidcClient.getRequestToken())], requestOptions);
}
static getRequestToken() {
const token = process.env['ACTIONS_ID_TOKEN_REQUEST_TOKEN'];
if (!token) {
throw new Error('Unable to get ACTIONS_ID_TOKEN_REQUEST_TOKEN env variable');
}
return token;
}
static getIDTokenUrl() {
const runtimeUrl = process.env['ACTIONS_ID_TOKEN_REQUEST_URL'];
if (!runtimeUrl) {
throw new Error('Unable to get ACTIONS_ID_TOKEN_REQUEST_URL env variable');
}
return runtimeUrl;
}
static getCall(id_token_url) {
var _a;
return __awaiter(this, void 0, void 0, function* () {
const httpclient = OidcClient.createHttpClient();
const res = yield httpclient
.getJson(id_token_url)
.catch(error => {
throw new Error(`Failed to get ID Token. \n
Error Code : ${error.statusCode}\n
Error Message: ${error.result.message}`);
});
const id_token = (_a = res.result) === null || _a === void 0 ? void 0 : _a.value;
if (!id_token) {
throw new Error('Response json body do not have ID Token field');
}
return id_token;
});
}
static getIDToken(audience) {
return __awaiter(this, void 0, void 0, function* () {
try {
// New ID Token is requested from action service
let id_token_url = OidcClient.getIDTokenUrl();
if (audience) {
const encodedAudience = encodeURIComponent(audience);
id_token_url = `${id_token_url}&audience=${encodedAudience}`;
}
core_1.debug(`ID token url is ${id_token_url}`);
const id_token = yield OidcClient.getCall(id_token_url);
core_1.setSecret(id_token);
return id_token;
}
catch (error) {
throw new Error(`Error message: ${error.message}`);
}
});
}
}
exports.OidcClient = OidcClient;
//# sourceMappingURL=oidc-utils.js.map

1
node_modules/@actions/core/lib/oidc-utils.js.map generated vendored Normal file
View File

@ -0,0 +1 @@
{"version":3,"file":"oidc-utils.js","sourceRoot":"","sources":["../src/oidc-utils.ts"],"names":[],"mappings":";;;;;;;;;;;;AAGA,sDAA+C;AAC/C,oDAAiE;AACjE,iCAAuC;AAKvC,MAAa,UAAU;IACb,MAAM,CAAC,gBAAgB,CAC7B,UAAU,GAAG,IAAI,EACjB,QAAQ,GAAG,EAAE;QAEb,MAAM,cAAc,GAAoB;YACtC,YAAY,EAAE,UAAU;YACxB,UAAU,EAAE,QAAQ;SACrB,CAAA;QAED,OAAO,IAAI,wBAAU,CACnB,qBAAqB,EACrB,CAAC,IAAI,8BAAuB,CAAC,UAAU,CAAC,eAAe,EAAE,CAAC,CAAC,EAC3D,cAAc,CACf,CAAA;IACH,CAAC;IAEO,MAAM,CAAC,eAAe;QAC5B,MAAM,KAAK,GAAG,OAAO,CAAC,GAAG,CAAC,gCAAgC,CAAC,CAAA;QAC3D,IAAI,CAAC,KAAK,EAAE;YACV,MAAM,IAAI,KAAK,CACb,2DAA2D,CAC5D,CAAA;SACF;QACD,OAAO,KAAK,CAAA;IACd,CAAC;IAEO,MAAM,CAAC,aAAa;QAC1B,MAAM,UAAU,GAAG,OAAO,CAAC,GAAG,CAAC,8BAA8B,CAAC,CAAA;QAC9D,IAAI,CAAC,UAAU,EAAE;YACf,MAAM,IAAI,KAAK,CAAC,yDAAyD,CAAC,CAAA;SAC3E;QACD,OAAO,UAAU,CAAA;IACnB,CAAC;IAEO,MAAM,CAAO,OAAO,CAAC,YAAoB;;;YAC/C,MAAM,UAAU,GAAG,UAAU,CAAC,gBAAgB,EAAE,CAAA;YAEhD,MAAM,GAAG,GAAG,MAAM,UAAU;iBACzB,OAAO,CAAgB,YAAY,CAAC;iBACpC,KAAK,CAAC,KAAK,CAAC,EAAE;gBACb,MAAM,IAAI,KAAK,CACb;uBACa,KAAK,CAAC,UAAU;yBACd,KAAK,CAAC,MAAM,CAAC,OAAO,EAAE,CACtC,CAAA;YACH,CAAC,CAAC,CAAA;YAEJ,MAAM,QAAQ,SAAG,GAAG,CAAC,MAAM,0CAAE,KAAK,CAAA;YAClC,IAAI,CAAC,QAAQ,EAAE;gBACb,MAAM,IAAI,KAAK,CAAC,+CAA+C,CAAC,CAAA;aACjE;YACD,OAAO,QAAQ,CAAA;;KAChB;IAED,MAAM,CAAO,UAAU,CAAC,QAAiB;;YACvC,IAAI;gBACF,gDAAgD;gBAChD,IAAI,YAAY,GAAW,UAAU,CAAC,aAAa,EAAE,CAAA;gBACrD,IAAI,QAAQ,EAAE;oBACZ,MAAM,eAAe,GAAG,kBAAkB,CAAC,QAAQ,CAAC,CAAA;oBACpD,YAAY,GAAG,GAAG,YAAY,aAAa,eAAe,EAAE,CAAA;iBAC7D;gBAED,YAAK,CAAC,mBAAmB,YAAY,EAAE,CAAC,CAAA;gBAExC,MAAM,QAAQ,GAAG,MAAM,UAAU,CAAC,OAAO,CAAC,YAAY,CAAC,CAAA;gBACvD,gBAAS,CAAC,QAAQ,CAAC,CAAA;gBACnB,OAAO,QAAQ,CAAA;aAChB;YAAC,OAAO,KAAK,EAAE;gBACd,MAAM,IAAI,KAAK,CAAC,kBAAkB,KAAK,CAAC,OAAO,EAAE,CAAC,CAAA;aACnD;QACH,CAAC;KAAA;CACF;AAzED,gCAyEC"}

14
node_modules/@actions/core/lib/utils.d.ts generated vendored Normal file
View File

@ -0,0 +1,14 @@
import { AnnotationProperties } from './core';
import { CommandProperties } from './command';
/**
* Sanitizes an input into a string so it can be passed into issueCommand safely
* @param input input to sanitize into a string
*/
export declare function toCommandValue(input: any): string;
/**
*
* @param annotationProperties
* @returns The command properties to send with the actual annotation command
* See IssueCommandProperties: https://github.com/actions/runner/blob/main/src/Runner.Worker/ActionCommandManager.cs#L646
*/
export declare function toCommandProperties(annotationProperties: AnnotationProperties): CommandProperties;

40
node_modules/@actions/core/lib/utils.js generated vendored Normal file
View File

@ -0,0 +1,40 @@
"use strict";
// We use any as a valid input type
/* eslint-disable @typescript-eslint/no-explicit-any */
Object.defineProperty(exports, "__esModule", { value: true });
exports.toCommandProperties = exports.toCommandValue = void 0;
/**
* Sanitizes an input into a string so it can be passed into issueCommand safely
* @param input input to sanitize into a string
*/
function toCommandValue(input) {
if (input === null || input === undefined) {
return '';
}
else if (typeof input === 'string' || input instanceof String) {
return input;
}
return JSON.stringify(input);
}
exports.toCommandValue = toCommandValue;
/**
*
* @param annotationProperties
* @returns The command properties to send with the actual annotation command
* See IssueCommandProperties: https://github.com/actions/runner/blob/main/src/Runner.Worker/ActionCommandManager.cs#L646
*/
function toCommandProperties(annotationProperties) {
if (!Object.keys(annotationProperties).length) {
return {};
}
return {
title: annotationProperties.title,
file: annotationProperties.file,
line: annotationProperties.startLine,
endLine: annotationProperties.endLine,
col: annotationProperties.startColumn,
endColumn: annotationProperties.endColumn
};
}
exports.toCommandProperties = toCommandProperties;
//# sourceMappingURL=utils.js.map

1
node_modules/@actions/core/lib/utils.js.map generated vendored Normal file
View File

@ -0,0 +1 @@
{"version":3,"file":"utils.js","sourceRoot":"","sources":["../src/utils.ts"],"names":[],"mappings":";AAAA,mCAAmC;AACnC,uDAAuD;;;AAKvD;;;GAGG;AACH,SAAgB,cAAc,CAAC,KAAU;IACvC,IAAI,KAAK,KAAK,IAAI,IAAI,KAAK,KAAK,SAAS,EAAE;QACzC,OAAO,EAAE,CAAA;KACV;SAAM,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,KAAK,YAAY,MAAM,EAAE;QAC/D,OAAO,KAAe,CAAA;KACvB;IACD,OAAO,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,CAAA;AAC9B,CAAC;AAPD,wCAOC;AAED;;;;;GAKG;AACH,SAAgB,mBAAmB,CACjC,oBAA0C;IAE1C,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,oBAAoB,CAAC,CAAC,MAAM,EAAE;QAC7C,OAAO,EAAE,CAAA;KACV;IAED,OAAO;QACL,KAAK,EAAE,oBAAoB,CAAC,KAAK;QACjC,IAAI,EAAE,oBAAoB,CAAC,IAAI;QAC/B,IAAI,EAAE,oBAAoB,CAAC,SAAS;QACpC,OAAO,EAAE,oBAAoB,CAAC,OAAO;QACrC,GAAG,EAAE,oBAAoB,CAAC,WAAW;QACrC,SAAS,EAAE,oBAAoB,CAAC,SAAS;KAC1C,CAAA;AACH,CAAC;AAfD,kDAeC"}

View File

@ -1,13 +1,13 @@
{
"name": "@actions/core",
"version": "1.2.3",
"version": "1.6.0",
"description": "Actions core lib",
"keywords": [
"github",
"actions",
"core"
],
"homepage": "https://github.com/actions/toolkit/tree/master/packages/core",
"homepage": "https://github.com/actions/toolkit/tree/main/packages/core",
"license": "MIT",
"main": "lib/core.js",
"types": "lib/core.d.ts",
@ -16,7 +16,8 @@
"test": "__tests__"
},
"files": [
"lib"
"lib",
"!.DS_Store"
],
"publishConfig": {
"access": "public"
@ -27,18 +28,17 @@
"directory": "packages/core"
},
"scripts": {
"audit-moderate": "npm install && npm audit --audit-level=moderate",
"audit-moderate": "npm install && npm audit --json --audit-level=moderate > audit.json",
"test": "echo \"Error: run tests from root\" && exit 1",
"tsc": "tsc"
},
"bugs": {
"url": "https://github.com/actions/toolkit/issues"
},
"dependencies": {
"@actions/http-client": "^1.0.11"
},
"devDependencies": {
"@types/node": "^12.0.2"
}
,"_resolved": "https://registry.npmjs.org/@actions/core/-/core-1.2.3.tgz"
,"_integrity": "sha512-Wp4xnyokakM45Uuj4WLUxdsa8fJjKVl1fDTsPbTEcTcuu0Nb26IPQbOtjmnfaCPGcaoPOOqId8H9NapZ8gii4w=="
,"_from": "@actions/core@1.2.3"
}
}

21
node_modules/@actions/http-client/LICENSE generated vendored Normal file
View File

@ -0,0 +1,21 @@
Actions Http Client for Node.js
Copyright (c) GitHub, Inc.
All rights reserved.
MIT License
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and
associated documentation files (the "Software"), to deal in the Software without restriction,
including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED *AS IS*, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

79
node_modules/@actions/http-client/README.md generated vendored Normal file
View File

@ -0,0 +1,79 @@
<p align="center">
<img src="actions.png">
</p>
# Actions Http-Client
[![Http Status](https://github.com/actions/http-client/workflows/http-tests/badge.svg)](https://github.com/actions/http-client/actions)
A lightweight HTTP client optimized for use with actions, TypeScript with generics and async await.
## Features
- HTTP client with TypeScript generics and async/await/Promises
- Typings included so no need to acquire separately (great for intellisense and no versioning drift)
- [Proxy support](https://help.github.com/en/actions/automating-your-workflow-with-github-actions/about-self-hosted-runners#using-a-proxy-server-with-self-hosted-runners) just works with actions and the runner
- Targets ES2019 (runner runs actions with node 12+). Only supported on node 12+.
- Basic, Bearer and PAT Support out of the box. Extensible handlers for others.
- Redirects supported
Features and releases [here](./RELEASES.md)
## Install
```
npm install @actions/http-client --save
```
## Samples
See the [HTTP](./__tests__) tests for detailed examples.
## Errors
### HTTP
The HTTP client does not throw unless truly exceptional.
* A request that successfully executes resulting in a 404, 500 etc... will return a response object with a status code and a body.
* Redirects (3xx) will be followed by default.
See [HTTP tests](./__tests__) for detailed examples.
## Debugging
To enable detailed console logging of all HTTP requests and responses, set the NODE_DEBUG environment varible:
```
export NODE_DEBUG=http
```
## Node support
The http-client is built using the latest LTS version of Node 12. It may work on previous node LTS versions but it's tested and officially supported on Node12+.
## Support and Versioning
We follow semver and will hold compatibility between major versions and increment the minor version with new features and capabilities (while holding compat).
## Contributing
We welcome PRs. Please create an issue and if applicable, a design before proceeding with code.
once:
```bash
$ npm install
```
To build:
```bash
$ npm run build
```
To run all tests:
```bash
$ npm test
```

26
node_modules/@actions/http-client/RELEASES.md generated vendored Normal file
View File

@ -0,0 +1,26 @@
## Releases
## 1.0.10
Contains a bug fix where proxy is defined without a user and password. see [PR here](https://github.com/actions/http-client/pull/42)
## 1.0.9
Throw HttpClientError instead of a generic Error from the \<verb>Json() helper methods when the server responds with a non-successful status code.
## 1.0.8
Fixed security issue where a redirect (e.g. 302) to another domain would pass headers. The fix was to strip the authorization header if the hostname was different. More [details in PR #27](https://github.com/actions/http-client/pull/27)
## 1.0.7
Update NPM dependencies and add 429 to the list of HttpCodes
## 1.0.6
Automatically sends Content-Type and Accept application/json headers for \<verb>Json() helper methods if not set in the client or parameters.
## 1.0.5
Adds \<verb>Json() helper methods for json over http scenarios.
## 1.0.4
Started to add \<verb>Json() helper methods. Do not use this release for that. Use >= 1.0.5 since there was an issue with types.
## 1.0.1 to 1.0.3
Adds proxy support.

BIN
node_modules/@actions/http-client/actions.png generated vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 33 KiB

23
node_modules/@actions/http-client/auth.d.ts generated vendored Normal file
View File

@ -0,0 +1,23 @@
import ifm = require('./interfaces');
export declare class BasicCredentialHandler implements ifm.IRequestHandler {
username: string;
password: string;
constructor(username: string, password: string);
prepareRequest(options: any): void;
canHandleAuthentication(response: ifm.IHttpClientResponse): boolean;
handleAuthentication(httpClient: ifm.IHttpClient, requestInfo: ifm.IRequestInfo, objs: any): Promise<ifm.IHttpClientResponse>;
}
export declare class BearerCredentialHandler implements ifm.IRequestHandler {
token: string;
constructor(token: string);
prepareRequest(options: any): void;
canHandleAuthentication(response: ifm.IHttpClientResponse): boolean;
handleAuthentication(httpClient: ifm.IHttpClient, requestInfo: ifm.IRequestInfo, objs: any): Promise<ifm.IHttpClientResponse>;
}
export declare class PersonalAccessTokenCredentialHandler implements ifm.IRequestHandler {
token: string;
constructor(token: string);
prepareRequest(options: any): void;
canHandleAuthentication(response: ifm.IHttpClientResponse): boolean;
handleAuthentication(httpClient: ifm.IHttpClient, requestInfo: ifm.IRequestInfo, objs: any): Promise<ifm.IHttpClientResponse>;
}

58
node_modules/@actions/http-client/auth.js generated vendored Normal file
View File

@ -0,0 +1,58 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
class BasicCredentialHandler {
constructor(username, password) {
this.username = username;
this.password = password;
}
prepareRequest(options) {
options.headers['Authorization'] =
'Basic ' +
Buffer.from(this.username + ':' + this.password).toString('base64');
}
// This handler cannot handle 401
canHandleAuthentication(response) {
return false;
}
handleAuthentication(httpClient, requestInfo, objs) {
return null;
}
}
exports.BasicCredentialHandler = BasicCredentialHandler;
class BearerCredentialHandler {
constructor(token) {
this.token = token;
}
// currently implements pre-authorization
// TODO: support preAuth = false where it hooks on 401
prepareRequest(options) {
options.headers['Authorization'] = 'Bearer ' + this.token;
}
// This handler cannot handle 401
canHandleAuthentication(response) {
return false;
}
handleAuthentication(httpClient, requestInfo, objs) {
return null;
}
}
exports.BearerCredentialHandler = BearerCredentialHandler;
class PersonalAccessTokenCredentialHandler {
constructor(token) {
this.token = token;
}
// currently implements pre-authorization
// TODO: support preAuth = false where it hooks on 401
prepareRequest(options) {
options.headers['Authorization'] =
'Basic ' + Buffer.from('PAT:' + this.token).toString('base64');
}
// This handler cannot handle 401
canHandleAuthentication(response) {
return false;
}
handleAuthentication(httpClient, requestInfo, objs) {
return null;
}
}
exports.PersonalAccessTokenCredentialHandler = PersonalAccessTokenCredentialHandler;

124
node_modules/@actions/http-client/index.d.ts generated vendored Normal file
View File

@ -0,0 +1,124 @@
/// <reference types="node" />
import http = require('http');
import ifm = require('./interfaces');
export declare enum HttpCodes {
OK = 200,
MultipleChoices = 300,
MovedPermanently = 301,
ResourceMoved = 302,
SeeOther = 303,
NotModified = 304,
UseProxy = 305,
SwitchProxy = 306,
TemporaryRedirect = 307,
PermanentRedirect = 308,
BadRequest = 400,
Unauthorized = 401,
PaymentRequired = 402,
Forbidden = 403,
NotFound = 404,
MethodNotAllowed = 405,
NotAcceptable = 406,
ProxyAuthenticationRequired = 407,
RequestTimeout = 408,
Conflict = 409,
Gone = 410,
TooManyRequests = 429,
InternalServerError = 500,
NotImplemented = 501,
BadGateway = 502,
ServiceUnavailable = 503,
GatewayTimeout = 504
}
export declare enum Headers {
Accept = "accept",
ContentType = "content-type"
}
export declare enum MediaTypes {
ApplicationJson = "application/json"
}
/**
* Returns the proxy URL, depending upon the supplied url and proxy environment variables.
* @param serverUrl The server URL where the request will be sent. For example, https://api.github.com
*/
export declare function getProxyUrl(serverUrl: string): string;
export declare class HttpClientError extends Error {
constructor(message: string, statusCode: number);
statusCode: number;
result?: any;
}
export declare class HttpClientResponse implements ifm.IHttpClientResponse {
constructor(message: http.IncomingMessage);
message: http.IncomingMessage;
readBody(): Promise<string>;
}
export declare function isHttps(requestUrl: string): boolean;
export declare class HttpClient {
userAgent: string | undefined;
handlers: ifm.IRequestHandler[];
requestOptions: ifm.IRequestOptions;
private _ignoreSslError;
private _socketTimeout;
private _allowRedirects;
private _allowRedirectDowngrade;
private _maxRedirects;
private _allowRetries;
private _maxRetries;
private _agent;
private _proxyAgent;
private _keepAlive;
private _disposed;
constructor(userAgent?: string, handlers?: ifm.IRequestHandler[], requestOptions?: ifm.IRequestOptions);
options(requestUrl: string, additionalHeaders?: ifm.IHeaders): Promise<ifm.IHttpClientResponse>;
get(requestUrl: string, additionalHeaders?: ifm.IHeaders): Promise<ifm.IHttpClientResponse>;
del(requestUrl: string, additionalHeaders?: ifm.IHeaders): Promise<ifm.IHttpClientResponse>;
post(requestUrl: string, data: string, additionalHeaders?: ifm.IHeaders): Promise<ifm.IHttpClientResponse>;
patch(requestUrl: string, data: string, additionalHeaders?: ifm.IHeaders): Promise<ifm.IHttpClientResponse>;
put(requestUrl: string, data: string, additionalHeaders?: ifm.IHeaders): Promise<ifm.IHttpClientResponse>;
head(requestUrl: string, additionalHeaders?: ifm.IHeaders): Promise<ifm.IHttpClientResponse>;
sendStream(verb: string, requestUrl: string, stream: NodeJS.ReadableStream, additionalHeaders?: ifm.IHeaders): Promise<ifm.IHttpClientResponse>;
/**
* Gets a typed object from an endpoint
* Be aware that not found returns a null. Other errors (4xx, 5xx) reject the promise
*/
getJson<T>(requestUrl: string, additionalHeaders?: ifm.IHeaders): Promise<ifm.ITypedResponse<T>>;
postJson<T>(requestUrl: string, obj: any, additionalHeaders?: ifm.IHeaders): Promise<ifm.ITypedResponse<T>>;
putJson<T>(requestUrl: string, obj: any, additionalHeaders?: ifm.IHeaders): Promise<ifm.ITypedResponse<T>>;
patchJson<T>(requestUrl: string, obj: any, additionalHeaders?: ifm.IHeaders): Promise<ifm.ITypedResponse<T>>;
/**
* Makes a raw http request.
* All other methods such as get, post, patch, and request ultimately call this.
* Prefer get, del, post and patch
*/
request(verb: string, requestUrl: string, data: string | NodeJS.ReadableStream, headers: ifm.IHeaders): Promise<ifm.IHttpClientResponse>;
/**
* Needs to be called if keepAlive is set to true in request options.
*/
dispose(): void;
/**
* Raw request.
* @param info
* @param data
*/
requestRaw(info: ifm.IRequestInfo, data: string | NodeJS.ReadableStream): Promise<ifm.IHttpClientResponse>;
/**
* Raw request with callback.
* @param info
* @param data
* @param onResult
*/
requestRawWithCallback(info: ifm.IRequestInfo, data: string | NodeJS.ReadableStream, onResult: (err: any, res: ifm.IHttpClientResponse) => void): void;
/**
* Gets an http agent. This function is useful when you need an http agent that handles
* routing through a proxy server - depending upon the url and proxy environment variables.
* @param serverUrl The server URL where the request will be sent. For example, https://api.github.com
*/
getAgent(serverUrl: string): http.Agent;
private _prepareRequest;
private _mergeHeaders;
private _getExistingOrDefaultHeader;
private _getAgent;
private _performExponentialBackoff;
private static dateTimeDeserializer;
private _processResponse;
}

537
node_modules/@actions/http-client/index.js generated vendored Normal file
View File

@ -0,0 +1,537 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
const http = require("http");
const https = require("https");
const pm = require("./proxy");
let tunnel;
var HttpCodes;
(function (HttpCodes) {
HttpCodes[HttpCodes["OK"] = 200] = "OK";
HttpCodes[HttpCodes["MultipleChoices"] = 300] = "MultipleChoices";
HttpCodes[HttpCodes["MovedPermanently"] = 301] = "MovedPermanently";
HttpCodes[HttpCodes["ResourceMoved"] = 302] = "ResourceMoved";
HttpCodes[HttpCodes["SeeOther"] = 303] = "SeeOther";
HttpCodes[HttpCodes["NotModified"] = 304] = "NotModified";
HttpCodes[HttpCodes["UseProxy"] = 305] = "UseProxy";
HttpCodes[HttpCodes["SwitchProxy"] = 306] = "SwitchProxy";
HttpCodes[HttpCodes["TemporaryRedirect"] = 307] = "TemporaryRedirect";
HttpCodes[HttpCodes["PermanentRedirect"] = 308] = "PermanentRedirect";
HttpCodes[HttpCodes["BadRequest"] = 400] = "BadRequest";
HttpCodes[HttpCodes["Unauthorized"] = 401] = "Unauthorized";
HttpCodes[HttpCodes["PaymentRequired"] = 402] = "PaymentRequired";
HttpCodes[HttpCodes["Forbidden"] = 403] = "Forbidden";
HttpCodes[HttpCodes["NotFound"] = 404] = "NotFound";
HttpCodes[HttpCodes["MethodNotAllowed"] = 405] = "MethodNotAllowed";
HttpCodes[HttpCodes["NotAcceptable"] = 406] = "NotAcceptable";
HttpCodes[HttpCodes["ProxyAuthenticationRequired"] = 407] = "ProxyAuthenticationRequired";
HttpCodes[HttpCodes["RequestTimeout"] = 408] = "RequestTimeout";
HttpCodes[HttpCodes["Conflict"] = 409] = "Conflict";
HttpCodes[HttpCodes["Gone"] = 410] = "Gone";
HttpCodes[HttpCodes["TooManyRequests"] = 429] = "TooManyRequests";
HttpCodes[HttpCodes["InternalServerError"] = 500] = "InternalServerError";
HttpCodes[HttpCodes["NotImplemented"] = 501] = "NotImplemented";
HttpCodes[HttpCodes["BadGateway"] = 502] = "BadGateway";
HttpCodes[HttpCodes["ServiceUnavailable"] = 503] = "ServiceUnavailable";
HttpCodes[HttpCodes["GatewayTimeout"] = 504] = "GatewayTimeout";
})(HttpCodes = exports.HttpCodes || (exports.HttpCodes = {}));
var Headers;
(function (Headers) {
Headers["Accept"] = "accept";
Headers["ContentType"] = "content-type";
})(Headers = exports.Headers || (exports.Headers = {}));
var MediaTypes;
(function (MediaTypes) {
MediaTypes["ApplicationJson"] = "application/json";
})(MediaTypes = exports.MediaTypes || (exports.MediaTypes = {}));
/**
* Returns the proxy URL, depending upon the supplied url and proxy environment variables.
* @param serverUrl The server URL where the request will be sent. For example, https://api.github.com
*/
function getProxyUrl(serverUrl) {
let proxyUrl = pm.getProxyUrl(new URL(serverUrl));
return proxyUrl ? proxyUrl.href : '';
}
exports.getProxyUrl = getProxyUrl;
const HttpRedirectCodes = [
HttpCodes.MovedPermanently,
HttpCodes.ResourceMoved,
HttpCodes.SeeOther,
HttpCodes.TemporaryRedirect,
HttpCodes.PermanentRedirect
];
const HttpResponseRetryCodes = [
HttpCodes.BadGateway,
HttpCodes.ServiceUnavailable,
HttpCodes.GatewayTimeout
];
const RetryableHttpVerbs = ['OPTIONS', 'GET', 'DELETE', 'HEAD'];
const ExponentialBackoffCeiling = 10;
const ExponentialBackoffTimeSlice = 5;
class HttpClientError extends Error {
constructor(message, statusCode) {
super(message);
this.name = 'HttpClientError';
this.statusCode = statusCode;
Object.setPrototypeOf(this, HttpClientError.prototype);
}
}
exports.HttpClientError = HttpClientError;
class HttpClientResponse {
constructor(message) {
this.message = message;
}
readBody() {
return new Promise(async (resolve, reject) => {
let output = Buffer.alloc(0);
this.message.on('data', (chunk) => {
output = Buffer.concat([output, chunk]);
});
this.message.on('end', () => {
resolve(output.toString());
});
});
}
}
exports.HttpClientResponse = HttpClientResponse;
function isHttps(requestUrl) {
let parsedUrl = new URL(requestUrl);
return parsedUrl.protocol === 'https:';
}
exports.isHttps = isHttps;
class HttpClient {
constructor(userAgent, handlers, requestOptions) {
this._ignoreSslError = false;
this._allowRedirects = true;
this._allowRedirectDowngrade = false;
this._maxRedirects = 50;
this._allowRetries = false;
this._maxRetries = 1;
this._keepAlive = false;
this._disposed = false;
this.userAgent = userAgent;
this.handlers = handlers || [];
this.requestOptions = requestOptions;
if (requestOptions) {
if (requestOptions.ignoreSslError != null) {
this._ignoreSslError = requestOptions.ignoreSslError;
}
this._socketTimeout = requestOptions.socketTimeout;
if (requestOptions.allowRedirects != null) {
this._allowRedirects = requestOptions.allowRedirects;
}
if (requestOptions.allowRedirectDowngrade != null) {
this._allowRedirectDowngrade = requestOptions.allowRedirectDowngrade;
}
if (requestOptions.maxRedirects != null) {
this._maxRedirects = Math.max(requestOptions.maxRedirects, 0);
}
if (requestOptions.keepAlive != null) {
this._keepAlive = requestOptions.keepAlive;
}
if (requestOptions.allowRetries != null) {
this._allowRetries = requestOptions.allowRetries;
}
if (requestOptions.maxRetries != null) {
this._maxRetries = requestOptions.maxRetries;
}
}
}
options(requestUrl, additionalHeaders) {
return this.request('OPTIONS', requestUrl, null, additionalHeaders || {});
}
get(requestUrl, additionalHeaders) {
return this.request('GET', requestUrl, null, additionalHeaders || {});
}
del(requestUrl, additionalHeaders) {
return this.request('DELETE', requestUrl, null, additionalHeaders || {});
}
post(requestUrl, data, additionalHeaders) {
return this.request('POST', requestUrl, data, additionalHeaders || {});
}
patch(requestUrl, data, additionalHeaders) {
return this.request('PATCH', requestUrl, data, additionalHeaders || {});
}
put(requestUrl, data, additionalHeaders) {
return this.request('PUT', requestUrl, data, additionalHeaders || {});
}
head(requestUrl, additionalHeaders) {
return this.request('HEAD', requestUrl, null, additionalHeaders || {});
}
sendStream(verb, requestUrl, stream, additionalHeaders) {
return this.request(verb, requestUrl, stream, additionalHeaders);
}
/**
* Gets a typed object from an endpoint
* Be aware that not found returns a null. Other errors (4xx, 5xx) reject the promise
*/
async getJson(requestUrl, additionalHeaders = {}) {
additionalHeaders[Headers.Accept] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.Accept, MediaTypes.ApplicationJson);
let res = await this.get(requestUrl, additionalHeaders);
return this._processResponse(res, this.requestOptions);
}
async postJson(requestUrl, obj, additionalHeaders = {}) {
let data = JSON.stringify(obj, null, 2);
additionalHeaders[Headers.Accept] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.Accept, MediaTypes.ApplicationJson);
additionalHeaders[Headers.ContentType] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.ContentType, MediaTypes.ApplicationJson);
let res = await this.post(requestUrl, data, additionalHeaders);
return this._processResponse(res, this.requestOptions);
}
async putJson(requestUrl, obj, additionalHeaders = {}) {
let data = JSON.stringify(obj, null, 2);
additionalHeaders[Headers.Accept] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.Accept, MediaTypes.ApplicationJson);
additionalHeaders[Headers.ContentType] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.ContentType, MediaTypes.ApplicationJson);
let res = await this.put(requestUrl, data, additionalHeaders);
return this._processResponse(res, this.requestOptions);
}
async patchJson(requestUrl, obj, additionalHeaders = {}) {
let data = JSON.stringify(obj, null, 2);
additionalHeaders[Headers.Accept] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.Accept, MediaTypes.ApplicationJson);
additionalHeaders[Headers.ContentType] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.ContentType, MediaTypes.ApplicationJson);
let res = await this.patch(requestUrl, data, additionalHeaders);
return this._processResponse(res, this.requestOptions);
}
/**
* Makes a raw http request.
* All other methods such as get, post, patch, and request ultimately call this.
* Prefer get, del, post and patch
*/
async request(verb, requestUrl, data, headers) {
if (this._disposed) {
throw new Error('Client has already been disposed.');
}
let parsedUrl = new URL(requestUrl);
let info = this._prepareRequest(verb, parsedUrl, headers);
// Only perform retries on reads since writes may not be idempotent.
let maxTries = this._allowRetries && RetryableHttpVerbs.indexOf(verb) != -1
? this._maxRetries + 1
: 1;
let numTries = 0;
let response;
while (numTries < maxTries) {
response = await this.requestRaw(info, data);
// Check if it's an authentication challenge
if (response &&
response.message &&
response.message.statusCode === HttpCodes.Unauthorized) {
let authenticationHandler;
for (let i = 0; i < this.handlers.length; i++) {
if (this.handlers[i].canHandleAuthentication(response)) {
authenticationHandler = this.handlers[i];
break;
}
}
if (authenticationHandler) {
return authenticationHandler.handleAuthentication(this, info, data);
}
else {
// We have received an unauthorized response but have no handlers to handle it.
// Let the response return to the caller.
return response;
}
}
let redirectsRemaining = this._maxRedirects;
while (HttpRedirectCodes.indexOf(response.message.statusCode) != -1 &&
this._allowRedirects &&
redirectsRemaining > 0) {
const redirectUrl = response.message.headers['location'];
if (!redirectUrl) {
// if there's no location to redirect to, we won't
break;
}
let parsedRedirectUrl = new URL(redirectUrl);
if (parsedUrl.protocol == 'https:' &&
parsedUrl.protocol != parsedRedirectUrl.protocol &&
!this._allowRedirectDowngrade) {
throw new Error('Redirect from HTTPS to HTTP protocol. This downgrade is not allowed for security reasons. If you want to allow this behavior, set the allowRedirectDowngrade option to true.');
}
// we need to finish reading the response before reassigning response
// which will leak the open socket.
await response.readBody();
// strip authorization header if redirected to a different hostname
if (parsedRedirectUrl.hostname !== parsedUrl.hostname) {
for (let header in headers) {
// header names are case insensitive
if (header.toLowerCase() === 'authorization') {
delete headers[header];
}
}
}
// let's make the request with the new redirectUrl
info = this._prepareRequest(verb, parsedRedirectUrl, headers);
response = await this.requestRaw(info, data);
redirectsRemaining--;
}
if (HttpResponseRetryCodes.indexOf(response.message.statusCode) == -1) {
// If not a retry code, return immediately instead of retrying
return response;
}
numTries += 1;
if (numTries < maxTries) {
await response.readBody();
await this._performExponentialBackoff(numTries);
}
}
return response;
}
/**
* Needs to be called if keepAlive is set to true in request options.
*/
dispose() {
if (this._agent) {
this._agent.destroy();
}
this._disposed = true;
}
/**
* Raw request.
* @param info
* @param data
*/
requestRaw(info, data) {
return new Promise((resolve, reject) => {
let callbackForResult = function (err, res) {
if (err) {
reject(err);
}
resolve(res);
};
this.requestRawWithCallback(info, data, callbackForResult);
});
}
/**
* Raw request with callback.
* @param info
* @param data
* @param onResult
*/
requestRawWithCallback(info, data, onResult) {
let socket;
if (typeof data === 'string') {
info.options.headers['Content-Length'] = Buffer.byteLength(data, 'utf8');
}
let callbackCalled = false;
let handleResult = (err, res) => {
if (!callbackCalled) {
callbackCalled = true;
onResult(err, res);
}
};
let req = info.httpModule.request(info.options, (msg) => {
let res = new HttpClientResponse(msg);
handleResult(null, res);
});
req.on('socket', sock => {
socket = sock;
});
// If we ever get disconnected, we want the socket to timeout eventually
req.setTimeout(this._socketTimeout || 3 * 60000, () => {
if (socket) {
socket.end();
}
handleResult(new Error('Request timeout: ' + info.options.path), null);
});
req.on('error', function (err) {
// err has statusCode property
// res should have headers
handleResult(err, null);
});
if (data && typeof data === 'string') {
req.write(data, 'utf8');
}
if (data && typeof data !== 'string') {
data.on('close', function () {
req.end();
});
data.pipe(req);
}
else {
req.end();
}
}
/**
* Gets an http agent. This function is useful when you need an http agent that handles
* routing through a proxy server - depending upon the url and proxy environment variables.
* @param serverUrl The server URL where the request will be sent. For example, https://api.github.com
*/
getAgent(serverUrl) {
let parsedUrl = new URL(serverUrl);
return this._getAgent(parsedUrl);
}
_prepareRequest(method, requestUrl, headers) {
const info = {};
info.parsedUrl = requestUrl;
const usingSsl = info.parsedUrl.protocol === 'https:';
info.httpModule = usingSsl ? https : http;
const defaultPort = usingSsl ? 443 : 80;
info.options = {};
info.options.host = info.parsedUrl.hostname;
info.options.port = info.parsedUrl.port
? parseInt(info.parsedUrl.port)
: defaultPort;
info.options.path =
(info.parsedUrl.pathname || '') + (info.parsedUrl.search || '');
info.options.method = method;
info.options.headers = this._mergeHeaders(headers);
if (this.userAgent != null) {
info.options.headers['user-agent'] = this.userAgent;
}
info.options.agent = this._getAgent(info.parsedUrl);
// gives handlers an opportunity to participate
if (this.handlers) {
this.handlers.forEach(handler => {
handler.prepareRequest(info.options);
});
}
return info;
}
_mergeHeaders(headers) {
const lowercaseKeys = obj => Object.keys(obj).reduce((c, k) => ((c[k.toLowerCase()] = obj[k]), c), {});
if (this.requestOptions && this.requestOptions.headers) {
return Object.assign({}, lowercaseKeys(this.requestOptions.headers), lowercaseKeys(headers));
}
return lowercaseKeys(headers || {});
}
_getExistingOrDefaultHeader(additionalHeaders, header, _default) {
const lowercaseKeys = obj => Object.keys(obj).reduce((c, k) => ((c[k.toLowerCase()] = obj[k]), c), {});
let clientHeader;
if (this.requestOptions && this.requestOptions.headers) {
clientHeader = lowercaseKeys(this.requestOptions.headers)[header];
}
return additionalHeaders[header] || clientHeader || _default;
}
_getAgent(parsedUrl) {
let agent;
let proxyUrl = pm.getProxyUrl(parsedUrl);
let useProxy = proxyUrl && proxyUrl.hostname;
if (this._keepAlive && useProxy) {
agent = this._proxyAgent;
}
if (this._keepAlive && !useProxy) {
agent = this._agent;
}
// if agent is already assigned use that agent.
if (!!agent) {
return agent;
}
const usingSsl = parsedUrl.protocol === 'https:';
let maxSockets = 100;
if (!!this.requestOptions) {
maxSockets = this.requestOptions.maxSockets || http.globalAgent.maxSockets;
}
if (useProxy) {
// If using proxy, need tunnel
if (!tunnel) {
tunnel = require('tunnel');
}
const agentOptions = {
maxSockets: maxSockets,
keepAlive: this._keepAlive,
proxy: {
...((proxyUrl.username || proxyUrl.password) && {
proxyAuth: `${proxyUrl.username}:${proxyUrl.password}`
}),
host: proxyUrl.hostname,
port: proxyUrl.port
}
};
let tunnelAgent;
const overHttps = proxyUrl.protocol === 'https:';
if (usingSsl) {
tunnelAgent = overHttps ? tunnel.httpsOverHttps : tunnel.httpsOverHttp;
}
else {
tunnelAgent = overHttps ? tunnel.httpOverHttps : tunnel.httpOverHttp;
}
agent = tunnelAgent(agentOptions);
this._proxyAgent = agent;
}
// if reusing agent across request and tunneling agent isn't assigned create a new agent
if (this._keepAlive && !agent) {
const options = { keepAlive: this._keepAlive, maxSockets: maxSockets };
agent = usingSsl ? new https.Agent(options) : new http.Agent(options);
this._agent = agent;
}
// if not using private agent and tunnel agent isn't setup then use global agent
if (!agent) {
agent = usingSsl ? https.globalAgent : http.globalAgent;
}
if (usingSsl && this._ignoreSslError) {
// we don't want to set NODE_TLS_REJECT_UNAUTHORIZED=0 since that will affect request for entire process
// http.RequestOptions doesn't expose a way to modify RequestOptions.agent.options
// we have to cast it to any and change it directly
agent.options = Object.assign(agent.options || {}, {
rejectUnauthorized: false
});
}
return agent;
}
_performExponentialBackoff(retryNumber) {
retryNumber = Math.min(ExponentialBackoffCeiling, retryNumber);
const ms = ExponentialBackoffTimeSlice * Math.pow(2, retryNumber);
return new Promise(resolve => setTimeout(() => resolve(), ms));
}
static dateTimeDeserializer(key, value) {
if (typeof value === 'string') {
let a = new Date(value);
if (!isNaN(a.valueOf())) {
return a;
}
}
return value;
}
async _processResponse(res, options) {
return new Promise(async (resolve, reject) => {
const statusCode = res.message.statusCode;
const response = {
statusCode: statusCode,
result: null,
headers: {}
};
// not found leads to null obj returned
if (statusCode == HttpCodes.NotFound) {
resolve(response);
}
let obj;
let contents;
// get the result from the body
try {
contents = await res.readBody();
if (contents && contents.length > 0) {
if (options && options.deserializeDates) {
obj = JSON.parse(contents, HttpClient.dateTimeDeserializer);
}
else {
obj = JSON.parse(contents);
}
response.result = obj;
}
response.headers = res.message.headers;
}
catch (err) {
// Invalid resource (contents not json); leaving result obj null
}
// note that 3xx redirects are handled by the http layer.
if (statusCode > 299) {
let msg;
// if exception/error in body, attempt to get better error
if (obj && obj.message) {
msg = obj.message;
}
else if (contents && contents.length > 0) {
// it may be the case that the exception is in the body message as string
msg = contents;
}
else {
msg = 'Failed request: (' + statusCode + ')';
}
let err = new HttpClientError(msg, statusCode);
err.result = response.result;
reject(err);
}
else {
resolve(response);
}
});
}
}
exports.HttpClient = HttpClient;

49
node_modules/@actions/http-client/interfaces.d.ts generated vendored Normal file
View File

@ -0,0 +1,49 @@
/// <reference types="node" />
import http = require('http');
export interface IHeaders {
[key: string]: any;
}
export interface IHttpClient {
options(requestUrl: string, additionalHeaders?: IHeaders): Promise<IHttpClientResponse>;
get(requestUrl: string, additionalHeaders?: IHeaders): Promise<IHttpClientResponse>;
del(requestUrl: string, additionalHeaders?: IHeaders): Promise<IHttpClientResponse>;
post(requestUrl: string, data: string, additionalHeaders?: IHeaders): Promise<IHttpClientResponse>;
patch(requestUrl: string, data: string, additionalHeaders?: IHeaders): Promise<IHttpClientResponse>;
put(requestUrl: string, data: string, additionalHeaders?: IHeaders): Promise<IHttpClientResponse>;
sendStream(verb: string, requestUrl: string, stream: NodeJS.ReadableStream, additionalHeaders?: IHeaders): Promise<IHttpClientResponse>;
request(verb: string, requestUrl: string, data: string | NodeJS.ReadableStream, headers: IHeaders): Promise<IHttpClientResponse>;
requestRaw(info: IRequestInfo, data: string | NodeJS.ReadableStream): Promise<IHttpClientResponse>;
requestRawWithCallback(info: IRequestInfo, data: string | NodeJS.ReadableStream, onResult: (err: any, res: IHttpClientResponse) => void): void;
}
export interface IRequestHandler {
prepareRequest(options: http.RequestOptions): void;
canHandleAuthentication(response: IHttpClientResponse): boolean;
handleAuthentication(httpClient: IHttpClient, requestInfo: IRequestInfo, objs: any): Promise<IHttpClientResponse>;
}
export interface IHttpClientResponse {
message: http.IncomingMessage;
readBody(): Promise<string>;
}
export interface IRequestInfo {
options: http.RequestOptions;
parsedUrl: URL;
httpModule: any;
}
export interface IRequestOptions {
headers?: IHeaders;
socketTimeout?: number;
ignoreSslError?: boolean;
allowRedirects?: boolean;
allowRedirectDowngrade?: boolean;
maxRedirects?: number;
maxSockets?: number;
keepAlive?: boolean;
deserializeDates?: boolean;
allowRetries?: boolean;
maxRetries?: number;
}
export interface ITypedResponse<T> {
statusCode: number;
result: T | null;
headers: Object;
}

2
node_modules/@actions/http-client/interfaces.js generated vendored Normal file
View File

@ -0,0 +1,2 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });

39
node_modules/@actions/http-client/package.json generated vendored Normal file
View File

@ -0,0 +1,39 @@
{
"name": "@actions/http-client",
"version": "1.0.11",
"description": "Actions Http Client",
"main": "index.js",
"scripts": {
"build": "rm -Rf ./_out && tsc && cp package*.json ./_out && cp *.md ./_out && cp LICENSE ./_out && cp actions.png ./_out",
"test": "jest",
"format": "prettier --write *.ts && prettier --write **/*.ts",
"format-check": "prettier --check *.ts && prettier --check **/*.ts",
"audit-check": "npm audit --audit-level=moderate"
},
"repository": {
"type": "git",
"url": "git+https://github.com/actions/http-client.git"
},
"keywords": [
"Actions",
"Http"
],
"author": "GitHub, Inc.",
"license": "MIT",
"bugs": {
"url": "https://github.com/actions/http-client/issues"
},
"homepage": "https://github.com/actions/http-client#readme",
"devDependencies": {
"@types/jest": "^25.1.4",
"@types/node": "^12.12.31",
"jest": "^25.1.0",
"prettier": "^2.0.4",
"proxy": "^1.0.1",
"ts-jest": "^25.2.1",
"typescript": "^3.8.3"
},
"dependencies": {
"tunnel": "0.0.6"
}
}

2
node_modules/@actions/http-client/proxy.d.ts generated vendored Normal file
View File

@ -0,0 +1,2 @@
export declare function getProxyUrl(reqUrl: URL): URL | undefined;
export declare function checkBypass(reqUrl: URL): boolean;

57
node_modules/@actions/http-client/proxy.js generated vendored Normal file
View File

@ -0,0 +1,57 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
function getProxyUrl(reqUrl) {
let usingSsl = reqUrl.protocol === 'https:';
let proxyUrl;
if (checkBypass(reqUrl)) {
return proxyUrl;
}
let proxyVar;
if (usingSsl) {
proxyVar = process.env['https_proxy'] || process.env['HTTPS_PROXY'];
}
else {
proxyVar = process.env['http_proxy'] || process.env['HTTP_PROXY'];
}
if (proxyVar) {
proxyUrl = new URL(proxyVar);
}
return proxyUrl;
}
exports.getProxyUrl = getProxyUrl;
function checkBypass(reqUrl) {
if (!reqUrl.hostname) {
return false;
}
let noProxy = process.env['no_proxy'] || process.env['NO_PROXY'] || '';
if (!noProxy) {
return false;
}
// Determine the request port
let reqPort;
if (reqUrl.port) {
reqPort = Number(reqUrl.port);
}
else if (reqUrl.protocol === 'http:') {
reqPort = 80;
}
else if (reqUrl.protocol === 'https:') {
reqPort = 443;
}
// Format the request hostname and hostname with port
let upperReqHosts = [reqUrl.hostname.toUpperCase()];
if (typeof reqPort === 'number') {
upperReqHosts.push(`${upperReqHosts[0]}:${reqPort}`);
}
// Compare request host against noproxy
for (let upperNoProxyItem of noProxy
.split(',')
.map(x => x.trim().toUpperCase())
.filter(x => x)) {
if (upperReqHosts.some(x => x === upperNoProxyItem)) {
return true;
}
}
return false;
}
exports.checkBypass = checkBypass;

361
node_modules/@xmldom/xmldom/CHANGELOG.md generated vendored Normal file
View File

@ -0,0 +1,361 @@
# Changelog
All notable changes to this project will be documented in this file.
This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## [0.8.1](https://github.com/xmldom/xmldom/compare/0.8.0...0.8.1)
### Fixes
- Only use own properties in entityMap [`#374`](https://github.com/xmldom/xmldom/pull/374)
### Docs
- Add security policy [`#365`](https://github.com/xmldom/xmldom/pull/365)
- changelog: Correct contributor name and link [`#366`](https://github.com/xmldom/xmldom/pull/366)
- Describe release/publish steps [`#358`](https://github.com/xmldom/xmldom/pull/358), [`#376`](https://github.com/xmldom/xmldom/pull/376)
- Add snyk package health badge [`#360`](https://github.com/xmldom/xmldom/pull/360)
## [0.8.0](https://github.com/xmldom/xmldom/compare/0.7.5...0.8.0)
### Fixed
- Normalize all line endings according to XML specs [1.0](https://w3.org/TR/xml/#sec-line-ends) and [1.1](https://www.w3.org/TR/xml11/#sec-line-ends) \
BREAKING CHANGE: Certain combination of line break characters are normalized to a single `\n` before parsing takes place and will no longer be preserved.
- [`#303`](https://github.com/xmldom/xmldom/issues/303) / [`#307`](https://github.com/xmldom/xmldom/pull/307)
- [`#49`](https://github.com/xmldom/xmldom/issues/49), [`#97`](https://github.com/xmldom/xmldom/issues/97), [`#324`](https://github.com/xmldom/xmldom/issues/324) / [`#314`](https://github.com/xmldom/xmldom/pull/314)
- XMLSerializer: Preserve whitespace character references [`#284`](https://github.com/xmldom/xmldom/issues/284) / [`#310`](https://github.com/xmldom/xmldom/pull/310) \
BREAKING CHANGE: If you relied on the not spec compliant preservation of literal `\t`, `\n` or `\r` in **attribute values**.
To preserve those you will have to create XML that instead contains the correct numerical (or hexadecimal) equivalent (e.g. `&#x9;`, `&#xA;`, `&#xD;`).
- Drop deprecated exports `DOMImplementation` and `XMLSerializer` from `lib/dom-parser.js` [#53](https://github.com/xmldom/xmldom/issues/53) / [`#309`](https://github.com/xmldom/xmldom/pull/309)
BREAKING CHANGE: Use the one provided by the main package export.
- dom: Remove all links as part of `removeChild` [`#343`](https://github.com/xmldom/xmldom/issues/343) / [`#355`](https://github.com/xmldom/xmldom/pull/355)
### Chore
- ci: Restore latest tested node version to 16.x [`#325`](https://github.com/xmldom/xmldom/pull/325)
- ci: Split test and lint steps into jobs [`#111`](https://github.com/xmldom/xmldom/issues/111) / [`#304`](https://github.com/xmldom/xmldom/pull/304)
- Pinned and updated devDependencies
Thank you [@marrus-sh](https://github.com/marrus-sh), [@victorandree](https://github.com/victorandree), [@mdierolf](https://github.com/mdierolf), [@tsabbay](https://github.com/tsabbay), [@fatihpense](https://github.com/fatihpense) for your contributions
## 0.7.5
[Commits](https://github.com/xmldom/xmldom/compare/0.7.4...0.7.5)
### Fixes:
- Preserve default namespace when serializing [`#319`](https://github.com/xmldom/xmldom/issues/319) / [`#321`](https://github.com/xmldom/xmldom/pull/321)
Thank you [@lupestro](https://github.com/lupestro)
## 0.7.4
[Commits](https://github.com/xmldom/xmldom/compare/0.7.3...0.7.4)
### Fixes:
- Restore ability to parse `__prototype__` attributes [`#315`](https://github.com/xmldom/xmldom/pull/315)
Thank you [@dsimpsonOMF](https://github.com/dsimpsonOMF)
## 0.7.3
[Commits](https://github.com/xmldom/xmldom/compare/0.7.2...0.7.3)
### Fixes:
- Add doctype when parsing from string [`#277`](https://github.com/xmldom/xmldom/issues/277) / [`#301`](https://github.com/xmldom/xmldom/pull/301)
- Correct typo in error message [`#294`](https://github.com/xmldom/xmldom/pull/294)
Thank you [@rrthomas](https://github.com/rrthomas)
### Refactor:
- Improve exports & require statements, new main package entry [`#233`](https://github.com/xmldom/xmldom/pull/233)
### Docs:
- Fix Stryker badge [`#298`](https://github.com/xmldom/xmldom/pull/298)
- Fix link to help-wanted issues [`#299`](https://github.com/xmldom/xmldom/pull/299)
### Chore:
- Execute stryker:dry-run on branches [`#302`](https://github.com/xmldom/xmldom/pull/302)
- Fix stryker config [`#300`](https://github.com/xmldom/xmldom/pull/300)
- Split test and lint scripts [`#297`](https://github.com/xmldom/xmldom/pull/297)
- Switch to stryker dashboard owned by org [`#292`](https://github.com/xmldom/xmldom/pull/292)
## 0.7.2
[Commits](https://github.com/xmldom/xmldom/compare/0.7.1...0.7.2)
### Fixes:
- Types: Add index.d.ts to packaged files [`#288`](https://github.com/xmldom/xmldom/pull/288)
Thank you [@forty](https://github.com/forty)
## 0.7.1
[Commits](https://github.com/xmldom/xmldom/compare/0.7.0...0.7.1)
### Fixes:
- Types: Copy types from DefinitelyTyped [`#283`](https://github.com/xmldom/xmldom/pull/283)
Thank you [@kachkaev](https://github.com/kachkaev)
### Chore:
- package.json: remove author, maintainers, etc. [`#279`](https://github.com/xmldom/xmldom/pull/279)
## 0.7.0
[Commits](https://github.com/xmldom/xmldom/compare/0.6.0...0.7.0)
Due to [`#271`](https://github.com/xmldom/xmldom/issue/271) this version was published as
- unscoped `xmldom` package to github (git tags [`0.7.0`](https://github.com/xmldom/xmldom/tree/0.7.0) and [`0.7.0+unscoped`](https://github.com/xmldom/xmldom/tree/0.7.0%2Bunscoped))
- scoped `@xmldom/xmldom` package to npm (git tag `0.7.0+scoped`)
For more details look at [`#278`](https://github.com/xmldom/xmldom/pull/278#issuecomment-902172483)
### Fixes:
- Security: Misinterpretation of malicious XML input [`CVE-2021-32796`](https://github.com/xmldom/xmldom/security/advisories/GHSA-5fg8-2547-mr8q)
- Implement `Document.getElementsByClassName` as specified [`#213`](https://github.com/xmldom/xmldom/pull/213), thank you [@ChALkeR](https://github.com/ChALkeR)
- Inherit namespace prefix from parent when required [`#268`](https://github.com/xmldom/xmldom/pull/268)
- Handle whitespace in closing tags [`#267`](https://github.com/xmldom/xmldom/pull/267)
- Update `DOMImplementation` according to recent specs [`#210`](https://github.com/xmldom/xmldom/pull/210)
BREAKING CHANGE: Only if you "passed features to be marked as available as a constructor arguments" and expected it to "magically work".
- No longer serializes any namespaces with an empty URI [`#244`](https://github.com/xmldom/xmldom/pull/244)
(related to [`#168`](https://github.com/xmldom/xmldom/pull/168) released in 0.6.0)
BREAKING CHANGE: Only if you rely on ["unsetting" a namespace prefix](https://github.com/xmldom/xmldom/pull/168#issuecomment-886984994) by setting it to an empty string
- Set `localName` as part of `Document.createElement` [`#229`](https://github.com/xmldom/xmldom/pull/229), thank you [@rrthomas](https://github.com/rrthomas)
### CI
- We are now additionally running tests against node v16
- Stryker tests on the master branch now run against node v14
### Docs
- Describe relations with and between specs: [`#211`](https://github.com/xmldom/xmldom/pull/211), [`#247`](https://github.com/xmldom/xmldom/pull/247)
## 0.6.0
[Commits](https://github.com/xmldom/xmldom/compare/0.5.0...0.6.0)
### Fixes
- Stop serializing empty namespace values like `xmlns:ds=""` [`#168`](https://github.com/xmldom/xmldom/pull/168)
BREAKING CHANGE: If your code expected empty namespaces attributes to be serialized.
Thank you [@pdecat](https://github.com/pdecat) and [@FranckDepoortere](https://github.com/FranckDepoortere)
- Escape `<` to `&lt;` when serializing attribute values [`#198`](https://github.com/xmldom/xmldom/issues/198) / [`#199`](https://github.com/xmldom/xmldom/pull/199)
## 0.5.0
[Commits](https://github.com/xmldom/xmldom/compare/0.4.0...0.5.0)
### Fixes
- Avoid misinterpretation of malicious XML input - [`GHSA-h6q6-9hqw-rwfv`](https://github.com/xmldom/xmldom/security/advisories/GHSA-h6q6-9hqw-rwfv) (CVE-2021-21366)
- Improve error reporting; throw on duplicate attribute\
BREAKING CHANGE: It is currently not clear how to consistently deal with duplicate attributes, so it's also safer for our users to fail when detecting them.
It's possible to configure the `DOMParser.errorHandler` before parsing, to handle those errors differently.
To accomplish this and also be able to verify it in tests I needed to
- create a new `Error` type `ParseError` and export it
- Throw `ParseError` from `errorHandler.fatalError` and prevent those from being caught in `XMLReader`.
- export `DOMHandler` constructor as `__DOMHandler`
- Preserve quotes in DOCTYPE declaration
Since the only purpose of parsing the DOCTYPE is to be able to restore it when serializing, we decided that it would be best to leave the parsed `publicId` and `systemId` as is, including any quotes.
BREAKING CHANGE: If somebody relies on the actual unquoted values of those ids, they will need to take care of either single or double quotes and the right escaping.
(Without this change this would not have been possible because the SAX parser already dropped the information about the quotes that have been used in the source.)
https://www.w3.org/TR/2006/REC-xml11-20060816/#dtd
https://www.w3.org/TR/2006/REC-xml11-20060816/#IDAX1KS (External Entity Declaration)
- Fix breaking preprocessors' directives when parsing attributes [`#171`](https://github.com/xmldom/xmldom/pull/171)
- fix(dom): Escape `]]&gt;` when serializing CharData [`#181`](https://github.com/xmldom/xmldom/pull/181)
- Switch to (only) MIT license (drop problematic LGPL license option) [`#178`](https://github.com/xmldom/xmldom/pull/178)
- Export DOMException; remove custom assertions; etc. [`#174`](https://github.com/xmldom/xmldom/pull/174)
### Docs
- Update MDN links in `readme.md` [`#188`](https://github.com/xmldom/xmldom/pull/188)
## 0.4.0
[Commits](https://github.com/xmldom/xmldom/compare/0.3.0...0.4.0)
### Fixes
- **BREAKING** Restore `&nbsp;` behavior from v0.1.27 [`#67`](https://github.com/xmldom/xmldom/pull/67)
- **BREAKING** Typecheck source param before parsing [`#113`](https://github.com/xmldom/xmldom/pull/113)
- Include documents in package files list [`#156`](https://github.com/xmldom/xmldom/pull/156)
- Preserve doctype with sysid [`#144`](https://github.com/xmldom/xmldom/pull/144)
- Remove ES6 syntax from getElementsByClassName [`#91`](https://github.com/xmldom/xmldom/pull/91)
- Revert "Add lowercase of åäö in entityMap" due to duplicate entries [`#84`](https://github.com/xmldom/xmldom/pull/84)
- fix: Convert all line separators to LF [`#66`](https://github.com/xmldom/xmldom/pull/66)
### Docs
- Update CHANGELOG.md through version 0.3.0 [`#63`](https://github.com/xmldom/xmldom/pull/63)
- Update badges [`#78`](https://github.com/xmldom/xmldom/pull/78)
- Add .editorconfig file [`#104`](https://github.com/xmldom/xmldom/pull/104)
- Add note about import [`#79`](https://github.com/xmldom/xmldom/pull/79)
- Modernize & improve the example in readme.md [`#81`](https://github.com/xmldom/xmldom/pull/81)
### CI
- Add Stryker Mutator [`#70`](https://github.com/xmldom/xmldom/pull/70)
- Add Stryker action to update dashboard [`#77`](https://github.com/xmldom/xmldom/pull/77)
- Add Node GitHub action workflow [`#64`](https://github.com/xmldom/xmldom/pull/64)
- add & enable eslint [`#106`](https://github.com/xmldom/xmldom/pull/106)
- Use eslint-plugin-es5 to enforce ES5 syntax [`#107`](https://github.com/xmldom/xmldom/pull/107)
- Recover `vows` tests, drop `proof` tests [`#59`](https://github.com/xmldom/xmldom/pull/59)
- Add jest tessuite and first tests [`#114`](https://github.com/xmldom/xmldom/pull/114)
- Add jest testsuite with `xmltest` cases [`#112`](https://github.com/xmldom/xmldom/pull/112)
- Configure Renovate [`#108`](https://github.com/xmldom/xmldom/pull/108)
- Test European HTML entities [`#86`](https://github.com/xmldom/xmldom/pull/86)
- Updated devDependencies
### Other
- Remove files that are not of any use [`#131`](https://github.com/xmldom/xmldom/pull/131), [`#65`](https://github.com/xmldom/xmldom/pull/65), [`#33`](https://github.com/xmldom/xmldom/pull/33)
## 0.3.0
[Commits](https://github.com/xmldom/xmldom/compare/0.2.1...0.3.0)
- **BREAKING** Node >=10.x is now required.
- **BREAKING** Remove `component.json` (deprecated package manager https://github.com/componentjs/guide)
- **BREAKING** Move existing sources into `lib` subdirectory.
- **POSSIBLY BREAKING** Introduce `files` entry in `package.json` and remove use of `.npmignore`.
- [Add `Document.getElementsByClassName`](https://github.com/xmldom/xmldom/issues/24).
- [Add `Node` to the list of exports](https://github.com/xmldom/xmldom/pull/27)
- [Add lowercase of åäö in `entityMap`](https://github.com/xmldom/xmldom/pull/23).
- Move CHANGELOG to markdown file.
- Move LICENSE to markdown file.
## 0.2.1
[Commits](https://github.com/xmldom/xmldom/compare/0.2.0...0.2.1)
- Correct `homepage`, `repository` and `bugs` URLs in `package.json`.
## 0.2.0
[Commits](https://github.com/xmldom/xmldom/compare/v0.1.27...0.2.0)
- Includes all **BREAKING** changes introduced in [`xmldom-alpha@v0.1.28`](#0128) by the original authors.
- **POSSIBLY BREAKING** [remove the `Object.create` check from the `_extends` method of `dom.js` that added a `__proto__` property](https://github.com/xmldom/xmldom/commit/0be2ae910a8a22c9ec2cac042e04de4c04317d2a#diff-7d1c5d97786fdf9af5446a241d0b6d56L19-L22) ().
- **POSSIBLY BREAKING** [remove code that added a `__proto__` property](https://github.com/xmldom/xmldom/commit/366159a76a181ce9a0d83f5dc48205686cfaf9cc)
- formatting/corrections in `package.json`
## 0.1.31
[Commits](https://github.com/xmldom/xmldom/compare/v0.1.27...v0.1.31)
The patch versions (`v0.1.29` - `v0.1.31`) that have been released on the [v0.1.x branch](https://github.com/xmldom/xmldom/tree/0.1.x), to reflect the changed maintainers, **are branched off from [`v0.1.27`](#0127) so they don't include the breaking changes introduced in [`xmldom-alpha@v0.1.28`](#0128)**:
## Maintainer changes
After the last commit to the original repository <https://github.com/jindw/xmldom> on the 9th of May 2017, the first commit to <https://github.com/xmldom/xmldom> is from the 19th of December 2019. [The fork has been announced in the original repository on the 2nd of March 2020.](https://github.com/jindw/xmldom/issues/259)
The versions listed below have been published to one or both of the following packages:
- <https://www.npmjs.com/package/xmldom-alpha>
- <https://www.npmjs.com/package/xmldom>
It is currently not planned to continue publishing the `xmldom-alpha` package.
The new maintainers did not invest time to understand changes that led to the last `xmldom` version [`0.1.27`](#0127) published by the original maintainer, but consider it the basis for their work.
A timeline of all the changes that happened from that version until `0.3.0` is available in <https://github.com/xmldom/xmldom/issues/62>. Any related questions should be asked there.
## 0.1.28
[Commits](https://github.com/xmldom/xmldom/compare/v0.1.27...xmldom-alpha@v0.1.28)
Published by @jindw on the 9th of May 2017 as
- `xmldom-alpha@0.1.28`
- **BREAKING** includes [regression regarding `&nbsp;` (issue #57)](https://github.com/xmldom/xmldom/issues/57)
- [Fix `license` field in `package.json`](https://github.com/jindw/xmldom/pull/178)
- [Conditional converting of HTML entities](https://github.com/jindw/xmldom/pull/80)
- Fix `dom.js` serialization issue for missing document element ([example that failed on `toString()` before this change](https://github.com/xmldom/xmldom/blob/a58dcf7a265522e80ce520fe3be0cddb1b976f6f/test/parse/unclosedcomment.js#L10-L11))
- Add new module `entities.js`
## 0.1.27
Published by @jindw on the 28th of Nov 2016 as
- `xmldom@0.1.27`
- `xmldom-alpha@0.1.27`
- Various bug fixes.
## 0.1.26
Published on the 18th of Nov 2016
as `xmldom@0.1.26`
- Details unknown
## 0.1.25
Published on the 18th of Nov 2016 as
- `xmldom@0.1.25`
- Details unknown
## 0.1.24
Published on the 27th of November 2016 as
- `xmldom@0.1.24`
- `xmldom-alpha@0.1.24`
- Added node filter.
## 0.1.23
Published on the 5th of May 2016 as
- `xmldom-alpha@0.1.23`
- Add namespace support for nest node serialize.
- Various other bug fixes.
## 0.1.22
- Merge XMLNS serialization.
- Remove \r from source string.
- Print namespaces for child elements.
- Switch references to nodeType to use named constants.
- Add nodelist toString support.
## 0.1.21
- Fix serialize bug.
## 0.1.20
- Optimize invalid XML support.
- Add toString sorter for attributes output.
- Add html self closed node button.
- Add `*` NS support for getElementsByTagNameNS.
- Convert attribute's value to string in setAttributeNS.
- Add support for HTML entities for HTML docs only.
- Fix TypeError when Document is created with DocumentType.
## 0.1.19
- Fix [infinite loop on unclosed comment (jindw/xmldom#68)](https://github.com/jindw/xmldom/issues/68)
- Add error report for unclosed tag.
- Various other fixes.
## 0.1.18
- Add default `ns` support.
- parseFromString now renders entirely plain text documents as textNode.
- Enable option to ignore white space on parsing.
## 0.1.17
**Details missing for this and potential earlier version**
## 0.1.16
- Correctly handle multibyte Unicode greater than two byts. #57. #56.
- Initial unit testing and test coverage. #53. #46. #19.
- Create Bower `component.json` #52.
## 0.1.8
- Add: some test case from node-o3-xml(excludes xpath support)
- Fix: remove existed attribute before setting (bug introduced in v0.1.5)
- Fix: index direct access for childNodes and any NodeList collection(not w3c standard)
- Fix: remove last child bug

8
node_modules/@xmldom/xmldom/LICENSE generated vendored Normal file
View File

@ -0,0 +1,8 @@
Copyright 2019 - present Christopher J. Brody and other contributors, as listed in: https://github.com/xmldom/xmldom/graphs/contributors
Copyright 2012 - 2017 @jindw <jindw@xidea.org> and other contributors, as listed in: https://github.com/jindw/xmldom/graphs/contributors
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

50
node_modules/@xmldom/xmldom/SECURITY.md generated vendored Normal file
View File

@ -0,0 +1,50 @@
# Security Policy
The most up-to-date version of this document can be found at <https://github.com/xmldom/xmldom/security/policy>.
## Supported Versions
This repository contains the code for the libraries `xmldom` and `@xmldom/xmldom` on npm.
As long as we didn't publish v1, we aim to maintain the last two minor versions with security fixes. If it is possible we provide security fixes as path versions.
If you think there is a good reason to also patch an earlier version let us know in a github issue or the release discussion once the fix has been provided.
The maintainers will consider it and if we agree and have/find the required resources, a patch for that version will be provided.
Please notice that [we are no longer able to publish the (unscoped) `xmldom` package](https://github.com/xmldom/xmldom/issues/271),
and that all existing versions of `xmldom` are affected by at least one security vulnerability and should be considered deprecated.
You can still report issues regarding `xmldom` as described below.
If you need help with migrating from `xmldom` to `@xmldom/xmldom`, file a github issue or PR in the affected repository and mention @karfau.
## Reporting vulnerabilities
Please email reports about any security related issues you find to `security@xmldom.org`, which will forward it to the list of maintainers.
The maintainers will try to respond within 7 calendar days. (If nobody peplies after 7 days, please us send a reminder!)
As part of you communication please make sure to always hit "Reply all", so all maintainers are kept in the loop.
In addition, please include the following information along with your report:
- Your name and affiliation (if any).
- A description of the technical details of the vulnerabilities. It is very important to let us know how we can reproduce your findings.
- An explanation who can exploit this vulnerability, and what they gain when doing so -- write an attack scenario. This will help us evaluate your report quickly, especially if the issue is complex.
- Whether this vulnerability public or known to third parties. If it is, please provide details.
If you believe that an existing (public) issue is security-related, please send an email to `security@xmldom.org`.
The email should include the issue URL and a short description of why it should be handled according to this security policy.
Once an issue is reported, the maintainers use the following disclosure process:
- When a report is received, we confirm the issue, determine its severity and the affected versions.
- If we know of specific third-party services or software based on xmldom that require mitigation before publication, those projects will be notified.
- A [github security advisory](https://docs.github.com/en/code-security/security-advisories/about-github-security-advisories) is [created](https://docs.github.com/en/code-security/security-advisories/creating-a-security-advisory) (but not published) which details the problem and steps for mitigation.
- If the reporter provides a github account and agrees to it, we (add that github account as a collaborator on the advisuory)[https://docs.github.com/en/code-security/security-advisories/adding-a-collaborator-to-a-security-advisory].
- The vulnerability is fixed in a [private fork](https://docs.github.com/en/code-security/security-advisories/collaborating-in-a-temporary-private-fork-to-resolve-a-security-vulnerability) and potential workarounds are identified.
- The maintainers audit the existing code to find any potential similar problems.
- The release for the current minor version and the [security advisory are published](https://docs.github.com/en/code-security/security-advisories/publishing-a-security-advisory).
- The release(s) for previous minor version(s) are published.
We credit reporters for identifying security issues, if they confirm that they want to.
## Known vulnerabilities
See https://github.com/xmldom/xmldom/security/advisories?state=published

43
node_modules/@xmldom/xmldom/index.d.ts generated vendored Normal file
View File

@ -0,0 +1,43 @@
/// <reference lib="dom" />
declare module "@xmldom/xmldom" {
var DOMParser: DOMParserStatic;
var XMLSerializer: XMLSerializerStatic;
var DOMImplementation: DOMImplementationStatic;
interface DOMImplementationStatic {
new(): DOMImplementation;
}
interface DOMParserStatic {
new (): DOMParser;
new (options: Options): DOMParser;
}
interface XMLSerializerStatic {
new (): XMLSerializer;
}
interface DOMParser {
parseFromString(xmlsource: string, mimeType?: string): Document;
}
interface XMLSerializer {
serializeToString(node: Node): string;
}
interface Options {
locator?: any;
errorHandler?: ErrorHandlerFunction | ErrorHandlerObject | undefined;
}
interface ErrorHandlerFunction {
(level: string, msg: any): any;
}
interface ErrorHandlerObject {
warning?: ((msg: any) => any) | undefined;
error?: ((msg: any) => any) | undefined;
fatalError?: ((msg: any) => any) | undefined;
}
}

2
node_modules/@xmldom/xmldom/lib/.eslintrc.yml generated vendored Normal file
View File

@ -0,0 +1,2 @@
extends:
- 'plugin:es5/no-es2015'

144
node_modules/@xmldom/xmldom/lib/conventions.js generated vendored Normal file
View File

@ -0,0 +1,144 @@
'use strict'
/**
* "Shallow freezes" an object to render it immutable.
* Uses `Object.freeze` if available,
* otherwise the immutability is only in the type.
*
* Is used to create "enum like" objects.
*
* @template T
* @param {T} object the object to freeze
* @param {Pick<ObjectConstructor, 'freeze'> = Object} oc `Object` by default,
* allows to inject custom object constructor for tests
* @returns {Readonly<T>}
*
* @see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/freeze
*/
function freeze(object, oc) {
if (oc === undefined) {
oc = Object
}
return oc && typeof oc.freeze === 'function' ? oc.freeze(object) : object
}
/**
* All mime types that are allowed as input to `DOMParser.parseFromString`
*
* @see https://developer.mozilla.org/en-US/docs/Web/API/DOMParser/parseFromString#Argument02 MDN
* @see https://html.spec.whatwg.org/multipage/dynamic-markup-insertion.html#domparsersupportedtype WHATWG HTML Spec
* @see DOMParser.prototype.parseFromString
*/
var MIME_TYPE = freeze({
/**
* `text/html`, the only mime type that triggers treating an XML document as HTML.
*
* @see DOMParser.SupportedType.isHTML
* @see https://www.iana.org/assignments/media-types/text/html IANA MimeType registration
* @see https://en.wikipedia.org/wiki/HTML Wikipedia
* @see https://developer.mozilla.org/en-US/docs/Web/API/DOMParser/parseFromString MDN
* @see https://html.spec.whatwg.org/multipage/dynamic-markup-insertion.html#dom-domparser-parsefromstring WHATWG HTML Spec
*/
HTML: 'text/html',
/**
* Helper method to check a mime type if it indicates an HTML document
*
* @param {string} [value]
* @returns {boolean}
*
* @see https://www.iana.org/assignments/media-types/text/html IANA MimeType registration
* @see https://en.wikipedia.org/wiki/HTML Wikipedia
* @see https://developer.mozilla.org/en-US/docs/Web/API/DOMParser/parseFromString MDN
* @see https://html.spec.whatwg.org/multipage/dynamic-markup-insertion.html#dom-domparser-parsefromstring */
isHTML: function (value) {
return value === MIME_TYPE.HTML
},
/**
* `application/xml`, the standard mime type for XML documents.
*
* @see https://www.iana.org/assignments/media-types/application/xml IANA MimeType registration
* @see https://tools.ietf.org/html/rfc7303#section-9.1 RFC 7303
* @see https://en.wikipedia.org/wiki/XML_and_MIME Wikipedia
*/
XML_APPLICATION: 'application/xml',
/**
* `text/html`, an alias for `application/xml`.
*
* @see https://tools.ietf.org/html/rfc7303#section-9.2 RFC 7303
* @see https://www.iana.org/assignments/media-types/text/xml IANA MimeType registration
* @see https://en.wikipedia.org/wiki/XML_and_MIME Wikipedia
*/
XML_TEXT: 'text/xml',
/**
* `application/xhtml+xml`, indicates an XML document that has the default HTML namespace,
* but is parsed as an XML document.
*
* @see https://www.iana.org/assignments/media-types/application/xhtml+xml IANA MimeType registration
* @see https://dom.spec.whatwg.org/#dom-domimplementation-createdocument WHATWG DOM Spec
* @see https://en.wikipedia.org/wiki/XHTML Wikipedia
*/
XML_XHTML_APPLICATION: 'application/xhtml+xml',
/**
* `image/svg+xml`,
*
* @see https://www.iana.org/assignments/media-types/image/svg+xml IANA MimeType registration
* @see https://www.w3.org/TR/SVG11/ W3C SVG 1.1
* @see https://en.wikipedia.org/wiki/Scalable_Vector_Graphics Wikipedia
*/
XML_SVG_IMAGE: 'image/svg+xml',
})
/**
* Namespaces that are used in this code base.
*
* @see http://www.w3.org/TR/REC-xml-names
*/
var NAMESPACE = freeze({
/**
* The XHTML namespace.
*
* @see http://www.w3.org/1999/xhtml
*/
HTML: 'http://www.w3.org/1999/xhtml',
/**
* Checks if `uri` equals `NAMESPACE.HTML`.
*
* @param {string} [uri]
*
* @see NAMESPACE.HTML
*/
isHTML: function (uri) {
return uri === NAMESPACE.HTML
},
/**
* The SVG namespace.
*
* @see http://www.w3.org/2000/svg
*/
SVG: 'http://www.w3.org/2000/svg',
/**
* The `xml:` namespace.
*
* @see http://www.w3.org/XML/1998/namespace
*/
XML: 'http://www.w3.org/XML/1998/namespace',
/**
* The `xmlns:` namespace
*
* @see https://www.w3.org/2000/xmlns/
*/
XMLNS: 'http://www.w3.org/2000/xmlns/',
})
exports.freeze = freeze;
exports.MIME_TYPE = MIME_TYPE;
exports.NAMESPACE = NAMESPACE;

View File

@ -1,3 +1,73 @@
var conventions = require("./conventions");
var dom = require('./dom')
var entities = require('./entities');
var sax = require('./sax');
var DOMImplementation = dom.DOMImplementation;
var NAMESPACE = conventions.NAMESPACE;
var ParseError = sax.ParseError;
var XMLReader = sax.XMLReader;
/**
* Normalizes line ending according to https://www.w3.org/TR/xml11/#sec-line-ends:
*
* > XML parsed entities are often stored in computer files which,
* > for editing convenience, are organized into lines.
* > These lines are typically separated by some combination
* > of the characters CARRIAGE RETURN (#xD) and LINE FEED (#xA).
* >
* > To simplify the tasks of applications, the XML processor must behave
* > as if it normalized all line breaks in external parsed entities (including the document entity)
* > on input, before parsing, by translating all of the following to a single #xA character:
* >
* > 1. the two-character sequence #xD #xA
* > 2. the two-character sequence #xD #x85
* > 3. the single character #x85
* > 4. the single character #x2028
* > 5. any #xD character that is not immediately followed by #xA or #x85.
*
* @param {string} input
* @returns {string}
*/
function normalizeLineEndings(input) {
return input
.replace(/\r[\n\u0085]/g, '\n')
.replace(/[\r\u0085\u2028]/g, '\n')
}
/**
* @typedef Locator
* @property {number} [columnNumber]
* @property {number} [lineNumber]
*/
/**
* @typedef DOMParserOptions
* @property {DOMHandler} [domBuilder]
* @property {Function} [errorHandler]
* @property {(string) => string} [normalizeLineEndings] used to replace line endings before parsing
* defaults to `normalizeLineEndings`
* @property {Locator} [locator]
* @property {Record<string, string>} [xmlns]
*
* @see normalizeLineEndings
*/
/**
* The DOMParser interface provides the ability to parse XML or HTML source code
* from a string into a DOM `Document`.
*
* _xmldom is different from the spec in that it allows an `options` parameter,
* to override the default behavior._
*
* @param {DOMParserOptions} [options]
* @constructor
*
* @see https://developer.mozilla.org/en-US/docs/Web/API/DOMParser
* @see https://html.spec.whatwg.org/multipage/dynamic-markup-insertion.html#dom-parsing-and-serialization
*/
function DOMParser(options){
this.options = options ||{locator:{}};
}
@ -10,7 +80,7 @@ DOMParser.prototype.parseFromString = function(source,mimeType){
var locator = options.locator;
var defaultNSMap = options.xmlns||{};
var isHTML = /\/x?html?$/.test(mimeType);//mimeType.toLowerCase().indexOf('html') > -1;
var entityMap = isHTML?htmlEntity.entityMap:{'lt':'<','gt':'>','amp':'&','quot':'"','apos':"'"};
var entityMap = isHTML ? entities.HTML_ENTITIES : entities.XML_ENTITIES;
if(locator){
domBuilder.setDocumentLocator(locator)
}
@ -18,13 +88,18 @@ DOMParser.prototype.parseFromString = function(source,mimeType){
sax.errorHandler = buildErrorHandler(errorHandler,domBuilder,locator);
sax.domBuilder = options.domBuilder || domBuilder;
if(isHTML){
defaultNSMap['']= 'http://www.w3.org/1999/xhtml';
defaultNSMap[''] = NAMESPACE.HTML;
}
defaultNSMap.xml = defaultNSMap.xml || 'http://www.w3.org/XML/1998/namespace';
if(source){
sax.parse(source,defaultNSMap,entityMap);
}else{
sax.errorHandler.error("invalid doc source");
defaultNSMap.xml = defaultNSMap.xml || NAMESPACE.XML;
var normalize = options.normalizeLineEndings || normalizeLineEndings;
if (source && typeof source === 'string') {
sax.parse(
normalize(source),
defaultNSMap,
entityMap
)
} else {
sax.errorHandler.error('invalid doc source')
}
return domBuilder.doc;
}
@ -165,6 +240,7 @@ DOMHandler.prototype = {
var dt = impl.createDocumentType(name, publicId, systemId);
this.locator && position(this.locator,dt)
appendElement(this, dt);
this.doc.doctype = dt;
}
},
/**
@ -178,8 +254,7 @@ DOMHandler.prototype = {
console.error('[xmldom error]\t'+error,_locator(this.locator));
},
fatalError:function(error) {
console.error('[xmldom fatalError]\t'+error,_locator(this.locator));
throw error;
throw new ParseError(error, this.locator);
}
}
function _locator(l){
@ -242,10 +317,6 @@ function appendElement (hander,node) {
}
}//appendChild and setAttributeNS are preformance key
//if(typeof require == 'function'){
var htmlEntity = require('./entities');
var XMLReader = require('./sax').XMLReader;
var DOMImplementation = exports.DOMImplementation = require('./dom').DOMImplementation;
exports.XMLSerializer = require('./dom').XMLSerializer ;
exports.__DOMHandler = DOMHandler;
exports.normalizeLineEndings = normalizeLineEndings;
exports.DOMParser = DOMParser;
//}

View File

@ -1,15 +1,71 @@
/*
* DOM Level 2
* Object DOMException
* @see http://www.w3.org/TR/REC-DOM-Level-1/ecma-script-language-binding.html
* @see http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/ecma-script-binding.html
var conventions = require("./conventions");
var NAMESPACE = conventions.NAMESPACE;
/**
* A prerequisite for `[].filter`, to drop elements that are empty
* @param {string} input
* @returns {boolean}
*/
function notEmptyString (input) {
return input !== ''
}
/**
* @see https://infra.spec.whatwg.org/#split-on-ascii-whitespace
* @see https://infra.spec.whatwg.org/#ascii-whitespace
*
* @param {string} input
* @returns {string[]} (can be empty)
*/
function splitOnASCIIWhitespace(input) {
// U+0009 TAB, U+000A LF, U+000C FF, U+000D CR, U+0020 SPACE
return input ? input.split(/[\t\n\f\r ]+/).filter(notEmptyString) : []
}
/**
* Adds element as a key to current if it is not already present.
*
* @param {Record<string, boolean | undefined>} current
* @param {string} element
* @returns {Record<string, boolean | undefined>}
*/
function orderedSetReducer (current, element) {
if (!current.hasOwnProperty(element)) {
current[element] = true;
}
return current;
}
/**
* @see https://infra.spec.whatwg.org/#ordered-set
* @param {string} input
* @returns {string[]}
*/
function toOrderedSet(input) {
if (!input) return [];
var list = splitOnASCIIWhitespace(input);
return Object.keys(list.reduce(orderedSetReducer, {}))
}
/**
* Uses `list.indexOf` to implement something like `Array.prototype.includes`,
* which we can not rely on being available.
*
* @param {any[]} list
* @returns {function(any): boolean}
*/
function arrayIncludes (list) {
return function(element) {
return list && list.indexOf(element) !== -1;
}
}
function copy(src,dest){
for(var p in src){
dest[p] = src[p];
}
}
/**
^\w+\.prototype\.([_\w]+)\s*=\s*((?:.*\{\s*?[\r\n][\s\S]*?^})|\S.*?(?=[;\r\n]));?
^\w+\.prototype\.([_\w]+)\s*=\s*(\S.*?(?=[;\r\n]));?
@ -25,12 +81,12 @@ function _extends(Class,Super){
}
if(pt.constructor != Class){
if(typeof Class != 'function'){
console.error("unknow Class:"+Class)
console.error("unknown Class:"+Class)
}
pt.constructor = Class
}
}
var htmlns = 'http://www.w3.org/1999/xhtml' ;
// Node Types
var NodeType = {}
var ELEMENT_NODE = NodeType.ELEMENT_NODE = 1;
@ -66,7 +122,12 @@ var INVALID_MODIFICATION_ERR = ExceptionCode.INVALID_MODIFICATION_ERR = ((Exce
var NAMESPACE_ERR = ExceptionCode.NAMESPACE_ERR = ((ExceptionMessage[14]="Invalid namespace"),14);
var INVALID_ACCESS_ERR = ExceptionCode.INVALID_ACCESS_ERR = ((ExceptionMessage[15]="Invalid access"),15);
/**
* DOM Level 2
* Object DOMException
* @see http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/ecma-script-binding.html
* @see http://www.w3.org/TR/REC-DOM-Level-1/ecma-script-language-binding.html
*/
function DOMException(code, message) {
if(message instanceof Error){
var error = message;
@ -82,6 +143,7 @@ function DOMException(code, message) {
};
DOMException.prototype = Error.prototype;
copy(ExceptionCode,DOMException)
/**
* @see http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-536297177
* The NodeList interface provides the abstraction of an ordered collection of nodes, without defining or constraining how this collection is implemented. NodeList objects in the DOM are live.
@ -113,6 +175,7 @@ NodeList.prototype = {
return buf.join('');
}
};
function LiveNodeList(node,refresh){
this._node = node;
this._refresh = refresh
@ -134,9 +197,15 @@ LiveNodeList.prototype.item = function(i){
}
_extends(LiveNodeList,NodeList);
/**
*
* Objects implementing the NamedNodeMap interface are used to represent collections of nodes that can be accessed by name. Note that NamedNodeMap does not inherit from NodeList; NamedNodeMaps are not maintained in any particular order. Objects contained in an object implementing NamedNodeMap may also be accessed by an ordinal index, but this is simply to allow convenient enumeration of the contents of a NamedNodeMap, and does not imply that the DOM specifies an order to these Nodes.
* Objects implementing the NamedNodeMap interface are used
* to represent collections of nodes that can be accessed by name.
* Note that NamedNodeMap does not inherit from NodeList;
* NamedNodeMaps are not maintained in any particular order.
* Objects contained in an object implementing NamedNodeMap may also be accessed by an ordinal index,
* but this is simply to allow convenient enumeration of the contents of a NamedNodeMap,
* and does not imply that the DOM specifies an order to these Nodes.
* NamedNodeMap objects in the DOM are live.
* used for attributes or DocumentType entities
*/
@ -248,55 +317,108 @@ NamedNodeMap.prototype = {
return null;
}
};
/**
* @see http://www.w3.org/TR/REC-DOM-Level-1/level-one-core.html#ID-102161490
* The DOMImplementation interface represents an object providing methods
* which are not dependent on any particular document.
* Such an object is returned by the `Document.implementation` property.
*
* __The individual methods describe the differences compared to the specs.__
*
* @constructor
*
* @see https://developer.mozilla.org/en-US/docs/Web/API/DOMImplementation MDN
* @see https://www.w3.org/TR/REC-DOM-Level-1/level-one-core.html#ID-102161490 DOM Level 1 Core (Initial)
* @see https://www.w3.org/TR/DOM-Level-2-Core/core.html#ID-102161490 DOM Level 2 Core
* @see https://www.w3.org/TR/DOM-Level-3-Core/core.html#ID-102161490 DOM Level 3 Core
* @see https://dom.spec.whatwg.org/#domimplementation DOM Living Standard
*/
function DOMImplementation(/* Object */ features) {
this._features = {};
if (features) {
for (var feature in features) {
this._features = features[feature];
}
}
};
function DOMImplementation() {
}
DOMImplementation.prototype = {
hasFeature: function(/* string */ feature, /* string */ version) {
var versions = this._features[feature.toLowerCase()];
if (versions && (!version || version in versions)) {
/**
* The DOMImplementation.hasFeature() method returns a Boolean flag indicating if a given feature is supported.
* The different implementations fairly diverged in what kind of features were reported.
* The latest version of the spec settled to force this method to always return true, where the functionality was accurate and in use.
*
* @deprecated It is deprecated and modern browsers return true in all cases.
*
* @param {string} feature
* @param {string} [version]
* @returns {boolean} always true
*
* @see https://developer.mozilla.org/en-US/docs/Web/API/DOMImplementation/hasFeature MDN
* @see https://www.w3.org/TR/REC-DOM-Level-1/level-one-core.html#ID-5CED94D7 DOM Level 1 Core
* @see https://dom.spec.whatwg.org/#dom-domimplementation-hasfeature DOM Living Standard
*/
hasFeature: function(feature, version) {
return true;
} else {
return false;
}
},
// Introduced in DOM Level 2:
createDocument:function(namespaceURI, qualifiedName, doctype){// raises:INVALID_CHARACTER_ERR,NAMESPACE_ERR,WRONG_DOCUMENT_ERR
/**
* Creates an XML Document object of the specified type with its document element.
*
* __It behaves slightly different from the description in the living standard__:
* - There is no interface/class `XMLDocument`, it returns a `Document` instance.
* - `contentType`, `encoding`, `mode`, `origin`, `url` fields are currently not declared.
* - this implementation is not validating names or qualified names
* (when parsing XML strings, the SAX parser takes care of that)
*
* @param {string|null} namespaceURI
* @param {string} qualifiedName
* @param {DocumentType=null} doctype
* @returns {Document}
*
* @see https://developer.mozilla.org/en-US/docs/Web/API/DOMImplementation/createDocument MDN
* @see https://www.w3.org/TR/DOM-Level-2-Core/core.html#Level-2-Core-DOM-createDocument DOM Level 2 Core (initial)
* @see https://dom.spec.whatwg.org/#dom-domimplementation-createdocument DOM Level 2 Core
*
* @see https://dom.spec.whatwg.org/#validate-and-extract DOM: Validate and extract
* @see https://www.w3.org/TR/xml/#NT-NameStartChar XML Spec: Names
* @see https://www.w3.org/TR/xml-names/#ns-qualnames XML Namespaces: Qualified names
*/
createDocument: function(namespaceURI, qualifiedName, doctype){
var doc = new Document();
doc.implementation = this;
doc.childNodes = new NodeList();
doc.doctype = doctype;
if(doctype){
doc.doctype = doctype || null;
if (doctype){
doc.appendChild(doctype);
}
if(qualifiedName){
var root = doc.createElementNS(namespaceURI,qualifiedName);
if (qualifiedName){
var root = doc.createElementNS(namespaceURI, qualifiedName);
doc.appendChild(root);
}
return doc;
},
// Introduced in DOM Level 2:
createDocumentType:function(qualifiedName, publicId, systemId){// raises:INVALID_CHARACTER_ERR,NAMESPACE_ERR
/**
* Returns a doctype, with the given `qualifiedName`, `publicId`, and `systemId`.
*
* __This behavior is slightly different from the in the specs__:
* - this implementation is not validating names or qualified names
* (when parsing XML strings, the SAX parser takes care of that)
*
* @param {string} qualifiedName
* @param {string} [publicId]
* @param {string} [systemId]
* @returns {DocumentType} which can either be used with `DOMImplementation.createDocument` upon document creation
* or can be put into the document via methods like `Node.insertBefore()` or `Node.replaceChild()`
*
* @see https://developer.mozilla.org/en-US/docs/Web/API/DOMImplementation/createDocumentType MDN
* @see https://www.w3.org/TR/DOM-Level-2-Core/core.html#Level-2-Core-DOM-createDocType DOM Level 2 Core
* @see https://dom.spec.whatwg.org/#dom-domimplementation-createdocumenttype DOM Living Standard
*
* @see https://dom.spec.whatwg.org/#validate-and-extract DOM: Validate and extract
* @see https://www.w3.org/TR/xml/#NT-NameStartChar XML Spec: Names
* @see https://www.w3.org/TR/xml-names/#ns-qualnames XML Namespaces: Qualified names
*/
createDocumentType: function(qualifiedName, publicId, systemId){
var node = new DocumentType();
node.name = qualifiedName;
node.nodeName = qualifiedName;
node.publicId = publicId;
node.systemId = systemId;
// Introduced in DOM Level 2:
//readonly attribute DOMString internalSubset;
//TODO:..
// readonly attribute NamedNodeMap entities;
// readonly attribute NamedNodeMap notations;
node.publicId = publicId || '';
node.systemId = systemId || '';
return node;
}
};
@ -366,6 +488,20 @@ Node.prototype = {
hasAttributes:function(){
return this.attributes.length>0;
},
/**
* Look up the prefix associated to the given namespace URI, starting from this node.
* **The default namespace declarations are ignored by this method.**
* See Namespace Prefix Lookup for details on the algorithm used by this method.
*
* _Note: The implementation seems to be incomplete when compared to the algorithm described in the specs._
*
* @param {string | null} namespaceURI
* @returns {string | null}
* @see https://www.w3.org/TR/DOM-Level-3-Core/core.html#Node3-lookupNamespacePrefix
* @see https://www.w3.org/TR/DOM-Level-3-Core/namespaces-algorithms.html#lookupNamespacePrefixAlgo
* @see https://dom.spec.whatwg.org/#dom-node-lookupprefix
* @see https://github.com/xmldom/xmldom/issues/322
*/
lookupPrefix:function(namespaceURI){
var el = this;
while(el){
@ -436,64 +572,86 @@ function _visitNode(node,callback){
function Document(){
}
function _onAddAttribute(doc,el,newAttr){
doc && doc._inc++;
var ns = newAttr.namespaceURI ;
if(ns == 'http://www.w3.org/2000/xmlns/'){
if(ns === NAMESPACE.XMLNS){
//update namespace
el._nsMap[newAttr.prefix?newAttr.localName:''] = newAttr.value
}
}
function _onRemoveAttribute(doc,el,newAttr,remove){
doc && doc._inc++;
var ns = newAttr.namespaceURI ;
if(ns == 'http://www.w3.org/2000/xmlns/'){
if(ns === NAMESPACE.XMLNS){
//update namespace
delete el._nsMap[newAttr.prefix?newAttr.localName:'']
}
}
function _onUpdateChild(doc,el,newChild){
/**
* Updates `el.childNodes`, updating the indexed items and it's `length`.
* Passing `newChild` means it will be appended.
* Otherwise it's assumed that an item has been removed,
* and `el.firstNode` and it's `.nextSibling` are used
* to walk the current list of child nodes.
*
* @param {Document} doc
* @param {Node} el
* @param {Node} [newChild]
* @private
*/
function _onUpdateChild (doc, el, newChild) {
if(doc && doc._inc){
doc._inc++;
//update childNodes
var cs = el.childNodes;
if(newChild){
if (newChild) {
cs[cs.length++] = newChild;
}else{
//console.log(1)
} else {
var child = el.firstChild;
var i = 0;
while(child){
while (child) {
cs[i++] = child;
child =child.nextSibling;
child = child.nextSibling;
}
cs.length = i;
delete cs[cs.length];
}
}
}
/**
* attributes;
* children;
*
* writeable properties:
* nodeValue,Attr:value,CharacterData:data
* prefix
* Removes the connections between `parentNode` and `child`
* and any existing `child.previousSibling` or `child.nextSibling`.
*
* @see https://github.com/xmldom/xmldom/issues/135
* @see https://github.com/xmldom/xmldom/issues/145
*
* @param {Node} parentNode
* @param {Node} child
* @returns {Node} the child that was removed.
* @private
*/
function _removeChild(parentNode,child){
function _removeChild (parentNode, child) {
var previous = child.previousSibling;
var next = child.nextSibling;
if(previous){
if (previous) {
previous.nextSibling = next;
}else{
parentNode.firstChild = next
} else {
parentNode.firstChild = next;
}
if(next){
if (next) {
next.previousSibling = previous;
}else{
} else {
parentNode.lastChild = previous;
}
_onUpdateChild(parentNode.ownerDocument,parentNode);
child.parentNode = null;
child.previousSibling = null;
child.nextSibling = null;
_onUpdateChild(parentNode.ownerDocument, parentNode);
return child;
}
/**
@ -539,36 +697,50 @@ function _insertBefore(parentNode,newChild,nextChild){
}
return newChild;
}
function _appendSingleChild(parentNode,newChild){
var cp = newChild.parentNode;
if(cp){
var pre = parentNode.lastChild;
cp.removeChild(newChild);//remove and update
var pre = parentNode.lastChild;
/**
* Appends `newChild` to `parentNode`.
* If `newChild` is already connected to a `parentNode` it is first removed from it.
*
* @see https://github.com/xmldom/xmldom/issues/135
* @see https://github.com/xmldom/xmldom/issues/145
* @param {Node} parentNode
* @param {Node} newChild
* @returns {Node}
* @private
*/
function _appendSingleChild (parentNode, newChild) {
if (newChild.parentNode) {
newChild.parentNode.removeChild(newChild);
}
var pre = parentNode.lastChild;
newChild.parentNode = parentNode;
newChild.previousSibling = pre;
newChild.previousSibling = parentNode.lastChild;
newChild.nextSibling = null;
if(pre){
pre.nextSibling = newChild;
}else{
if (newChild.previousSibling) {
newChild.previousSibling.nextSibling = newChild;
} else {
parentNode.firstChild = newChild;
}
parentNode.lastChild = newChild;
_onUpdateChild(parentNode.ownerDocument,parentNode,newChild);
_onUpdateChild(parentNode.ownerDocument, parentNode, newChild);
return newChild;
//console.log("__aa",parentNode.lastChild.nextSibling == null)
}
Document.prototype = {
//implementation : null,
nodeName : '#document',
nodeType : DOCUMENT_NODE,
/**
* The DocumentType node of the document.
*
* @readonly
* @type DocumentType
*/
doctype : null,
documentElement : null,
_inc : 1,
insertBefore : function(newChild, refChild){//raises
insertBefore : function(newChild, refChild){//raises
if(newChild.nodeType == DOCUMENT_FRAGMENT_NODE){
var child = newChild.firstChild;
while(child){
@ -581,7 +753,7 @@ Document.prototype = {
if(this.documentElement == null && newChild.nodeType == ELEMENT_NODE){
this.documentElement = newChild;
}
return _insertBefore(this,newChild,refChild),(newChild.ownerDocument = this),newChild;
},
removeChild : function(oldChild){
@ -607,28 +779,58 @@ Document.prototype = {
})
return rtv;
},
getElementsByClassName: function(className) {
const pattern = new RegExp(`(^|\\s)${className}(\\s|$)`);
return new LiveNodeList(this, base => {
/**
* The `getElementsByClassName` method of `Document` interface returns an array-like object
* of all child elements which have **all** of the given class name(s).
*
* Returns an empty list if `classeNames` is an empty string or only contains HTML white space characters.
*
*
* Warning: This is a live LiveNodeList.
* Changes in the DOM will reflect in the array as the changes occur.
* If an element selected by this array no longer qualifies for the selector,
* it will automatically be removed. Be aware of this for iteration purposes.
*
* @param {string} classNames is a string representing the class name(s) to match; multiple class names are separated by (ASCII-)whitespace
*
* @see https://developer.mozilla.org/en-US/docs/Web/API/Document/getElementsByClassName
* @see https://dom.spec.whatwg.org/#concept-getelementsbyclassname
*/
getElementsByClassName: function(classNames) {
var classNamesSet = toOrderedSet(classNames)
return new LiveNodeList(this, function(base) {
var ls = [];
_visitNode(base.documentElement, node => {
if(node !== base && node.nodeType == ELEMENT_NODE) {
if(pattern.test(node.getAttribute('class'))) {
ls.push(node);
if (classNamesSet.length > 0) {
_visitNode(base.documentElement, function(node) {
if(node !== base && node.nodeType === ELEMENT_NODE) {
var nodeClassNames = node.getAttribute('class')
// can be null if the attribute does not exist
if (nodeClassNames) {
// before splitting and iterating just compare them for the most common case
var matches = classNames === nodeClassNames;
if (!matches) {
var nodeClassNamesSet = toOrderedSet(nodeClassNames)
matches = classNamesSet.every(arrayIncludes(nodeClassNamesSet))
}
if(matches) {
ls.push(node);
}
}
}
}
});
});
}
return ls;
});
},
//document factory method:
createElement : function(tagName){
var node = new Element();
node.ownerDocument = this;
node.nodeName = tagName;
node.tagName = tagName;
node.localName = tagName;
node.childNodes = new NodeList();
var attrs = node.attributes = new NamedNodeMap();
attrs._ownerElement = node;
@ -946,36 +1148,55 @@ function nodeSerializeToString(isHtml,nodeFilter){
//console.log('###',this.nodeType,uri,prefix,buf.join(''))
return buf.join('');
}
function needNamespaceDefine(node,isHTML, visibleNamespaces) {
var prefix = node.prefix||'';
function needNamespaceDefine(node, isHTML, visibleNamespaces) {
var prefix = node.prefix || '';
var uri = node.namespaceURI;
if (!prefix && !uri){
// According to [Namespaces in XML 1.0](https://www.w3.org/TR/REC-xml-names/#ns-using) ,
// and more specifically https://www.w3.org/TR/REC-xml-names/#nsc-NoPrefixUndecl :
// > In a namespace declaration for a prefix [...], the attribute value MUST NOT be empty.
// in a similar manner [Namespaces in XML 1.1](https://www.w3.org/TR/xml-names11/#ns-using)
// and more specifically https://www.w3.org/TR/xml-names11/#nsc-NSDeclared :
// > [...] Furthermore, the attribute value [...] must not be an empty string.
// so serializing empty namespace value like xmlns:ds="" would produce an invalid XML document.
if (!uri) {
return false;
}
if (prefix === "xml" && uri === "http://www.w3.org/XML/1998/namespace"
|| uri == 'http://www.w3.org/2000/xmlns/'){
if (prefix === "xml" && uri === NAMESPACE.XML || uri === NAMESPACE.XMLNS) {
return false;
}
var i = visibleNamespaces.length
//console.log('@@@@',node.tagName,prefix,uri,visibleNamespaces)
while (i--) {
var ns = visibleNamespaces[i];
// get namespace prefix
//console.log(node.nodeType,node.tagName,ns.prefix,prefix)
if (ns.prefix == prefix){
return ns.namespace != uri;
if (ns.prefix === prefix) {
return ns.namespace !== uri;
}
}
//console.log(isHTML,uri,prefix=='')
//if(isHTML && prefix ==null && uri == 'http://www.w3.org/1999/xhtml'){
// return false;
//}
//node.flag = '11111'
//console.error(3,true,node.flag,node.prefix,node.namespaceURI)
return true;
}
/**
* Well-formed constraint: No < in Attribute Values
* > The replacement text of any entity referred to directly or indirectly
* > in an attribute value must not contain a <.
* @see https://www.w3.org/TR/xml11/#CleanAttrVals
* @see https://www.w3.org/TR/xml11/#NT-AttValue
*
* Literal whitespace other than space that appear in attribute values
* are serialized as their entity references, so they will be preserved.
* (In contrast to whitespace literals in the input which are normalized to spaces)
* @see https://www.w3.org/TR/xml11/#AVNormalize
*/
function addSerializedAttribute(buf, qualifiedName, value) {
buf.push(' ', qualifiedName, '="', value.replace(/[<&"\t\n\r]/g, _xmlEncoder), '"')
}
function serializeToString(node,buf,isHTML,nodeFilter,visibleNamespaces){
if (!visibleNamespaces) {
visibleNamespaces = [];
}
if(nodeFilter){
node = nodeFilter(node);
if(node){
@ -988,20 +1209,51 @@ function serializeToString(node,buf,isHTML,nodeFilter,visibleNamespaces){
}
//buf.sort.apply(attrs, attributeSorter);
}
switch(node.nodeType){
case ELEMENT_NODE:
if (!visibleNamespaces) visibleNamespaces = [];
var startVisibleNamespaces = visibleNamespaces.length;
var attrs = node.attributes;
var len = attrs.length;
var child = node.firstChild;
var nodeName = node.tagName;
isHTML = (htmlns === node.namespaceURI) ||isHTML
buf.push('<',nodeName);
isHTML = NAMESPACE.isHTML(node.namespaceURI) || isHTML
var prefixedNodeName = nodeName
if (!isHTML && !node.prefix && node.namespaceURI) {
var defaultNS
// lookup current default ns from `xmlns` attribute
for (var ai = 0; ai < attrs.length; ai++) {
if (attrs.item(ai).name === 'xmlns') {
defaultNS = attrs.item(ai).value
break
}
}
if (!defaultNS) {
// lookup current default ns in visibleNamespaces
for (var nsi = visibleNamespaces.length - 1; nsi >= 0; nsi--) {
var namespace = visibleNamespaces[nsi]
if (namespace.prefix === '' && namespace.namespace === node.namespaceURI) {
defaultNS = namespace.namespace
break
}
}
}
if (defaultNS !== node.namespaceURI) {
for (var nsi = visibleNamespaces.length - 1; nsi >= 0; nsi--) {
var namespace = visibleNamespaces[nsi]
if (namespace.namespace === node.namespaceURI) {
if (namespace.prefix) {
prefixedNodeName = namespace.prefix + ':' + nodeName
}
break
}
}
}
}
buf.push('<', prefixedNodeName);
for(var i=0;i<len;i++){
// add namespaces for attributes
var attr = attrs.item(i);
@ -1011,23 +1263,23 @@ function serializeToString(node,buf,isHTML,nodeFilter,visibleNamespaces){
visibleNamespaces.push({ prefix: '', namespace: attr.value });
}
}
for(var i=0;i<len;i++){
var attr = attrs.item(i);
if (needNamespaceDefine(attr,isHTML, visibleNamespaces)) {
var prefix = attr.prefix||'';
var uri = attr.namespaceURI;
var ns = prefix ? ' xmlns:' + prefix : " xmlns";
buf.push(ns, '="' , uri , '"');
addSerializedAttribute(buf, prefix ? 'xmlns:' + prefix : "xmlns", uri);
visibleNamespaces.push({ prefix: prefix, namespace:uri });
}
serializeToString(attr,buf,isHTML,nodeFilter,visibleNamespaces);
}
// add namespace for current node
if (needNamespaceDefine(node,isHTML, visibleNamespaces)) {
if (nodeName === prefixedNodeName && needNamespaceDefine(node, isHTML, visibleNamespaces)) {
var prefix = node.prefix||'';
var uri = node.namespaceURI;
var ns = prefix ? ' xmlns:' + prefix : " xmlns";
buf.push(ns, '="' , uri , '"');
addSerializedAttribute(buf, prefix ? 'xmlns:' + prefix : "xmlns", uri);
visibleNamespaces.push({ prefix: prefix, namespace:uri });
}
@ -1039,18 +1291,18 @@ function serializeToString(node,buf,isHTML,nodeFilter,visibleNamespaces){
if(child.data){
buf.push(child.data);
}else{
serializeToString(child,buf,isHTML,nodeFilter,visibleNamespaces);
serializeToString(child, buf, isHTML, nodeFilter, visibleNamespaces.slice());
}
child = child.nextSibling;
}
}else
{
while(child){
serializeToString(child,buf,isHTML,nodeFilter,visibleNamespaces);
serializeToString(child, buf, isHTML, nodeFilter, visibleNamespaces.slice());
child = child.nextSibling;
}
}
buf.push('</',nodeName,'>');
buf.push('</',prefixedNodeName,'>');
}else{
buf.push('/>');
}
@ -1061,14 +1313,32 @@ function serializeToString(node,buf,isHTML,nodeFilter,visibleNamespaces){
case DOCUMENT_FRAGMENT_NODE:
var child = node.firstChild;
while(child){
serializeToString(child,buf,isHTML,nodeFilter,visibleNamespaces);
serializeToString(child, buf, isHTML, nodeFilter, visibleNamespaces.slice());
child = child.nextSibling;
}
return;
case ATTRIBUTE_NODE:
return buf.push(' ',node.name,'="',node.value.replace(/[<&"]/g,_xmlEncoder),'"');
return addSerializedAttribute(buf, node.name, node.value);
case TEXT_NODE:
return buf.push(node.data.replace(/[<&]/g,_xmlEncoder));
/**
* The ampersand character (&) and the left angle bracket (<) must not appear in their literal form,
* except when used as markup delimiters, or within a comment, a processing instruction, or a CDATA section.
* If they are needed elsewhere, they must be escaped using either numeric character references or the strings
* `&amp;` and `&lt;` respectively.
* The right angle bracket (>) may be represented using the string " &gt; ", and must, for compatibility,
* be escaped using either `&gt;` or a character reference when it appears in the string `]]>` in content,
* when that string is not marking the end of a CDATA section.
*
* In the content of elements, character data is any string of characters
* which does not contain the start-delimiter of any markup
* and does not include the CDATA-section-close delimiter, `]]>`.
*
* @see https://www.w3.org/TR/xml/#NT-CharData
*/
return buf.push(node.data
.replace(/[<&]/g,_xmlEncoder)
.replace(/]]>/g, ']]&gt;')
);
case CDATA_SECTION_NODE:
return buf.push( '<![CDATA[',node.data,']]>');
case COMMENT_NODE:
@ -1078,13 +1348,13 @@ function serializeToString(node,buf,isHTML,nodeFilter,visibleNamespaces){
var sysid = node.systemId;
buf.push('<!DOCTYPE ',node.name);
if(pubid){
buf.push(' PUBLIC "',pubid);
buf.push(' PUBLIC ', pubid);
if (sysid && sysid!='.') {
buf.push( '" "',sysid);
buf.push(' ', sysid);
}
buf.push('">');
buf.push('>');
}else if(sysid && sysid!='.'){
buf.push(' SYSTEM "',sysid,'">');
buf.push(' SYSTEM ', sysid, '>');
}else{
var sub = node.internalSubset;
if(sub){
@ -1200,10 +1470,12 @@ try{
return this.$$length;
}
});
Object.defineProperty(Node.prototype,'textContent',{
get:function(){
return getTextContent(this);
},
set:function(data){
switch(this.nodeType){
case ELEMENT_NODE:
@ -1215,8 +1487,8 @@ try{
this.appendChild(this.ownerDocument.createTextNode(data));
}
break;
default:
//TODO:
this.data = data;
this.value = data;
this.nodeValue = data;
@ -1241,6 +1513,7 @@ try{
return node.nodeValue;
}
}
__set__ = function(object,key,value){
//console.log(value)
object['$$'+key] = value
@ -1250,7 +1523,11 @@ try{
}
//if(typeof require == 'function'){
exports.Node = Node;
exports.DocumentType = DocumentType;
exports.DOMException = DOMException;
exports.DOMImplementation = DOMImplementation;
exports.Element = Element;
exports.Node = Node;
exports.NodeList = NodeList;
exports.XMLSerializer = XMLSerializer;
//}

View File

@ -1,4 +1,28 @@
exports.entityMap = {
var freeze = require('./conventions').freeze;
/**
* The entities that are predefined in every XML document.
*
* @see https://www.w3.org/TR/2006/REC-xml11-20060816/#sec-predefined-ent W3C XML 1.1
* @see https://www.w3.org/TR/2008/REC-xml-20081126/#sec-predefined-ent W3C XML 1.0
* @see https://en.wikipedia.org/wiki/List_of_XML_and_HTML_character_entity_references#Predefined_entities_in_XML Wikipedia
*/
exports.XML_ENTITIES = freeze({amp:'&', apos:"'", gt:'>', lt:'<', quot:'"'})
/**
* A map of currently 241 entities that are detected in an HTML document.
* They contain all entries from `XML_ENTITIES`.
*
* @see XML_ENTITIES
* @see DOMParser.parseFromString
* @see DOMImplementation.prototype.createHTMLDocument
* @see https://html.spec.whatwg.org/#named-character-references WHATWG HTML(5) Spec
* @see https://www.w3.org/TR/xml-entity-names/ W3C XML Entity Names
* @see https://www.w3.org/TR/html4/sgml/entities.html W3C HTML4/SGML
* @see https://en.wikipedia.org/wiki/List_of_XML_and_HTML_character_entity_references#Character_entity_references_in_HTML Wikipedia (HTML)
* @see https://en.wikipedia.org/wiki/List_of_XML_and_HTML_character_entity_references#Entities_representing_special_characters_in_XHTML Wikpedia (XHTML)
*/
exports.HTML_ENTITIES = freeze({
lt: '<',
gt: '>',
amp: '&',
@ -9,9 +33,7 @@ exports.entityMap = {
Acirc: "Â",
Atilde: "Ã",
Auml: "Ä",
auml: "ä",
Aring: "Å",
aring: "å",
AElig: "Æ",
Ccedil: "Ç",
Egrave: "È",
@ -29,7 +51,6 @@ exports.entityMap = {
Ocirc: "Ô",
Otilde: "Õ",
Ouml: "Ö",
ouml: "ö",
Oslash: "Ø",
Ugrave: "Ù",
Uacute: "Ú",
@ -69,7 +90,7 @@ exports.entityMap = {
yacute: "ý",
thorn: "þ",
yuml: "ÿ",
nbsp: " ",
nbsp: "\u00a0",
iexcl: "¡",
cent: "¢",
pound: "£",
@ -243,5 +264,10 @@ exports.entityMap = {
clubs: "♣",
hearts: "♥",
diams: "♦"
};
//for(var n in exports.entityMap){console.log(exports.entityMap[n].charCodeAt())}
});
/**
* @deprecated use `HTML_ENTITIES` instead
* @see HTML_ENTITIES
*/
exports.entityMap = exports.HTML_ENTITIES

4
node_modules/@xmldom/xmldom/lib/index.js generated vendored Normal file
View File

@ -0,0 +1,4 @@
var dom = require('./dom')
exports.DOMImplementation = dom.DOMImplementation
exports.XMLSerializer = dom.XMLSerializer
exports.DOMParser = require('./dom-parser').DOMParser

View File

@ -1,3 +1,5 @@
var NAMESPACE = require("./conventions").NAMESPACE;
//[4] NameStartChar ::= ":" | [A-Z] | "_" | [a-z] | [#xC0-#xD6] | [#xD8-#xF6] | [#xF8-#x2FF] | [#x370-#x37D] | [#x37F-#x1FFF] | [#x200C-#x200D] | [#x2070-#x218F] | [#x2C00-#x2FEF] | [#x3001-#xD7FF] | [#xF900-#xFDCF] | [#xFDF0-#xFFFD] | [#x10000-#xEFFFF]
//[4a] NameChar ::= NameStartChar | "-" | "." | [0-9] | #xB7 | [#x0300-#x036F] | [#x203F-#x2040]
//[5] Name ::= NameStartChar (NameChar)*
@ -10,7 +12,7 @@ var tagNamePattern = new RegExp('^'+nameStartChar.source+nameChar.source+'*(?:\:
//S_TAG, S_ATTR, S_EQ, S_ATTR_NOQUOT_VALUE
//S_ATTR_SPACE, S_ATTR_END, S_TAG_SPACE, S_TAG_CLOSE
var S_TAG = 0;//tag name offerring
var S_ATTR = 1;//attr name offerring
var S_ATTR = 1;//attr name offerring
var S_ATTR_SPACE=2;//attr name end and space offer
var S_EQ = 3;//=space?
var S_ATTR_NOQUOT_VALUE = 4;//attr value(no quot value only)
@ -18,8 +20,23 @@ var S_ATTR_END = 5;//attr value end and no space(quot end)
var S_TAG_SPACE = 6;//(attr value end || tag end ) && (space offer)
var S_TAG_CLOSE = 7;//closed el<el />
/**
* Creates an error that will not be caught by XMLReader aka the SAX parser.
*
* @param {string} message
* @param {any?} locator Optional, can provide details about the location in the source
* @constructor
*/
function ParseError(message, locator) {
this.message = message
this.locator = locator
if(Error.captureStackTrace) Error.captureStackTrace(this, ParseError);
}
ParseError.prototype = new Error();
ParseError.prototype.name = ParseError.name
function XMLReader(){
}
XMLReader.prototype = {
@ -48,8 +65,8 @@ function parse(source,defaultNSMapCopy,entityMap,domBuilder,errorHandler){
}
function entityReplacer(a){
var k = a.slice(1,-1);
if(k in entityMap){
return entityMap[k];
if (Object.hasOwnProperty.call(entityMap, k)) {
return entityMap[k];
}else if(k.charAt(0) === '#'){
return fixedFromCharCode(parseInt(k.substr(1).replace('x','0x')))
}else{
@ -78,7 +95,7 @@ function parse(source,defaultNSMapCopy,entityMap,domBuilder,errorHandler){
var lineEnd = 0;
var linePattern = /.*(?:\r\n?|\n)|.*$/g
var locator = domBuilder.locator;
var parseStack = [{currentNSMap:defaultNSMapCopy}]
var closeMap = {};
var start = 0;
@ -100,12 +117,11 @@ function parse(source,defaultNSMapCopy,entityMap,domBuilder,errorHandler){
switch(source.charAt(tagStart+1)){
case '/':
var end = source.indexOf('>',tagStart+3);
var tagName = source.substring(tagStart+2,end);
var tagName = source.substring(tagStart + 2, end).replace(/[ \t\n\r]+$/g, '');
var config = parseStack.pop();
if(end<0){
tagName = source.substring(tagStart+2).replace(/[\s<].*/,'');
//console.error('#@@@@@@'+tagName)
errorHandler.error("end tag name: "+tagName+' is not complete:'+config.tagName);
end = tagStart+1+tagName.length;
}else if(tagName.match(/\s</)){
@ -113,8 +129,6 @@ function parse(source,defaultNSMapCopy,entityMap,domBuilder,errorHandler){
errorHandler.error("end tag name: "+tagName+' maybe not complete');
end = tagStart+1+tagName.length;
}
//console.error(parseStack.length,parseStack)
//console.error(config);
var localNSMap = config.localNSMap;
var endMatch = config.tagName == tagName;
var endIgnoreCaseMach = endMatch || config.tagName&&config.tagName.toLowerCase() == tagName.toLowerCase()
@ -126,12 +140,12 @@ function parse(source,defaultNSMapCopy,entityMap,domBuilder,errorHandler){
}
}
if(!endMatch){
errorHandler.fatalError("end tag name: "+tagName+' is not match the current start tagName:'+config.tagName );
errorHandler.fatalError("end tag name: "+tagName+' is not match the current start tagName:'+config.tagName ); // No known test case
}
}else{
parseStack.push(config)
}
end++;
break;
// end elment
@ -150,8 +164,8 @@ function parse(source,defaultNSMapCopy,entityMap,domBuilder,errorHandler){
//elStartEnd
var end = parseElementStartPart(source,tagStart,el,currentNSMap,entityReplacer,errorHandler);
var len = el.length;
if(!el.closed && fixSelfClosed(source,end,el.tagName,closeMap)){
el.closed = true;
if(!entityMap.nbsp){
@ -166,7 +180,6 @@ function parse(source,defaultNSMapCopy,entityMap,domBuilder,errorHandler){
position(a.offset);
a.locator = copyLocator(locator,{});
}
//}catch(e){console.error('@@@@@'+e)}
domBuilder.locator = locator2
if(appendElement(el,domBuilder,currentNSMap)){
parseStack.push(el)
@ -177,20 +190,19 @@ function parse(source,defaultNSMapCopy,entityMap,domBuilder,errorHandler){
parseStack.push(el)
}
}
if(el.uri === 'http://www.w3.org/1999/xhtml' && !el.closed){
if (NAMESPACE.isHTML(el.uri) && !el.closed) {
end = parseHtmlSpecialContent(source,end,el.tagName,entityReplacer,domBuilder)
}else{
} else {
end++;
}
}
}catch(e){
if (e instanceof ParseError) {
throw e;
}
errorHandler.error('element parse error: '+e)
//errorHandler.error('element parse error: '+e);
end = -1;
//throw e;
}
if(end>start){
start = end;
@ -211,6 +223,26 @@ function copyLocator(f,t){
* @return end of the elementStartPart(end of elementEndPart for selfClosed el)
*/
function parseElementStartPart(source,start,el,currentNSMap,entityReplacer,errorHandler){
/**
* @param {string} qname
* @param {string} value
* @param {number} startIndex
*/
function addAttribute(qname, value, startIndex) {
if (el.attributeNames.hasOwnProperty(qname)) {
errorHandler.fatalError('Attribute ' + qname + ' redefined')
}
el.addValue(
qname,
// @see https://www.w3.org/TR/xml/#AVNormalize
// since the xmldom sax parser does not "interpret" DTD the following is not implemented:
// - recursive replacement of (DTD) entity references
// - trimming and collapsing multiple spaces into a single one for attributes that are not of type CDATA
value.replace(/[\t\n\r]/g, ' ').replace(/&#?\w+;/g, entityReplacer),
startIndex
)
}
var attrName;
var value;
var p = ++start;
@ -226,7 +258,7 @@ function parseElementStartPart(source,start,el,currentNSMap,entityReplacer,error
s = S_EQ;
}else{
//fatalError: equal must after attrName or space after attrName
throw new Error('attribute equal must after attrName');
throw new Error('attribute equal must after attrName'); // No known test case
}
break;
case '\'':
@ -240,24 +272,22 @@ function parseElementStartPart(source,start,el,currentNSMap,entityReplacer,error
start = p+1;
p = source.indexOf(c,start)
if(p>0){
value = source.slice(start,p).replace(/&#?\w+;/g,entityReplacer);
el.add(attrName,value,start-1);
value = source.slice(start, p);
addAttribute(attrName, value, start-1);
s = S_ATTR_END;
}else{
//fatalError: no end quot match
throw new Error('attribute value no end \''+c+'\' match');
}
}else if(s == S_ATTR_NOQUOT_VALUE){
value = source.slice(start,p).replace(/&#?\w+;/g,entityReplacer);
//console.log(attrName,value,start,p)
el.add(attrName,value,start);
//console.dir(el)
value = source.slice(start, p);
addAttribute(attrName, value, start);
errorHandler.warning('attribute "'+attrName+'" missed start quot('+c+')!!');
start = p+1;
s = S_ATTR_END
}else{
//fatalError: no equal before
throw new Error('attribute value must after "="');
throw new Error('attribute value must after "="'); // No known test case
}
break;
case '/':
@ -275,11 +305,10 @@ function parseElementStartPart(source,start,el,currentNSMap,entityReplacer,error
break;
//case S_EQ:
default:
throw new Error("attribute invalid close char('/')")
throw new Error("attribute invalid close char('/')") // No known test case
}
break;
case ''://end document
//throw new Error('unexpected end of input')
errorHandler.error('unexpected end of input');
if(s == S_TAG){
el.setTagName(source.slice(start,p));
@ -305,13 +334,13 @@ function parseElementStartPart(source,start,el,currentNSMap,entityReplacer,error
value = attrName;
}
if(s == S_ATTR_NOQUOT_VALUE){
errorHandler.warning('attribute "'+value+'" missed quot(")!!');
el.add(attrName,value.replace(/&#?\w+;/g,entityReplacer),start)
errorHandler.warning('attribute "'+value+'" missed quot(")!');
addAttribute(attrName, value, start)
}else{
if(currentNSMap[''] !== 'http://www.w3.org/1999/xhtml' || !value.match(/^(?:disabled|checked|selected)$/i)){
if(!NAMESPACE.isHTML(currentNSMap['']) || !value.match(/^(?:disabled|checked|selected)$/i)){
errorHandler.warning('attribute "'+value+'" missed value!! "'+value+'" instead!!')
}
el.add(value,value,start)
addAttribute(value, value, start)
}
break;
case S_EQ:
@ -334,9 +363,9 @@ function parseElementStartPart(source,start,el,currentNSMap,entityReplacer,error
s = S_ATTR_SPACE;
break;
case S_ATTR_NOQUOT_VALUE:
var value = source.slice(start,p).replace(/&#?\w+;/g,entityReplacer);
var value = source.slice(start, p);
errorHandler.warning('attribute "'+value+'" missed quot(")!!');
el.add(attrName,value,start)
addAttribute(attrName, value, start)
case S_ATTR_END:
s = S_TAG_SPACE;
break;
@ -356,10 +385,10 @@ function parseElementStartPart(source,start,el,currentNSMap,entityReplacer,error
//case S_ATTR_NOQUOT_VALUE:void();break;
case S_ATTR_SPACE:
var tagName = el.tagName;
if(currentNSMap[''] !== 'http://www.w3.org/1999/xhtml' || !attrName.match(/^(?:disabled|checked|selected)$/i)){
if (!NAMESPACE.isHTML(currentNSMap['']) || !attrName.match(/^(?:disabled|checked|selected)$/i)) {
errorHandler.warning('attribute "'+attrName+'" missed value!! "'+attrName+'" instead2!!')
}
el.add(attrName,attrName,start);
addAttribute(attrName, attrName, start);
start = p;
s = S_ATTR;
break;
@ -406,7 +435,7 @@ function appendElement(el,domBuilder,currentNSMap){
}
//can not set prefix,because prefix !== ''
a.localName = localName ;
//prefix == null for no ns prefix attribute
//prefix == null for no ns prefix attribute
if(nsPrefix !== false){//hack!!
if(localNSMap == null){
localNSMap = {}
@ -415,8 +444,8 @@ function appendElement(el,domBuilder,currentNSMap){
//console.log(currentNSMap,1)
}
currentNSMap[nsPrefix] = localNSMap[nsPrefix] = value;
a.uri = 'http://www.w3.org/2000/xmlns/'
domBuilder.startPrefixMapping(nsPrefix, value)
a.uri = NAMESPACE.XMLNS
domBuilder.startPrefixMapping(nsPrefix, value)
}
}
var i = el.length;
@ -425,10 +454,10 @@ function appendElement(el,domBuilder,currentNSMap){
var prefix = a.prefix;
if(prefix){//no prefix attribute has no namespace
if(prefix === 'xml'){
a.uri = 'http://www.w3.org/XML/1998/namespace';
a.uri = NAMESPACE.XML;
}if(prefix !== 'xmlns'){
a.uri = currentNSMap[prefix || '']
//{console.log('###'+a.qName,domBuilder.locator.systemId+'',currentNSMap,a.uri)}
}
}
@ -450,7 +479,7 @@ function appendElement(el,domBuilder,currentNSMap){
domBuilder.endElement(ns,localName,tagName);
if(localNSMap){
for(prefix in localNSMap){
domBuilder.endPrefixMapping(prefix)
domBuilder.endPrefixMapping(prefix)
}
}
}else{
@ -477,7 +506,7 @@ function parseHtmlSpecialContent(source,elStartEnd,tagName,entityReplacer,domBui
domBuilder.characters(text,0,text.length);
return elEndStart;
//}
}
}
return elStartEnd+1;
@ -494,7 +523,7 @@ function fixSelfClosed(source,elStartEnd,tagName,closeMap){
closeMap[tagName] =pos
}
return pos<elStartEnd;
//}
//}
}
function _copy(source,target){
for(var n in source){target[n] = source[n]}
@ -522,22 +551,29 @@ function parseDCC(source,start,domBuilder,errorHandler){//sure start with '<!'
var end = source.indexOf(']]>',start+9);
domBuilder.startCDATA();
domBuilder.characters(source,start+9,end-start-9);
domBuilder.endCDATA()
domBuilder.endCDATA()
return end+3;
}
//<!DOCTYPE
//startDTD(java.lang.String name, java.lang.String publicId, java.lang.String systemId)
//startDTD(java.lang.String name, java.lang.String publicId, java.lang.String systemId)
var matchs = split(source,start);
var len = matchs.length;
if(len>1 && /!doctype/i.test(matchs[0][0])){
var name = matchs[1][0];
var pubid = len>3 && /^public$/i.test(matchs[2][0]) && matchs[3][0]
var sysid = len>4 && matchs[4][0];
var pubid = false;
var sysid = false;
if(len>3){
if(/^public$/i.test(matchs[2][0])){
pubid = matchs[3][0];
sysid = len>4 && matchs[4][0];
}else if(/^system$/i.test(matchs[2][0])){
sysid = matchs[3][0];
}
}
var lastMatch = matchs[len-1]
domBuilder.startDTD(name,pubid && pubid.replace(/^(['"])(.*?)\1$/,'$2'),
sysid && sysid.replace(/^(['"])(.*?)\1$/,'$2'));
domBuilder.startDTD(name, pubid, sysid);
domBuilder.endDTD();
return lastMatch.index+lastMatch[0].length
}
}
@ -561,11 +597,8 @@ function parseInstruction(source,start,domBuilder){
return -1;
}
/**
* @param source
*/
function ElementAttributes(source){
function ElementAttributes(){
this.attributeNames = {}
}
ElementAttributes.prototype = {
setTagName:function(tagName){
@ -574,10 +607,11 @@ ElementAttributes.prototype = {
}
this.tagName = tagName
},
add:function(qName,value,offset){
addValue:function(qName, value, offset) {
if(!tagNamePattern.test(qName)){
throw new Error('invalid attribute:'+qName)
}
this.attributeNames[qName] = this.length;
this[this.length++] = {qName:qName,value:value,offset:offset}
},
length:0,
@ -588,7 +622,7 @@ ElementAttributes.prototype = {
getValue:function(i){return this[i].value}
// ,getIndex:function(uri, localName)){
// if(localName){
//
//
// }else{
// var qName = uri
// }
@ -613,4 +647,4 @@ function split(source,start){
}
exports.XMLReader = XMLReader;
exports.ParseError = ParseError;

69
node_modules/@xmldom/xmldom/package.json generated vendored Normal file
View File

@ -0,0 +1,69 @@
{
"name": "@xmldom/xmldom",
"version": "0.8.1",
"description": "A pure JavaScript W3C standard-based (XML DOM Level 2 Core) DOMParser and XMLSerializer module.",
"keywords": [
"w3c",
"dom",
"xml",
"parser",
"javascript",
"DOMParser",
"XMLSerializer",
"ponyfill"
],
"homepage": "https://github.com/xmldom/xmldom",
"repository": {
"type": "git",
"url": "git://github.com/xmldom/xmldom.git"
},
"main": "lib/index.js",
"types": "index.d.ts",
"files": [
"CHANGELOG.md",
"LICENSE",
"readme.md",
"SECURITY.md",
"index.d.ts",
"lib"
],
"scripts": {
"lint": "eslint lib test",
"changelog": "auto-changelog --unreleased-only",
"start": "nodemon --watch package.json --watch lib --watch test --exec 'npm --silent run test && npm --silent run lint'",
"stryker": "stryker run",
"stryker:dry-run": "stryker run -m '' --reporters progress",
"test": "jest",
"version": "./changelog-has-version.sh",
"release": "np --no-yarn"
},
"engines": {
"node": ">=10.0.0"
},
"dependencies": {},
"devDependencies": {
"@stryker-mutator/core": "5.6.1",
"auto-changelog": "2.4.0",
"eslint": "8.9.0",
"eslint-config-prettier": "8.3.0",
"eslint-plugin-es5": "1.5.0",
"eslint-plugin-prettier": "4.0.0",
"get-stream": "6.0.1",
"jest": "27.5.1",
"nodemon": "2.0.15",
"np": "7.6.0",
"prettier": "2.5.1",
"xmltest": "1.5.0",
"yauzl": "2.10.0"
},
"bugs": {
"url": "https://github.com/xmldom/xmldom/issues"
},
"license": "MIT",
"auto-changelog": {
"prepend": true,
"remote": "upstream",
"tagPrefix": "",
"template": "./auto-changelog.hbs"
}
}

339
node_modules/@xmldom/xmldom/readme.md generated vendored Normal file
View File

@ -0,0 +1,339 @@
# @xmldom/xmldom
***Since version 0.7.0 this package is published to npm as [`@xmldom/xmldom`](https://www.npmjs.com/package/@xmldom/xmldom) and no longer as [`xmldom`](https://www.npmjs.com/package/xmldom), because [we are no longer able to publish `xmldom`](https://github.com/xmldom/xmldom/issues/271).***
*For better readability in the docs we will continue to talk about this library as "xmldom".*
[![license(MIT)](https://img.shields.io/npm/l/@xmldom/xmldom?color=blue&style=flat-square)](https://github.com/xmldom/xmldom/blob/master/LICENSE)
[![npm](https://img.shields.io/npm/v/@xmldom/xmldom?style=flat-square)](https://www.npmjs.com/package/@xmldom/xmldom)
[![snyk.io package health](https://snyk.io/advisor/npm-package/@xmldom/xmldom/badge.svg)](https://snyk.io/advisor/npm-package/@xmldom/xmldom)
[![bug issues](https://img.shields.io/github/issues/xmldom/xmldom/bug?color=red&style=flat-square)](https://github.com/xmldom/xmldom/issues?q=is%3Aissue+is%3Aopen+label%3Abug)
[![help-wanted issues](https://img.shields.io/github/issues/xmldom/xmldom/help-wanted?color=darkgreen&style=flat-square)](https://github.com/xmldom/xmldom/issues?q=is%3Aissue+is%3Aopen+label%3Ahelp-wanted)
[![Mutation report](https://img.shields.io/endpoint?style=flat-square&url=https%3A%2F%2Fbadge-api.stryker-mutator.io%2Fgithub.com%2Fxmldom%2Fxmldom%2Fmaster)](https://dashboard.stryker-mutator.io/reports/github.com/xmldom/xmldom/master)
xmldom is a javascript [ponyfill](https://ponyfill.com/) to provide the following APIs [that are present in modern browsers](https://caniuse.com/xml-serializer) to other runtimes:
- convert an XML string into a DOM tree
```
new DOMParser().parseFromString(xml, mimeType) => Document
```
- create, access and modify a DOM tree
```
new DOMImplementation().createDocument(...) => Document
```
- serialize a DOM tree back into an XML string
```
new XMLSerializer().serializeToString(node) => string
```
The target runtimes `xmldom` supports are currently Node >= v10 (ES5) and Rhino ([not tested as part of CI](https://github.com/xmldom/xmldom/discussions/214)).
When deciding how to fix bugs or implement features, `xmldom` tries to stay as close as possible to the various [related specifications/standards](#specs).
As indicated by the version starting with `0.`, this implementation is not feature complete and some implemented features differ from what the specifications describe.
**Issues and PRs for such differences are always welcome, even when they only provide a failing test case.**
This project was forked from it's [original source](https://github.com/jindw/xmldom) in 2019, more details about that transition can be found in the [CHANGELOG](CHANGELOG.md#maintainer-changes).
## Usage
### Install:
> npm install @xmldom/xmldom
### Example:
```javascript
const { DOMParser } = require('@xmldom/xmldom')
const doc = new DOMParser().parseFromString(
'<xml xmlns="a" xmlns:c="./lite">\n' +
'\t<child>test</child>\n' +
'\t<child></child>\n' +
'\t<child/>\n' +
'</xml>',
'text/xml'
)
doc.documentElement.setAttribute('x', 'y')
doc.documentElement.setAttributeNS('./lite', 'c:x', 'y2')
console.info(doc)
const nsAttr = doc.documentElement.getAttributeNS('./lite', 'x')
console.info(nsAttr)
```
Note: in Typescript and ES6 you can use the import approach, as follows:
```javascript
import { DOMParser } from '@xmldom/xmldom'
```
## API Reference
* [DOMParser](https://developer.mozilla.org/en-US/docs/Web/API/DOMParser):
```javascript
parseFromString(xmlsource,mimeType)
```
* **options extension** _by xmldom_ (not DOM standard!!)
```javascript
//added the options argument
new DOMParser(options)
//errorHandler is supported
new DOMParser({
/**
* locator is always need for error position info
*/
locator:{},
/**
* you can override the errorHandler for xml parser
* @link http://www.saxproject.org/apidoc/org/xml/sax/ErrorHandler.html
*/
errorHandler:{warning:function(w){console.warn(w)},error:callback,fatalError:callback}
//only callback model
//errorHandler:function(level,msg){console.log(level,msg)}
})
```
* [XMLSerializer](https://developer.mozilla.org/en-US/docs/Web/API/XMLSerializer)
```javascript
serializeToString(node)
```
### DOM level2 method and attribute:
* [Node](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-1950641247)
attribute:
nodeValue|prefix
readonly attribute:
nodeName|nodeType|parentNode|childNodes|firstChild|lastChild|previousSibling|nextSibling|attributes|ownerDocument|namespaceURI|localName
method:
insertBefore(newChild, refChild)
replaceChild(newChild, oldChild)
removeChild(oldChild)
appendChild(newChild)
hasChildNodes()
cloneNode(deep)
normalize()
isSupported(feature, version)
hasAttributes()
* [DOMException](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/ecma-script-binding.html)
The DOMException class has the following constants (and `value` of type `Number`):
1. `DOMException.INDEX_SIZE_ERR` (`1`)
1. `DOMException.DOMSTRING_SIZE_ERR` (`2`)
1. `DOMException.HIERARCHY_REQUEST_ERR` (`3`)
1. `DOMException.WRONG_DOCUMENT_ERR` (`4`)
1. `DOMException.INVALID_CHARACTER_ERR` (`5`)
1. `DOMException.NO_DATA_ALLOWED_ERR` (`6`)
1. `DOMException.NO_MODIFICATION_ALLOWED_ERR` (`7`)
1. `DOMException.NOT_FOUND_ERR` (`8`)
1. `DOMException.NOT_SUPPORTED_ERR` (`9`)
1. `DOMException.INUSE_ATTRIBUTE_ERR` (`10`)
1. `DOMException.INVALID_STATE_ERR` (`11`)
1. `DOMException.SYNTAX_ERR` (`12`)
1. `DOMException.INVALID_MODIFICATION_ERR` (`13`)
1. `DOMException.NAMESPACE_ERR` (`14`)
1. `DOMException.INVALID_ACCESS_ERR` (`15`)
The DOMException object has the following properties:
code
This property is of type Number.
* extends the Error type thrown as part of DOM API:
* [DOMImplementation](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-102161490)
method:
hasFeature(feature, version)
createDocumentType(qualifiedName, publicId, systemId)
createDocument(namespaceURI, qualifiedName, doctype)
* [Document](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#i-Document) : Node
readonly attribute:
doctype|implementation|documentElement
method:
createElement(tagName)
createDocumentFragment()
createTextNode(data)
createComment(data)
createCDATASection(data)
createProcessingInstruction(target, data)
createAttribute(name)
createEntityReference(name)
getElementsByTagName(tagname)
importNode(importedNode, deep)
createElementNS(namespaceURI, qualifiedName)
createAttributeNS(namespaceURI, qualifiedName)
getElementsByTagNameNS(namespaceURI, localName)
getElementById(elementId)
* [DocumentFragment](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-B63ED1A3) : Node
* [Element](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-745549614) : Node
readonly attribute:
tagName
method:
getAttribute(name)
setAttribute(name, value)
removeAttribute(name)
getAttributeNode(name)
setAttributeNode(newAttr)
removeAttributeNode(oldAttr)
getElementsByTagName(name)
getAttributeNS(namespaceURI, localName)
setAttributeNS(namespaceURI, qualifiedName, value)
removeAttributeNS(namespaceURI, localName)
getAttributeNodeNS(namespaceURI, localName)
setAttributeNodeNS(newAttr)
getElementsByTagNameNS(namespaceURI, localName)
hasAttribute(name)
hasAttributeNS(namespaceURI, localName)
* [Attr](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-637646024) : Node
attribute:
value
readonly attribute:
name|specified|ownerElement
* [NodeList](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-536297177)
readonly attribute:
length
method:
item(index)
* [NamedNodeMap](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-1780488922)
readonly attribute:
length
method:
getNamedItem(name)
setNamedItem(arg)
removeNamedItem(name)
item(index)
getNamedItemNS(namespaceURI, localName)
setNamedItemNS(arg)
removeNamedItemNS(namespaceURI, localName)
* [CharacterData](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-FF21A306) : Node
method:
substringData(offset, count)
appendData(arg)
insertData(offset, arg)
deleteData(offset, count)
replaceData(offset, count, arg)
* [Text](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-1312295772) : CharacterData
method:
splitText(offset)
* [CDATASection](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-667469212)
* [Comment](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-1728279322) : CharacterData
* [DocumentType](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-412266927)
readonly attribute:
name|entities|notations|publicId|systemId|internalSubset
* Notation : Node
readonly attribute:
publicId|systemId
* Entity : Node
readonly attribute:
publicId|systemId|notationName
* EntityReference : Node
* ProcessingInstruction : Node
attribute:
data
readonly attribute:
target
### DOM level 3 support:
* [Node](http://www.w3.org/TR/DOM-Level-3-Core/core.html#Node3-textContent)
attribute:
textContent
method:
isDefaultNamespace(namespaceURI){
lookupNamespaceURI(prefix)
### DOM extension by xmldom
* [Node] Source position extension;
attribute:
//Numbered starting from '1'
lineNumber
//Numbered starting from '1'
columnNumber
## Specs
The implementation is based on several specifications:
<!-- Should open in new tab and the links in the SVG should be clickable there! -->
<a href="https://raw.githubusercontent.com/xmldom/xmldom/master/docs/specs.svg" target="_blank" rel="noopener noreferrer nofollow" >![Overview of related specifications and their relations](docs/specs.svg)</a>
### DOM Parsing and Serialization
From the [W3C DOM Parsing and Serialization (WD 2016)](https://www.w3.org/TR/2016/WD-DOM-Parsing-20160517/) `xmldom` provides an implementation for the interfaces:
- `DOMParser`
- `XMLSerializer`
Note that there are some known deviations between this implementation and the W3 specifications.
Note: [The latest version of this spec](https://w3c.github.io/DOM-Parsing/) has the status "Editors Draft", since it is under active development. One major change is that [the definition of the `DOMParser` interface has been moved to the HTML spec](https://w3c.github.io/DOM-Parsing/#the-domparser-interface)
### DOM
The original author claims that xmldom implements [DOM Level 2] in a "fully compatible" way and some parts of [DOM Level 3], but there are not enough tests to prove this. Both Specifications are now superseded by the [DOM Level 4 aka Living standard] wich has a much broader scope than xmldom.
xmldom implements the following interfaces (most constructors are currently not exposed):
- `Attr`
- `CDATASection`
- `CharacterData`
- `Comment`
- `Document`
- `DocumentFragment`
- `DocumentType`
- `DOMException` (constructor exposed)
- `DOMImplementation` (constructor exposed)
- `Element`
- `Entity`
- `EntityReference`
- `LiveNodeList`
- `NamedNodeMap`
- `Node` (constructor exposed)
- `NodeList`
- `Notation`
- `ProcessingInstruction`
- `Text`
more details are available in the (incomplete) [API Reference](#api-reference) section.
### HTML
xmldom does not have any goal of supporting the full spec, but it has some capability to parse, report and serialize things differently when "detecting HTML" (by checking the default namespace).
There is an upcoming change to better align the implementation with the latest specs, related to <https://github.com/xmldom/xmldom/issues/203>.
### SAX, XML, XMLNS
xmldom has an own SAX parser implementation to do the actual parsing, which implements some interfaces in alignment with the Java interfaces SAX defines:
- `XMLReader`
- `DOMHandler`
There is an idea/proposal to make ti possible to replace it with something else in <https://github.com/xmldom/xmldom/issues/55>

6
node_modules/tunnel/.travis.yml generated vendored Normal file
View File

@ -0,0 +1,6 @@
language: node_js
node_js:
- "4"
- "6"
- "8"
- "10"

22
node_modules/tunnel/CHANGELOG.md generated vendored Normal file
View File

@ -0,0 +1,22 @@
# Changelog
- 0.0.6 (2018/09/11)
- Fix `localAddress` not working (#25)
- Fix `Host:` header for CONNECT method by @tmurakam (#29, #30)
- Fix default port for https (#32)
- Fix error handling when the proxy send illegal response body (#33)
- 0.0.5 (2017/06/12)
- Fix socket leak.
- 0.0.4 (2016/01/23)
- supported Node v0.12 or later.
- 0.0.3 (2014/01/20)
- fixed package.json
- 0.0.1 (2012/02/18)
- supported Node v0.6.x (0.6.11 or later).
- 0.0.0 (2012/02/11)
- first release.

21
node_modules/tunnel/LICENSE generated vendored Normal file
View File

@ -0,0 +1,21 @@
The MIT License (MIT)
Copyright (c) 2012 Koichi Kobayashi
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.

185
node_modules/tunnel/README.md generated vendored Normal file
View File

@ -0,0 +1,185 @@
# node-tunnel - HTTP/HTTPS Agents for tunneling proxies
[![Build Status](https://img.shields.io/travis/koichik/node-tunnel.svg?style=flat)](https://travis-ci.org/koichik/node-tunnel)
[![Dependency Status](http://img.shields.io/david/koichik/node-tunnel.svg?style=flat)](https://david-dm.org/koichik/node-tunnel#info=dependencies)
[![DevDependency Status](http://img.shields.io/david/dev/koichik/node-tunnel.svg?style=flat)](https://david-dm.org/koichik/node-tunnel#info=devDependencies)
## Example
```javascript
var tunnel = require('tunnel');
var tunnelingAgent = tunnel.httpsOverHttp({
proxy: {
host: 'localhost',
port: 3128
}
});
var req = https.request({
host: 'example.com',
port: 443,
agent: tunnelingAgent
});
```
## Installation
$ npm install tunnel
## Usages
### HTTP over HTTP tunneling
```javascript
var tunnelingAgent = tunnel.httpOverHttp({
maxSockets: poolSize, // Defaults to http.Agent.defaultMaxSockets
proxy: { // Proxy settings
host: proxyHost, // Defaults to 'localhost'
port: proxyPort, // Defaults to 80
localAddress: localAddress, // Local interface if necessary
// Basic authorization for proxy server if necessary
proxyAuth: 'user:password',
// Header fields for proxy server if necessary
headers: {
'User-Agent': 'Node'
}
}
});
var req = http.request({
host: 'example.com',
port: 80,
agent: tunnelingAgent
});
```
### HTTPS over HTTP tunneling
```javascript
var tunnelingAgent = tunnel.httpsOverHttp({
maxSockets: poolSize, // Defaults to http.Agent.defaultMaxSockets
// CA for origin server if necessary
ca: [ fs.readFileSync('origin-server-ca.pem')],
// Client certification for origin server if necessary
key: fs.readFileSync('origin-server-key.pem'),
cert: fs.readFileSync('origin-server-cert.pem'),
proxy: { // Proxy settings
host: proxyHost, // Defaults to 'localhost'
port: proxyPort, // Defaults to 80
localAddress: localAddress, // Local interface if necessary
// Basic authorization for proxy server if necessary
proxyAuth: 'user:password',
// Header fields for proxy server if necessary
headers: {
'User-Agent': 'Node'
},
}
});
var req = https.request({
host: 'example.com',
port: 443,
agent: tunnelingAgent
});
```
### HTTP over HTTPS tunneling
```javascript
var tunnelingAgent = tunnel.httpOverHttps({
maxSockets: poolSize, // Defaults to http.Agent.defaultMaxSockets
proxy: { // Proxy settings
host: proxyHost, // Defaults to 'localhost'
port: proxyPort, // Defaults to 443
localAddress: localAddress, // Local interface if necessary
// Basic authorization for proxy server if necessary
proxyAuth: 'user:password',
// Header fields for proxy server if necessary
headers: {
'User-Agent': 'Node'
},
// CA for proxy server if necessary
ca: [ fs.readFileSync('origin-server-ca.pem')],
// Server name for verification if necessary
servername: 'example.com',
// Client certification for proxy server if necessary
key: fs.readFileSync('origin-server-key.pem'),
cert: fs.readFileSync('origin-server-cert.pem'),
}
});
var req = http.request({
host: 'example.com',
port: 80,
agent: tunnelingAgent
});
```
### HTTPS over HTTPS tunneling
```javascript
var tunnelingAgent = tunnel.httpsOverHttps({
maxSockets: poolSize, // Defaults to http.Agent.defaultMaxSockets
// CA for origin server if necessary
ca: [ fs.readFileSync('origin-server-ca.pem')],
// Client certification for origin server if necessary
key: fs.readFileSync('origin-server-key.pem'),
cert: fs.readFileSync('origin-server-cert.pem'),
proxy: { // Proxy settings
host: proxyHost, // Defaults to 'localhost'
port: proxyPort, // Defaults to 443
localAddress: localAddress, // Local interface if necessary
// Basic authorization for proxy server if necessary
proxyAuth: 'user:password',
// Header fields for proxy server if necessary
headers: {
'User-Agent': 'Node'
}
// CA for proxy server if necessary
ca: [ fs.readFileSync('origin-server-ca.pem')],
// Server name for verification if necessary
servername: 'example.com',
// Client certification for proxy server if necessary
key: fs.readFileSync('origin-server-key.pem'),
cert: fs.readFileSync('origin-server-cert.pem'),
}
});
var req = https.request({
host: 'example.com',
port: 443,
agent: tunnelingAgent
});
```
## CONTRIBUTORS
* [Aleksis Brezas (abresas)](https://github.com/abresas)
* [Jackson Tian (JacksonTian)](https://github.com/JacksonTian)
* [Dmitry Sorin (1999)](https://github.com/1999)
## License
Licensed under the [MIT](https://github.com/koichik/node-tunnel/blob/master/LICENSE) license.

1
node_modules/tunnel/index.js generated vendored Normal file
View File

@ -0,0 +1 @@
module.exports = require('./lib/tunnel');

264
node_modules/tunnel/lib/tunnel.js generated vendored Normal file
View File

@ -0,0 +1,264 @@
'use strict';
var net = require('net');
var tls = require('tls');
var http = require('http');
var https = require('https');
var events = require('events');
var assert = require('assert');
var util = require('util');
exports.httpOverHttp = httpOverHttp;
exports.httpsOverHttp = httpsOverHttp;
exports.httpOverHttps = httpOverHttps;
exports.httpsOverHttps = httpsOverHttps;
function httpOverHttp(options) {
var agent = new TunnelingAgent(options);
agent.request = http.request;
return agent;
}
function httpsOverHttp(options) {
var agent = new TunnelingAgent(options);
agent.request = http.request;
agent.createSocket = createSecureSocket;
agent.defaultPort = 443;
return agent;
}
function httpOverHttps(options) {
var agent = new TunnelingAgent(options);
agent.request = https.request;
return agent;
}
function httpsOverHttps(options) {
var agent = new TunnelingAgent(options);
agent.request = https.request;
agent.createSocket = createSecureSocket;
agent.defaultPort = 443;
return agent;
}
function TunnelingAgent(options) {
var self = this;
self.options = options || {};
self.proxyOptions = self.options.proxy || {};
self.maxSockets = self.options.maxSockets || http.Agent.defaultMaxSockets;
self.requests = [];
self.sockets = [];
self.on('free', function onFree(socket, host, port, localAddress) {
var options = toOptions(host, port, localAddress);
for (var i = 0, len = self.requests.length; i < len; ++i) {
var pending = self.requests[i];
if (pending.host === options.host && pending.port === options.port) {
// Detect the request to connect same origin server,
// reuse the connection.
self.requests.splice(i, 1);
pending.request.onSocket(socket);
return;
}
}
socket.destroy();
self.removeSocket(socket);
});
}
util.inherits(TunnelingAgent, events.EventEmitter);
TunnelingAgent.prototype.addRequest = function addRequest(req, host, port, localAddress) {
var self = this;
var options = mergeOptions({request: req}, self.options, toOptions(host, port, localAddress));
if (self.sockets.length >= this.maxSockets) {
// We are over limit so we'll add it to the queue.
self.requests.push(options);
return;
}
// If we are under maxSockets create a new one.
self.createSocket(options, function(socket) {
socket.on('free', onFree);
socket.on('close', onCloseOrRemove);
socket.on('agentRemove', onCloseOrRemove);
req.onSocket(socket);
function onFree() {
self.emit('free', socket, options);
}
function onCloseOrRemove(err) {
self.removeSocket(socket);
socket.removeListener('free', onFree);
socket.removeListener('close', onCloseOrRemove);
socket.removeListener('agentRemove', onCloseOrRemove);
}
});
};
TunnelingAgent.prototype.createSocket = function createSocket(options, cb) {
var self = this;
var placeholder = {};
self.sockets.push(placeholder);
var connectOptions = mergeOptions({}, self.proxyOptions, {
method: 'CONNECT',
path: options.host + ':' + options.port,
agent: false,
headers: {
host: options.host + ':' + options.port
}
});
if (options.localAddress) {
connectOptions.localAddress = options.localAddress;
}
if (connectOptions.proxyAuth) {
connectOptions.headers = connectOptions.headers || {};
connectOptions.headers['Proxy-Authorization'] = 'Basic ' +
new Buffer(connectOptions.proxyAuth).toString('base64');
}
debug('making CONNECT request');
var connectReq = self.request(connectOptions);
connectReq.useChunkedEncodingByDefault = false; // for v0.6
connectReq.once('response', onResponse); // for v0.6
connectReq.once('upgrade', onUpgrade); // for v0.6
connectReq.once('connect', onConnect); // for v0.7 or later
connectReq.once('error', onError);
connectReq.end();
function onResponse(res) {
// Very hacky. This is necessary to avoid http-parser leaks.
res.upgrade = true;
}
function onUpgrade(res, socket, head) {
// Hacky.
process.nextTick(function() {
onConnect(res, socket, head);
});
}
function onConnect(res, socket, head) {
connectReq.removeAllListeners();
socket.removeAllListeners();
if (res.statusCode !== 200) {
debug('tunneling socket could not be established, statusCode=%d',
res.statusCode);
socket.destroy();
var error = new Error('tunneling socket could not be established, ' +
'statusCode=' + res.statusCode);
error.code = 'ECONNRESET';
options.request.emit('error', error);
self.removeSocket(placeholder);
return;
}
if (head.length > 0) {
debug('got illegal response body from proxy');
socket.destroy();
var error = new Error('got illegal response body from proxy');
error.code = 'ECONNRESET';
options.request.emit('error', error);
self.removeSocket(placeholder);
return;
}
debug('tunneling connection has established');
self.sockets[self.sockets.indexOf(placeholder)] = socket;
return cb(socket);
}
function onError(cause) {
connectReq.removeAllListeners();
debug('tunneling socket could not be established, cause=%s\n',
cause.message, cause.stack);
var error = new Error('tunneling socket could not be established, ' +
'cause=' + cause.message);
error.code = 'ECONNRESET';
options.request.emit('error', error);
self.removeSocket(placeholder);
}
};
TunnelingAgent.prototype.removeSocket = function removeSocket(socket) {
var pos = this.sockets.indexOf(socket)
if (pos === -1) {
return;
}
this.sockets.splice(pos, 1);
var pending = this.requests.shift();
if (pending) {
// If we have pending requests and a socket gets closed a new one
// needs to be created to take over in the pool for the one that closed.
this.createSocket(pending, function(socket) {
pending.request.onSocket(socket);
});
}
};
function createSecureSocket(options, cb) {
var self = this;
TunnelingAgent.prototype.createSocket.call(self, options, function(socket) {
var hostHeader = options.request.getHeader('host');
var tlsOptions = mergeOptions({}, self.options, {
socket: socket,
servername: hostHeader ? hostHeader.replace(/:.*$/, '') : options.host
});
// 0 is dummy port for v0.6
var secureSocket = tls.connect(0, tlsOptions);
self.sockets[self.sockets.indexOf(socket)] = secureSocket;
cb(secureSocket);
});
}
function toOptions(host, port, localAddress) {
if (typeof host === 'string') { // since v0.10
return {
host: host,
port: port,
localAddress: localAddress
};
}
return host; // for v0.11 or later
}
function mergeOptions(target) {
for (var i = 1, len = arguments.length; i < len; ++i) {
var overrides = arguments[i];
if (typeof overrides === 'object') {
var keys = Object.keys(overrides);
for (var j = 0, keyLen = keys.length; j < keyLen; ++j) {
var k = keys[j];
if (overrides[k] !== undefined) {
target[k] = overrides[k];
}
}
}
}
return target;
}
var debug;
if (process.env.NODE_DEBUG && /\btunnel\b/.test(process.env.NODE_DEBUG)) {
debug = function() {
var args = Array.prototype.slice.call(arguments);
if (typeof args[0] === 'string') {
args[0] = 'TUNNEL: ' + args[0];
} else {
args.unshift('TUNNEL:');
}
console.error.apply(console, args);
}
} else {
debug = function() {};
}
exports.debug = debug; // for test

34
node_modules/tunnel/package.json generated vendored Normal file
View File

@ -0,0 +1,34 @@
{
"name": "tunnel",
"version": "0.0.6",
"description": "Node HTTP/HTTPS Agents for tunneling proxies",
"keywords": [
"http",
"https",
"agent",
"proxy",
"tunnel"
],
"homepage": "https://github.com/koichik/node-tunnel/",
"bugs": "https://github.com/koichik/node-tunnel/issues",
"license": "MIT",
"author": "Koichi Kobayashi <koichik@improvement.jp>",
"main": "./index.js",
"directories": {
"lib": "./lib"
},
"repository": {
"type": "git",
"url": "https://github.com/koichik/node-tunnel.git"
},
"scripts": {
"test": "mocha"
},
"devDependencies": {
"mocha": "^5.2.0",
"should": "^13.2.3"
},
"engines": {
"node": ">=0.6.11 <=0.7.0 || >=0.7.3"
}
}

92
node_modules/xmldom/CHANGELOG.md generated vendored
View File

@ -1,92 +0,0 @@
## 0.3.0
- Node >=10.x now required.
- Added getElementsByClassName method.
- Added Node to the list of exports
- Added lowercase of åäö in entityMap.
- Moved existing sources into `lib` subdirectory.
- Removed `.npmignore` in favor of `files` entry in package.json.
- More `package.json` refactoring.
- Replaced CHANGELOG with more rigorous file.
- Replaced LICENSE with more rigorous file.
- Removed component.json (deprecated package manager https://github.com/componentjs/guide)
- `proof` devDep updated to latest.
- Fixed CI.
- README updates.
## 0.2.1
- More package.json refactoring.
## 0.2.0
- Now publishing under xmldom npm package again; retiring xmldom-alpha.
- Remove coveralls.
- Disable cache in travis.
- Other refactoring.
## 0.1.28 (via xmldom-alpha npm package)
- Removed __proto__ accessor.
- Appended HTML entities defaults.
## 0.1.27 (via xmldom-alpha npm package)
- Various bug fixes.
- Don't ask why 0.1.26 and 0.1.25 were skipped. `¯\_(ツ)_/¯`
## 0.1.24 (via xmldom-alpha package)
- Added node filter.
## 0.1.23 (via xmldom-alpha npm package)
- Added namespace support for nest node serialize.
- Various other bug fixes.
## 0.1.22
- Merge XMLNS serialization.
- Removed \r from source string.
- Print namespaces for child elements.
- Switch references to nodeType to use named constants.
- Add nodelist toString support.
## 0.1.21
- Fixed serialize bug.
## 0.1.20
- Optimized invalid XML support.
- Added toString sorter for attributes output.
- Added html self closed node button.
- Added `*` NS support for getElementsByTagNameNS.
- Converted attribute's value to string in setAttributeNS.
- Added support for HTML entities for HTML docs only.
- Fixed TypeError when Document is created with DocumentType.
## 0.1.19
- Fixed issue #68, infinite loop on unclosed comment.
- Added error report for unclosed tag.
- Various other fixes.
## 0.1.18
- Added default `ns` support.
- parseFromString now renders entirely plain text documents as textNode.
- Enabled option to ignore white space on parsing.
## 0.1.16
- Correctly handle multibyte Unicode greater than two byts. #57. #56.
- Initial unit testing and test coverage. #53. #46. #19.
- Create Bower `component.json` #52.
## 0.1.8
- Add: some test case from node-o3-xml(excludes xpath support)
- Fix: remove existed attribute before setting (bug introduced in v0.1.5)
- Fix: index direct access for childNodes and any NodeList collection(not w3c standard)
- Fix: remove last child bug

4
node_modules/xmldom/LICENSE.md generated vendored
View File

@ -1,4 +0,0 @@
You can choose any one of these licenses:
- MIT: https://opensource.org/licenses/MIT
- LGPL: http://www.gnu.org/licenses/lgpl.html

76
node_modules/xmldom/package.json generated vendored
View File

@ -1,76 +0,0 @@
{
"name": "xmldom",
"version": "0.3.0",
"description": "A pure JavaScript W3C standard-based (XML DOM Level 2 Core) DOMParser and XMLSerializer module.",
"keywords": [
"w3c",
"dom",
"xml",
"parser",
"javascript",
"DOMParser",
"XMLSerializer"
],
"author": "jindw <jindw@xidea.org> (http://www.xidea.org)",
"homepage": "https://github.com/xmldom/xmldom",
"repository": {
"type": "git",
"url": "git://github.com/xmldom/xmldom.git"
},
"main": "lib/dom-parser.js",
"files": [
"lib"
],
"scripts": {
"test": "proof platform win32 && proof test */*/*.t.js || t/test"
},
"engines": {
"node": ">=10.0.0"
},
"dependencies": {},
"devDependencies": {
"proof": "~7.0.9"
},
"maintainers": [
{
"name": "brodybits",
"email": "chris@brody.consulting",
"url": "https://github.com/brodybits"
}
],
"contributors": [
{
"name": "jindw",
"email": "jindw@xidea.org",
"url": "http://www.xidea.org"
},
{
"name": "Yaron Naveh",
"email": "yaronn01@gmail.com",
"web": "http://webservices20.blogspot.com/"
},
{
"name": "Harutyun Amirjanyan",
"email": "amirjanyan@gmail.com",
"web": "https://github.com/nightwing"
},
{
"name": "Alan Gutierrez",
"email": "alan@prettyrobots.com",
"web": "http://www.prettyrobots.com/"
},
{
"name": "Eric Newport",
"email": "kethinov@gmail.com",
"web": "https://github.com/kethinov"
}
],
"bugs": {
"url": "https://github.com/xmldom/xmldom/issues"
},
"license": "(LGPL-2.0 OR MIT)"
,"_resolved": "https://registry.npmjs.org/xmldom/-/xmldom-0.3.0.tgz"
,"_integrity": "sha512-z9s6k3wxE+aZHgXYxSTpGDo7BYOUfJsIRyoZiX6HTjwpwfS2wpQBQKa2fD+ShLyPkqDYo5ud7KitmLZ2Cd6r0g=="
,"_from": "xmldom@0.3.0"
}

221
node_modules/xmldom/readme.md generated vendored
View File

@ -1,221 +0,0 @@
# XMLDOM [![Build Status](https://secure.travis-ci.org/xmldom/xmldom.png?branch=master)](http://travis-ci.org/xmldom/xmldom) [![NPM version](https://badge.fury.io/js/xmldom.png)](http://badge.fury.io/js/xmldom)
A JavaScript implementation of W3C DOM for Node.js, Rhino and the browser. Fully
compatible with `W3C DOM level2`; and some compatible with `level3`. Supports
`DOMParser` and `XMLSerializer` interface such as in browser.
**Original project location:** <https://github.com/jindw/xmldom>
Install:
-------
>npm install xmldom
Example:
====
```javascript
var DOMParser = require('xmldom').DOMParser;
var doc = new DOMParser().parseFromString(
'<xml xmlns="a" xmlns:c="./lite">\n'+
'\t<child>test</child>\n'+
'\t<child></child>\n'+
'\t<child/>\n'+
'</xml>'
,'text/xml');
doc.documentElement.setAttribute('x','y');
doc.documentElement.setAttributeNS('./lite','c:x','y2');
var nsAttr = doc.documentElement.getAttributeNS('./lite','x')
console.info(nsAttr)
console.info(doc)
```
API Reference
=====
* [DOMParser](https://developer.mozilla.org/en/DOMParser):
```javascript
parseFromString(xmlsource,mimeType)
```
* **options extension** _by xmldom_(not BOM standard!!)
```javascript
//added the options argument
new DOMParser(options)
//errorHandler is supported
new DOMParser({
/**
* locator is always need for error position info
*/
locator:{},
/**
* you can override the errorHandler for xml parser
* @link http://www.saxproject.org/apidoc/org/xml/sax/ErrorHandler.html
*/
errorHandler:{warning:function(w){console.warn(w)},error:callback,fatalError:callback}
//only callback model
//errorHandler:function(level,msg){console.log(level,msg)}
})
```
* [XMLSerializer](https://developer.mozilla.org/en/XMLSerializer)
```javascript
serializeToString(node)
```
DOM level2 method and attribute:
------
* [Node](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-1950641247)
attribute:
nodeValue|prefix
readonly attribute:
nodeName|nodeType|parentNode|childNodes|firstChild|lastChild|previousSibling|nextSibling|attributes|ownerDocument|namespaceURI|localName
method:
insertBefore(newChild, refChild)
replaceChild(newChild, oldChild)
removeChild(oldChild)
appendChild(newChild)
hasChildNodes()
cloneNode(deep)
normalize()
isSupported(feature, version)
hasAttributes()
* [DOMImplementation](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-102161490)
method:
hasFeature(feature, version)
createDocumentType(qualifiedName, publicId, systemId)
createDocument(namespaceURI, qualifiedName, doctype)
* [Document](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#i-Document) : Node
readonly attribute:
doctype|implementation|documentElement
method:
createElement(tagName)
createDocumentFragment()
createTextNode(data)
createComment(data)
createCDATASection(data)
createProcessingInstruction(target, data)
createAttribute(name)
createEntityReference(name)
getElementsByTagName(tagname)
importNode(importedNode, deep)
createElementNS(namespaceURI, qualifiedName)
createAttributeNS(namespaceURI, qualifiedName)
getElementsByTagNameNS(namespaceURI, localName)
getElementById(elementId)
* [DocumentFragment](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-B63ED1A3) : Node
* [Element](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-745549614) : Node
readonly attribute:
tagName
method:
getAttribute(name)
setAttribute(name, value)
removeAttribute(name)
getAttributeNode(name)
setAttributeNode(newAttr)
removeAttributeNode(oldAttr)
getElementsByTagName(name)
getAttributeNS(namespaceURI, localName)
setAttributeNS(namespaceURI, qualifiedName, value)
removeAttributeNS(namespaceURI, localName)
getAttributeNodeNS(namespaceURI, localName)
setAttributeNodeNS(newAttr)
getElementsByTagNameNS(namespaceURI, localName)
hasAttribute(name)
hasAttributeNS(namespaceURI, localName)
* [Attr](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-637646024) : Node
attribute:
value
readonly attribute:
name|specified|ownerElement
* [NodeList](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-536297177)
readonly attribute:
length
method:
item(index)
* [NamedNodeMap](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-1780488922)
readonly attribute:
length
method:
getNamedItem(name)
setNamedItem(arg)
removeNamedItem(name)
item(index)
getNamedItemNS(namespaceURI, localName)
setNamedItemNS(arg)
removeNamedItemNS(namespaceURI, localName)
* [CharacterData](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-FF21A306) : Node
method:
substringData(offset, count)
appendData(arg)
insertData(offset, arg)
deleteData(offset, count)
replaceData(offset, count, arg)
* [Text](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-1312295772) : CharacterData
method:
splitText(offset)
* [CDATASection](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-667469212)
* [Comment](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-1728279322) : CharacterData
* [DocumentType](http://www.w3.org/TR/2000/REC-DOM-Level-2-Core-20001113/core.html#ID-412266927)
readonly attribute:
name|entities|notations|publicId|systemId|internalSubset
* Notation : Node
readonly attribute:
publicId|systemId
* Entity : Node
readonly attribute:
publicId|systemId|notationName
* EntityReference : Node
* ProcessingInstruction : Node
attribute:
data
readonly attribute:
target
DOM level 3 support:
-----
* [Node](http://www.w3.org/TR/DOM-Level-3-Core/core.html#Node3-textContent)
attribute:
textContent
method:
isDefaultNamespace(namespaceURI){
lookupNamespaceURI(prefix)
DOM extension by xmldom
---
* [Node] Source position extension;
attribute:
//Numbered starting from '1'
lineNumber
//Numbered starting from '1'
columnNumber

1
node_modules/xpath/.npmignore generated vendored
View File

@ -1 +0,0 @@
node_modules/

133
node_modules/xpath/README.md generated vendored
View File

@ -1,133 +0,0 @@
## xpath
DOM 3 XPath 1.0 implemention and helper for JavaScript, with node.js support.
Originally written by Cameron McCormack ([blog](http://mcc.id.au/xpathjs)).
Additional contributions from
Yaron Naveh ([blog](http://webservices20.blogspot.com/))
goto100
Thomas Weinert
Jimmy Rishe
and [others](https://github.com/goto100/xpath/graphs/contributors)
## Install
Install with [npm](http://github.com/isaacs/npm):
npm install xpath
xpath is xml engine agnostic but I recommend to use [xmldom](https://github.com/jindw/xmldom):
npm install xmldom
## API Documentation
Can be found [here](https://github.com/goto100/xpath/blob/master/docs/xpath%20methods.md). See below for example usage.
## Your first xpath:
`````javascript
var xpath = require('xpath')
, dom = require('xmldom').DOMParser
var xml = "<book><title>Harry Potter</title></book>"
var doc = new dom().parseFromString(xml)
var nodes = xpath.select("//title", doc)
console.log(nodes[0].localName + ": " + nodes[0].firstChild.data)
console.log("Node: " + nodes[0].toString())
`````
title: Harry Potter
Node: <title>Harry Potter</title>
### Alternatively
Using the same interface you have on modern browsers ([MDN])
`````javascript
var node = null;
var xml = "<book author='J. K. Rowling'><title>Harry Potter</title></book>"
var doc = new dom().parseFromString(xml)
var result = xpath.evaluate(
"/book/title", // xpathExpression
doc, // contextNode
null, // namespaceResolver
xpath.XPathResult.ANY_TYPE, // resultType
null // result
)
node = result.iterateNext();
while (node) {
console.log(node.localName + ": " + node.firstChild.data);
console.log("Node: " + node.toString());
node = result.iterateNext();
}
`````
title: Harry Potter
Node: <title>Harry Potter</title>
## Evaluate string values directly:
`````javascript
var xml = "<book><title>Harry Potter</title></book>";
var doc = new dom().parseFromString(xml);
var title = xpath.select("string(//title)", doc);
console.log(title);
`````
Harry Potter
## Namespaces
`````javascript
var xml = "<book><title xmlns='myns'>Harry Potter</title></book>"
var doc = new dom().parseFromString(xml)
var node = xpath.select("//*[local-name(.)='title' and namespace-uri(.)='myns']", doc)[0]
console.log(node.namespaceURI)
`````
myns
## Namespaces with easy mappings
`````javascript
var xml = "<book xmlns:bookml='http://example.com/book'><bookml:title>Harry Potter</bookml:title></book>"
var select = xpath.useNamespaces({"bookml": "http://example.com/book"});
console.log(select('//bookml:title/text()', doc)[0].nodeValue);
`````
Harry Potter
## Default namespace with mapping
`````javascript
var xml = "<book xmlns='http://example.com/book'><title>Harry Potter</title></book>"
var select = xpath.useNamespaces({"bookml": "http://example.com/book"});
console.log(select('//bookml:title/text()', doc)[0].nodeValue);
`````
Harry Potter
## Attributes
`````javascript
var xml = "<book author='J. K. Rowling'><title>Harry Potter</title></book>"
var doc = new dom().parseFromString(xml)
var author = xpath.select1("/book/@author", doc).value
console.log(author)
`````
J. K. Rowling
[MDN]: https://developer.mozilla.org/en/docs/Web/API/Document/evaluate
## License
MIT

View File

@ -1,62 +0,0 @@
# `XPathEvaluator`
The `xpath.parse()` method returns an `XPathEvaluator`, which contains the following methods.
Each of these methods takes an optional `options` object, which can contain any of the following properties:
`namespaces` - a namespace resolver. See the [documentation page](namespace%20resolvers.md) for details.
`variables` - a variable resolver. See the [documentation page](variable%20resolvers.md) for details.
`functions` - a function resolver. See the [documentation page](function%20resolvers.md) for details.
`node` - the context node for evaluating the expression
Example usage:
```js
var evaluator = xpath.parse('/characters/character[@greeting = $greeting]');
var character = evaluator.select1({
node: myCharacterDoc,
variables: {
greeting: "Hello, I'm Harry, Harry Potter."
}
});
```
## `XPathEvaluator` methods
`evaluate([options])`
Evaluates the XPath expression and returns the result. The resulting type is determined based on the type of the expression, using the same criteria as [`xpath.select`](xpath%20methods.md).
`evaluateNumber([options])`
Evaluates the XPath expression and returns the result as a number.
`evaluateString([options])`
Evaluates the XPath expression and returns the result as a string.
`evaluateBoolean([options])`
Evaluates the XPath expression and returns the result as a boolean value.
`evaluateNodeSet([options])`
Evaluates the XPath expression and returns the result as an XNodeSet. See the [documentation page](#) for details on this interface.
This is only valid for expressions that evaluate to a node set.
`select([options])`
Evaluates the XPath expression and returns an array of the resulting nodes, in document order.
This is only valid for expressions that evaluate to a node set.
`select1([options])`
Evaluates the XPath expression and the first node in the resulting node set, in document order. Returns `undefined`
This is only valid for expressions that evaluate to a node set.

View File

@ -1,47 +0,0 @@
# XPathResult interface
Represents the result of an XPath expression. This interface is used for the parameters passed into custom functions
used in [function resolvers](function resolvers.md) and can represent a number, a string, a boolean value, or a node set.
## Methods
```js
booleanValue() -> boolean
```
Returns the boolean value of the result in accordance with the XPath 1.0 spec.
```js
numberValue() -> number
```
Returns the numeric value of the result in accordance with the XPath 1.0 spec.
```js
stringValue() -> string
```
Returns the string value of the result in accordance with the XPath 1.0 spec.
## Methods and properties that are only present on `XPathResult`s representing node sets
```js
toArray() -> Array of nodes
```
Returns an array of the nodes in the node set, in document order.
```js
first() -> Node
```
Returns the first node in the node set, in document order.
```js
size -> number
```
Returns the number of nodes in this node set

View File

@ -1,88 +0,0 @@
# Function Resolvers
The methods on the [XPathEvaluator](XPathEvaluator.md) type can optionally take a function resolver to resolve
function references in the XPath expression being evaluated.
There are three ways to specify a function resolver and you can use any one of them depending on which is
most suited to your particular situation.
Note that if your functions are in a namespace (e.g. `fn:myFunction()`), you must use the second or third
type as the plain object implementation does not support namespaces.
## Function implementations
Custom XPath functions are implemented as JavaScript functions taking one or more arguments.
The first argument passed in is a context object containing a number of properties relating to the execution context,
the most important being `contextNode`, the context in which the function is being evaluated.
The remaining arguments are the arguments passed into the XPath function, as instances of the `XPathResult` interface.
Please see [the documentation on that interface](XPathResult.md) for details.
As the return value, you can return a string, number, boolean, single node, or array of nodes.
## Function Resolver Type 1: Plain object
A plain object with function names as the keys and function implementations as the values.
Example usage:
```js
var evaluator = xpath.parse('squareRoot(10)');
var aboutPi = evaluator.evaluateNumber({
functions: {
'squareRoot': function (c, value) {
return Math.sqrt(value.numberValue());
}
}
});
```
## Function Resolver Type 2: Function
A function that takes a function name as its first parameter and an optional namespace URI as its second parameter
and returns a function based on the name and namespace.
Example usage:
```js
var evaluator = xpath.parse('math:squareRoot(10)');
var aboutPi = evaluator.evaluateNumber({
functions: function (name, namespace) {
if (name === 'squareRoot' && namespace === 'http://sample.org/math/') {
return function (c, value) {
return Math.sqrt(value.numberValue());
};
}
},
namespaces: {
math: 'http://sample.org/math/'
}
});
```
## Function Resolver Type 3: Object with `getFunction` method
An object with a method named `getFunction` that works in the same way as the function-based function resolver
described above.
Example usage:
```js
var evaluator = xpath.parse('math:squareRoot(10)');
var aboutPi = evaluator.evaluateNumber({
functions: {
getFunction: function (name, namespace) {
if (name === 'squareRoot' && namespace === 'http://sample.org/math/') {
return function (c, value) {
return Math.sqrt(value.numberValue());
};
}
}
},
namespaces: {
math: 'http://sample.org/math/'
}
});
```

View File

@ -1,69 +0,0 @@
# Namespace Resolvers
The methods on the [XPathEvaluator](XPathEvaluator.md) type can optionally take a namespace resolver to resolve
namespace references in the XPath expression being evaluated.
There are three ways to specify a namespace resolver and you can use any one of them depending on which is
most suited to your particular situation.
## Namespace Resolver Type 1: Plain object
A plain object with namespace prefixes as the keys and namespace URIs as the values:
Example usage:
```js
var evaluator = xpath.parse('/bk:book/hp:characters');
var characters = evaluator.select({
node: myBookNode,
namespaces: {
'bk': 'http://sample.org/books/',
'hp': 'http://sample.org/harrypotter/'
}
});
```
## Namespace Resolver Type 2: Function
A function that takes a namespace prefix as a parameter and returns the corresponding namespace URI.
Example usage:
```js
var evaluator = xpath.parse('/bk:book/hp:characters');
var characters = evaluator.select({
node: myBookNode,
namespaces: function (prefix) {
if (prefix === 'bk') {
return 'http://sample.org/books/';
}
if (prefix === 'hp') {
return 'http://sample.org/books/';
}
}
});
```
## Namespace Resolver Type 3: Object with `getNamespace` method
An object with a method named `getNamespace` that works in the same way as the function-based namespace resolver
described above.
Example usage:
```js
var evaluator = xpath.parse('/bk:book/hp:characters');
var characters = evaluator.select({
node: myBookNode,
namespaces: {
getNamespace: function (prefix) {
if (prefix === 'bk') {
return 'http://sample.org/books/';
}
if (prefix === 'hp') {
return 'http://sample.org/books/';
}
}
}
});
```

View File

@ -1,21 +0,0 @@
# Using Parsed Expressions
The `xpath.parse()` method allows pre-parsing an XPath expression and creating an XPath executor to evaluate the XPath as many times as needed.
This can provide a performance benefit if you plan to evaluate the same XPath multiple times, because the expression only needs to be parsed once.
This also provides access to additional features such as the use of variables and custom XPath functions, which are not available using the evaluation methods on the `xpath` object.
#### xpath.parse(expression)
Parses the specified XPath expression and returns an `XPathEvaluator`. See the [documentation page](XPathEvaluator.md) for API details.
`expression` should be a string.
Example usage:
```js
var evaluator = xpath.parse('/book/characters');
```

View File

@ -1,89 +0,0 @@
# Variable Resolvers
The methods on the [XPathEvaluator](#) type can optionally take a variable resolver to resolve
variable references in the XPath expression being evaluated.
There are three ways to specify a variable resolver and you can use any one of them depending on which is
most suited to your particular situation.
Note that if your variables are in a namespace (e.g. `$myVars:var`), you must use the second or third
type as the plain object implementation does not support namespaces.
## Variable values
You can use any of five types of values to specify the values of variables:
- string
- number
- boolean
- single node (will be treated as a node set)
- array of nodes or array-like collection of nodes (will be treated as a node set)
## Variable Resolver Type 1: Plain object
A plain object with variable names as the keys and variable values as the values.
Example usage:
````
var evaluator = xpath.parse('concat($character1, ", ", $character2, ", and ", $character3)');
var mainCharacters = evaluator.evaluateString({
variables: {
character1: 'Harry',
character2: 'Ron',
character3: 'Hermione'
}
});
````
## Variable Resolver Type 2: Function
A function that takes a variable name as its first parameter and an optional namespace URI as its second parameter
and returns a value based on the name and namespace.
Example usage:
````
var evaluator = xpath.parse('concat($hp:character1, ", ", $hp:character2, ", and ", $hp:character3)');
var mainCharacters = evaluator.evaluateString({
variables: function (name, namespace) {
if (namespace === 'http://sample.org/harrypotter/') {
switch (name) {
case 'character1': return 'Harry';
case 'character2': return 'Ron';
case 'character3': return 'Hermione';
}
}
},
namespaces: {
hp: 'http://sample.org/harrypotter/'
}
});
````
## Function Resolver Type 3: Object with `getFunction` method
An object with a method named `getVariable` that works in the same way as the function-based variable resolver
described above.
Example usage:
````
var evaluator = xpath.parse('concat($hp:character1, ", ", $hp:character2, ", and ", $hp:character3)');
var mainCharacters = evaluator.evaluateString({
variables: {
getVariable: function (name, namespace) {
if (namespace === 'http://sample.org/harrypotter/') {
switch (name) {
case 'character1': return 'Harry';
case 'character2': return 'Ron';
case 'character3': return 'Hermione';
}
}
}
},
namespaces: {
hp: 'http://sample.org/harrypotter/'
}
});
````

View File

@ -1,39 +0,0 @@
# xpath methods
This page details the methods exposed on the `xpath` object.
### `xpath.parse(expression)`
Creates a parsed expression. See the [documentation page](parsed%20expressions.md) for details.
### `xpath.select(expression[, node[, single]])`
Evaluates an XPath expression and returns the result. The return value is determined based on the result type of the expression (which can always be predicted ahead of time based on the expression's syntax):
- A boolean value if the expression evaluates to a boolean value.
- A number if the expression evaluates to a numeric value.
- A string if the expression evaluates to a string.
- If the expression evaluates to a nodeset:
- An array of 0 or more nodes if `single` is unspecified or falsy
- A single node (the first node in document order) or `undefined` if `single` is truthy
`node` is optional and if specified, is used as the context node for evaluating the expression. (It is necessary if the expression makes use of the current contex.)
`single` is optional and is ignored if the expression evaluates to anything other than a nodeset.
### `xpath.select1(expression[, node])`
Alias for [`xpath.select(expression, node, true)`](#xpathselectexpression-node-single). Selects a single node or value.
### `xpath.useNamespaces(mappings)`
Produces a function with the same signature as [`xpath.select()`](#xpathselectexpression-node-single) that evaluates the provided xpath expression using the XML namespace definitions provided in `mapppings`.
`mappings` should be an object with namespace prefixes as its property names and namespace URIs as its property values.
Example usage:
```js
var expr = xpath.useNamespaces({ hp: 'http://www.example.com/harryPotter', bk: 'http://www.example.com/books' });
var result = expr('/bk:books/bk:book[@name = "Harry Potter and the Half-Blood Prince"]/hp:characters', myBooks);
```

42
node_modules/xpath/package.json generated vendored
View File

@ -1,42 +0,0 @@
{
"name": "xpath",
"version": "0.0.27",
"description": "DOM 3 XPath implemention and helper for node.js.",
"engines": {
"node": ">=0.6.0"
},
"author": {
"name": "Cameron McCormack"
},
"contributors": [
{
"name": "goto100"
},
{
"name": "James Rishe"
}
],
"dependencies": {},
"devDependencies": {
"nodeunit": ">=0.6.4",
"xmldom": "^0.1.19"
},
"typings": "./xpath.d.ts",
"scripts": {
"test": "./node_modules/.bin/nodeunit test.js"
},
"repository": {
"type": "git",
"url": "https://github.com/goto100/xpath.git"
},
"main": "./xpath.js",
"keywords": [
"xpath",
"xml"
],
"license": "MIT"
,"_resolved": "https://registry.npmjs.org/xpath/-/xpath-0.0.27.tgz"
,"_integrity": "sha512-fg03WRxtkCV6ohClePNAECYsmpKKTv5L8y/X3Dn1hQrec3POx2jHZ/0P2qQ6HvsrU1BmeqXcof3NGGueG6LxwQ=="
,"_from": "xpath@0.0.27"
}

1092
node_modules/xpath/test.js generated vendored

File diff suppressed because it is too large Load Diff

9
node_modules/xpath/xpath.d.ts generated vendored
View File

@ -1,9 +0,0 @@
type SelectedValue = Node | Attr | string | number | boolean;
interface XPathSelect {
(expression: string, node?: Node): Array<SelectedValue>;
(expression: string, node: Node, single: true): SelectedValue;
}
export var select: XPathSelect;
export function select1(expression: string, node?: Node): SelectedValue;
export function evaluate(expression: string, contextNode: Node, resolver: XPathNSResolver, type: number, result: XPathResult): XPathResult;
export function useNamespaces(namespaceMap: { [name: string]: string }): XPathSelect;

4764
node_modules/xpath/xpath.js generated vendored

File diff suppressed because it is too large Load Diff

10520
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -1,11 +1,13 @@
{
"name": "maven-settings-action",
"version": "1.0.0",
"version": "2.6.0",
"description": "Prepare maven settings",
"main": "index.js",
"scripts": {
"lint": "eslint index.js settings.js",
"test": "eslint index.js settings.js && jest --coverage"
"test": "eslint index.js settings.js && jest --coverage",
"version": "./update-readme.sh",
"postversion": "git tag --delete v$npm_new_version"
},
"repository": {
"type": "git",
@ -24,12 +26,11 @@
},
"homepage": "https://github.com/s4u/maven-settings-action#readme",
"dependencies": {
"@actions/core": "^1.2.3",
"xmldom": "^0.3.0",
"xpath": "0.0.27"
"@actions/core": "^1.6.0",
"@xmldom/xmldom": "^0.8.1"
},
"devDependencies": {
"eslint": "^6.8.0",
"jest": "^25.2.7"
"eslint": "^8.12.0",
"jest": "^27.5.1"
}
}

View File

@ -26,17 +26,20 @@ const core = require('@actions/core');
const os = require('os');
const path = require('path');
const fs = require('fs');
const DOMParser = require('xmldom').DOMParser;
const XMLSerializer = require('xmldom').XMLSerializer;
const xpath = require('xpath');
const DOMParser = require('@xmldom/xmldom').DOMParser;
const XMLSerializer = require('@xmldom/xmldom').XMLSerializer;
function getSettingsPath() {
return path.join(os.homedir(), '.m2', 'settings.xml');
const _path = core.getInput('path');
if (!_path) {
return path.join(os.homedir(), '.m2', 'settings.xml');
} else {
return _path;
}
}
function getSettingsTemplate() {
const templatePath = path.join(__dirname, 'templates', 'settings.xml');
function getTemplate(templateName) {
const templatePath = path.join(__dirname, 'templates', templateName);
const templateStr = fs.readFileSync(templatePath).toString();
return new DOMParser().parseFromString(templateStr, 'text/xml');
}
@ -52,65 +55,87 @@ function writeSettings(settingsPath, templateXml) {
fs.writeFileSync(settingsPath, settingStr);
}
function createElementWithText(template, tag, text) {
const tagXml = template.createElement(tag);
tagXml.textContent = text;
return tagXml;
function jsonToXml(templateXml, xmlTag, json) {
for (const key in json) {
const keyXml = templateXml.createElement(key);
const value = json[key];
if (value instanceof Object) {
jsonToXml(templateXml, keyXml, value);
} else {
keyXml.textContent = value;
}
xmlTag.appendChild(keyXml);
}
}
function fillServer(template, id, username, password) {
function fillServer(templateXml, templateName, id, username, password, privateKey, passphrase, filePermissions, directoryPermissions, configurations) {
const serverXml = template.createElement('server');
if (!id || !username || !password) {
core.setFailed('servers must contain id, username and password');
if (!id || (!username && !configurations)) {
core.setFailed(templateName + ' must contain id, and username or configuration');
return;
}
const idXml = createElementWithText(template, 'id', id);
serverXml.appendChild(idXml);
const serverXml = getTemplate(templateName + '.xml')
serverXml.getElementsByTagName('id')[0].textContent = id;
const usernameXml = createElementWithText(template, 'username', username);
serverXml.appendChild(usernameXml);
const serverTags = {
'username': username,
'password': password,
'privateKey': privateKey,
'passphrase': passphrase,
'filePermissions': filePermissions,
'directoryPermissions': directoryPermissions
};
for (const tag in serverTags) {
const serverTag = serverXml.getElementsByTagName(tag)[0];
const tagValue = serverTags[tag];
if (tagValue) {
serverTag.textContent = tagValue;
} else {
serverXml.documentElement.removeChild(serverTag);
}
}
const passwordXml = createElementWithText(template, 'password', password);
serverXml.appendChild(passwordXml);
const configurationTag = serverXml.getElementsByTagName('configuration')[0];
if (configurations) {
jsonToXml(templateXml, configurationTag, configurations);
} else {
if (configurationTag.childNodes.length == 0) {
serverXml.documentElement.removeChild(configurationTag);
}
}
const serversXml = template.getElementsByTagName('servers')[0];
const serversXml = templateXml.getElementsByTagName('servers')[0];
serversXml.appendChild(serverXml);
}
function fillServers(template) {
function fillServers(template, templateName) {
const servers = core.getInput('servers');
const servers = core.getInput(templateName);
if (!servers) {
return;
}
JSON.parse(servers).forEach((server) => fillServer(template, server.id, server.username, server.password));
JSON.parse(servers).forEach((server) =>
fillServer(template, templateName, server.id, server.username,
server.password, server.privateKey, server.passphrase,
server.filePermissions, server.directoryPermissions,
server.configuration));
}
function fillMirror(template, id, name, mirrorOf, url) {
const mirrorXml = template.createElement('mirror');
if (!id || !name || !mirrorOf || !url) {
core.setFailed('mirrors must contain id, name, mirrorOf and url');
return;
}
const idXml = createElementWithText(template, 'id', id);
mirrorXml.appendChild(idXml);
const nameXml = createElementWithText(template, 'name', name);
mirrorXml.appendChild(nameXml);
const mirrorOfXml = createElementWithText(template, 'mirrorOf', mirrorOf);
mirrorXml.appendChild(mirrorOfXml);
const urlXml = createElementWithText(template, 'url', url);
mirrorXml.appendChild(urlXml);
const mirrorXml = getTemplate('mirrors.xml');
mirrorXml.getElementsByTagName('id')[0].textContent = id;
mirrorXml.getElementsByTagName('name')[0].textContent = name;
mirrorXml.getElementsByTagName('mirrorOf')[0].textContent = mirrorOf;
mirrorXml.getElementsByTagName('url')[0].textContent = url;
const mirrorsXml = template.getElementsByTagName('mirrors')[0];
mirrorsXml.appendChild(mirrorXml);
@ -138,42 +163,54 @@ function fillServerForGithub(templateXml) {
return;
}
fillServer(templateXml, 'github', '${env.GITHUB_ACTOR}', '${env.GITHUB_TOKEN}');
}
function activateProfile(template, profileId) {
const activeByDefault = xpath
.select(`/settings/profiles/profile[id[contains(text(),"${profileId}")]]/activation/activeByDefault`, template);
if (activeByDefault) {
activeByDefault[0].textContent = 'true';
}
fillServer(templateXml, 'servers', 'github', '${env.GITHUB_ACTOR}', '${env.GITHUB_TOKEN}');
}
function fillProperties(template) {
const properties = core.getInput('properties');
if (!properties) {
return;
}
activateProfile(template, '_properties_')
const propertiesXml = xpath
.select(`/settings/profiles/profile[id[contains(text(),"_properties_")]]/properties`, template)[0];
const propertiesProfileXml = getTemplate('properties.xml');
const propertiesXml = propertiesProfileXml.getElementsByTagName('properties')[0];
JSON.parse(properties).forEach((property) => {
for (const key in property) {
const keyXml = template.createElement(key);
keyXml.textContent = property[key];
propertiesXml.appendChild(keyXml);
}
});
const profilesXml = template.getElementsByTagName('profiles')[0];
profilesXml.appendChild(propertiesProfileXml);
}
function addProfile(template, profileName) {
const sonatypeXml = getTemplate(profileName);
const profilesXml = template.getElementsByTagName('profiles')[0];
profilesXml.appendChild(sonatypeXml);
}
function addApacheSnapshots(template) {
if (isInputTrue('apacheSnapshots')) {
addProfile(template, 'apache-snapshot.xml')
}
}
function addSonatypeSnapshots(template) {
if (isInputTrue('sonatypeSnapshots')) {
activateProfile(template, '_sonatype-snapshots_')
addProfile(template, 'sonatype-snapshot.xml')
}
}
function addOracleRepo(template) {
if (isInputTrue('oracleRepo')) {
addProfile(template, 'oracle-repo.xml')
}
}
@ -192,13 +229,16 @@ function generate() {
}
}
const templateXml = getSettingsTemplate();
fillMirrors(templateXml);
fillServers(templateXml);
fillServerForGithub(templateXml);
fillProperties(templateXml);
addSonatypeSnapshots(templateXml);
writeSettings(settingsPath, templateXml);
const settingsXml = getTemplate('settings.xml');
fillMirrors(settingsXml);
fillServers(settingsXml, 'servers');
fillServers(settingsXml, 'oracleServers');
fillServerForGithub(settingsXml);
fillProperties(settingsXml);
addApacheSnapshots(settingsXml);
addSonatypeSnapshots(settingsXml);
addOracleRepo(settingsXml);
writeSettings(settingsPath, settingsXml);
core.saveState('maven-settings', 'ok');
}
@ -219,13 +259,15 @@ function cleanup() {
}
module.exports = {
getSettingsTemplate,
getTemplate,
writeSettings,
fillMirrors,
fillServers,
fillServerForGithub,
fillProperties,
addApacheSnapshots,
addSonatypeSnapshots,
addOracleRepo,
generate,
cleanup
}

View File

@ -24,8 +24,8 @@ THE SOFTWARE.
const os = require('os');
const process = require('process');
const DOMParser = require('xmldom').DOMParser;
const XMLSerializer = require('xmldom').XMLSerializer;
const DOMParser = require('@xmldom/xmldom').DOMParser;
const XMLSerializer = require('@xmldom/xmldom').XMLSerializer;
const fs = require('fs');
const path = require('path');
@ -38,6 +38,14 @@ const settingsPath = path.join(testHomePath, '.m2', 'settings.xml');
var consoleOutput = [];
function stringAsXml(str) {
return new DOMParser().parseFromString(str, 'text/xml');
}
function xmlAsString(xml) {
return new XMLSerializer().serializeToString(xml).replace(/^\s*$(?:\r\n?|\n)/gm, '');
}
beforeAll(() => {
if (!fs.existsSync(testHomePath)) {
fs.mkdirSync(testHomePath);
@ -51,7 +59,7 @@ beforeAll(() => {
});
beforeEach(() => {
xmlTestProfile = new DOMParser().parseFromString(`<settings>
xmlTestProfile = stringAsXml(`<settings>
<profiles>
<profile>
<id>_properties_</id>
@ -99,7 +107,7 @@ afterEach(() => {
});
test('template should be read', () => {
const template = settings.getSettingsTemplate();
const template = settings.getTemplate('settings.xml');
expect(template).toBeDefined();
});
@ -119,9 +127,9 @@ test('xml should be write', () => {
test('fillServers do nothing if no params', () => {
const xml = new DOMParser().parseFromString("<servers/>");
const xml = stringAsXml("<servers/>");
settings.fillServers(xml);
settings.fillServers(xml, 'servers');
const xmlStr = new XMLSerializer().serializeToString(xml);
@ -130,82 +138,243 @@ test('fillServers do nothing if no params', () => {
test('fillServers one server', () => {
const xml = new DOMParser().parseFromString("<servers/>");
const xml = stringAsXml("<servers/>");
process.env['INPUT_SERVERS'] = '[{"id": "id1", "username": "username1", "password":"password1"}]';
settings.fillServers(xml);
settings.fillServers(xml, 'servers');
const xmlStr = new XMLSerializer().serializeToString(xml);
expect(xmlAsString(xml)).toBe(`<servers>
<server>
<id>id1</id>
<username>username1</username>
<password>password1</password>
</server></servers>`);
expect(xmlStr).toBe("<servers>" +
"<server><id>id1</id><username>username1</username><password>password1</password></server>" +
"</servers>");
});
test('fillServers with username and configuration', () => {
const xml = stringAsXml("<servers/>");
process.env['INPUT_SERVERS'] = '[{"id": "id1", "username": "username", "configuration": {"prop1": "prop1Value", "prop2": "prop2Value"}}]';
settings.fillServers(xml, 'servers');
expect(xmlAsString(xml)).toBe(`<servers>
<server>
<id>id1</id>
<username>username</username>
<configuration><prop1>prop1Value</prop1><prop2>prop2Value</prop2></configuration>
</server></servers>`);
});
test('fillServers with username, password and configuration', () => {
const xml = stringAsXml("<servers/>");
process.env['INPUT_SERVERS'] = '[{"id": "id1", "username": "username", "password": "password", "configuration": {"prop1": "prop1Value", "prop2": "prop2Value"}}]';
settings.fillServers(xml, 'servers');
expect(xmlAsString(xml)).toBe(`<servers>
<server>
<id>id1</id>
<username>username</username>
<password>password</password>
<configuration><prop1>prop1Value</prop1><prop2>prop2Value</prop2></configuration>
</server></servers>`);
});
test('fillServers with username, privateKey', () => {
const xml = stringAsXml("<servers/>");
process.env['INPUT_SERVERS'] = '[{"id": "id1", "username": "username", "privateKey": "${user.home}/.ssh/id_rsa"}]';
settings.fillServers(xml, 'servers');
expect(xmlAsString(xml)).toBe(`<servers>
<server>
<id>id1</id>
<username>username</username>
<privateKey>\${user.home}/.ssh/id_rsa</privateKey>
</server></servers>`);
});
test('fillServers with username, privateKey, and passphrase', () => {
const xml = stringAsXml("<servers/>");
process.env['INPUT_SERVERS'] = '[{"id": "id1", "username": "username", "privateKey": "${user.home}/.ssh/id_rsa", "passphrase": "secret"}]';
settings.fillServers(xml, 'servers');
expect(xmlAsString(xml)).toBe(`<servers>
<server>
<id>id1</id>
<username>username</username>
<privateKey>\${user.home}/.ssh/id_rsa</privateKey>
<passphrase>secret</passphrase>
</server></servers>`);
});
test('fillServers with all attributes', () => {
const xml = stringAsXml("<servers/>");
process.env['INPUT_SERVERS'] = '[{"id": "server001", "username": "my_login", "password": "my_password", "privateKey": "${user.home}/.ssh/id_dsa", "passphrase": "some_passphrase", "filePermissions": "664", "directoryPermissions": "775", "configuration": {"prop1": "prop1Value", "prop2": "prop2Value"} }]';
settings.fillServers(xml, 'servers');
expect(xmlAsString(xml)).toBe(`<servers>
<server>
<id>server001</id>
<username>my_login</username>
<password>my_password</password>
<privateKey>\${user.home}/.ssh/id_dsa</privateKey>
<passphrase>some_passphrase</passphrase>
<filePermissions>664</filePermissions>
<directoryPermissions>775</directoryPermissions>
<configuration><prop1>prop1Value</prop1><prop2>prop2Value</prop2></configuration>
</server></servers>`);
});
test('fillServers with configuration', () => {
const xml = stringAsXml("<servers/>");
process.env['INPUT_SERVERS'] = '[{"id": "id1", "configuration": {"prop1": "prop1Value", "prop2": "prop2Value"}}]';
settings.fillServers(xml, 'servers');
expect(xmlAsString(xml)).toBe(`<servers>
<server>
<id>id1</id>
<configuration><prop1>prop1Value</prop1><prop2>prop2Value</prop2></configuration>
</server></servers>`);
});
test('fillServers with configuration subLevel', () => {
const xml = stringAsXml("<servers/>");
process.env['INPUT_SERVERS'] = '[{"id": "id1", "configuration": {"prop1": {"prop11": "value11", "prop12": "value12"}, "prop2": "value2"}}]';
settings.fillServers(xml, 'servers');
expect(xmlAsString(xml)).toBe(`<servers>
<server>
<id>id1</id>
<configuration><prop1><prop11>value11</prop11><prop12>value12</prop12></prop1><prop2>value2</prop2></configuration>
</server></servers>`);
});
test('fillServers two servers', () => {
const xml = new DOMParser().parseFromString("<servers/>");
const xml = stringAsXml("<servers/>");
process.env['INPUT_SERVERS'] = '[{"id": "id1", "username": "username1", "password":"password1"},\
{"id": "id2", "username": "username2", "password":"password2"}]';
settings.fillServers(xml);
settings.fillServers(xml, 'servers');
const xmlStr = new XMLSerializer().serializeToString(xml);
expect(xmlStr).toBe("<servers>" +
"<server><id>id1</id><username>username1</username><password>password1</password></server>" +
"<server><id>id2</id><username>username2</username><password>password2</password></server>" +
"</servers>");
expect(xmlAsString(xml)).toBe(`<servers>
<server>
<id>id1</id>
<username>username1</username>
<password>password1</password>
</server>
<server>
<id>id2</id>
<username>username2</username>
<password>password2</password>
</server></servers>`);
});
test('fillServers incorrect fields', () => {
test('fill servers incorrect fields', () => {
const xml = new DOMParser().parseFromString("<servers/>");
const xml = stringAsXml("<servers/>");
process.env['INPUT_SERVERS'] = '[{"idx": "id1"}]';
settings.fillServers(xml);
settings.fillServers(xml, 'servers');
const xmlStr = new XMLSerializer().serializeToString(xml);
expect(xmlStr).toBe('<servers/>');
expect(consoleOutput).toEqual(
expect.arrayContaining([
expect.stringMatching(/::error::servers must contain id, username and password/)
expect.stringMatching(/::error::servers must contain id, and username or configuration/)
])
);
});
test('fill oracleServers', () => {
const xml = stringAsXml("<servers/>");
process.env['INPUT_ORACLESERVERS'] = '[{"id": "id1", "username": "username1", "password":"password1"}]';
settings.fillServers(xml, 'oracleServers');
expect(xmlAsString(xml)).toBe(`<servers>
<server>
<id>id1</id>
<username>username1</username>
<password>password1</password>
<configuration>
<basicAuthScope>
<host>ANY</host>
<port>ANY</port>
<realm>OAM 11g</realm>
</basicAuthScope>
<httpConfiguration>
<all>
<params>
<property>
<name>http.protocol.allow-circular-redirects</name>
<value>%b,true</value>
</property>
</params>
</all>
</httpConfiguration>
</configuration>
</server></servers>`);
});
test('fillServers github', () => {
const xml = new DOMParser().parseFromString("<servers/>");
const xml = stringAsXml("<servers/>");
process.env['INPUT_GITHUBSERVER'] = 'true';
settings.fillServerForGithub(xml);
const xmlStr = new XMLSerializer().serializeToString(xml);
expect(xmlStr).toBe('<servers><server><id>github</id><username>${env.GITHUB_ACTOR}</username><password>${env.GITHUB_TOKEN}</password></server></servers>');
expect(xmlAsString(xml)).toBe(`<servers>
<server>
<id>github</id>
<username>\${env.GITHUB_ACTOR}</username>
<password>\${env.GITHUB_TOKEN}</password>
</server></servers>`);
expect(consoleOutput).toEqual([]);
});
test('fillMirrors do nothing if no params', () => {
const xml = new DOMParser().parseFromString("<mirrors/>");
const xml = stringAsXml("<mirrors/>");
settings.fillMirrors(xml);
const xmlStr = new XMLSerializer().serializeToString(xml);
expect(xmlStr).toBe("<mirrors/>");
expect(consoleOutput).toEqual([]);
});
test('fillMirrors one mirror', () => {
const xml = new DOMParser().parseFromString("<mirrors/>");
const xml = stringAsXml("<mirrors/>");
process.env['INPUT_MIRRORS'] = '[{"id": "id1", "name": "name", "mirrorOf":"mirrorOf", "url":"url"}]';
@ -213,14 +382,19 @@ test('fillMirrors one mirror', () => {
const xmlStr = new XMLSerializer().serializeToString(xml);
expect(xmlStr).toBe("<mirrors>" +
"<mirror><id>id1</id><name>name</name><mirrorOf>mirrorOf</mirrorOf><url>url</url></mirror>" +
"</mirrors>");
expect(xmlStr).toBe(`<mirrors>
<mirror>
<id>id1</id>
<name>name</name>
<mirrorOf>mirrorOf</mirrorOf>
<url>url</url>
</mirror></mirrors>`);
expect(consoleOutput).toEqual([]);
});
test('fillMirrors two mirrors', () => {
const xml = new DOMParser().parseFromString("<mirrors/>");
const xml = stringAsXml("<mirrors/>");
process.env['INPUT_MIRRORS'] = '[{"id": "id1", "name": "name1", "mirrorOf":"mirrorOf1", "url":"url1"},{"id": "id2", "name": "name2", "mirrorOf":"mirrorOf2", "url":"url2"}]';
@ -228,14 +402,25 @@ test('fillMirrors two mirrors', () => {
const xmlStr = new XMLSerializer().serializeToString(xml);
expect(xmlStr).toBe("<mirrors>" +
"<mirror><id>id1</id><name>name1</name><mirrorOf>mirrorOf1</mirrorOf><url>url1</url></mirror><mirror><id>id2</id><name>name2</name><mirrorOf>mirrorOf2</mirrorOf><url>url2</url></mirror>" +
"</mirrors>");
expect(xmlStr).toBe(`<mirrors>
<mirror>
<id>id1</id>
<name>name1</name>
<mirrorOf>mirrorOf1</mirrorOf>
<url>url1</url>
</mirror>
<mirror>
<id>id2</id>
<name>name2</name>
<mirrorOf>mirrorOf2</mirrorOf>
<url>url2</url>
</mirror></mirrors>`);
expect(consoleOutput).toEqual([]);
});
test('fillMirrors incorrect fields', () => {
const xml = new DOMParser().parseFromString("<mirrors/>");
const xml = stringAsXml("<mirrors/>");
process.env['INPUT_MIRRORS'] = '[{"idx": "id1"}]';
@ -251,56 +436,169 @@ test('fillMirrors incorrect fields', () => {
);
});
test('addSonatypeSnapshots activate', () => {
test('addApacheSnapshots', () => {
process.env['INPUT_APACHESNAPSHOTS'] = "true";
const xml = stringAsXml('<profiles/>');
settings.addApacheSnapshots(xml);
const xmlStr = new XMLSerializer().serializeToString(xml);
expect(xmlStr).toBe(`<profiles>
<profile>
<id>_apache-snapshots_</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<repositories>
<repository>
<id>apache.snapshots.https</id>
<url>https://repository.apache.org/snapshots/</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>apache.snapshots.https</id>
<url>https://repository.apache.org/snapshots/</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</pluginRepository>
</pluginRepositories>
</profile></profiles>`);
});
test('addSonatypeSnapshots', () => {
process.env['INPUT_SONATYPESNAPSHOTS'] = "true";
settings.addSonatypeSnapshots(xmlTestProfile);
const xml = stringAsXml('<profiles/>');
const xmlStr = new XMLSerializer().serializeToString(xmlTestProfile);
expect(xmlStr).toBe(`<settings>
<profiles>
<profile>
<id>_properties_</id>
<activation>
<activeByDefault>false</activeByDefault>
</activation>
<properties/>
</profile>
<profile>
<id>_sonatype-snapshots_</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
</profile>
</profiles>
</settings>`);
settings.addSonatypeSnapshots(xml);
const xmlStr = new XMLSerializer().serializeToString(xml);
expect(xmlStr).toBe(`<profiles>
<profile>
<id>_sonatype-snapshots_</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<repositories>
<repository>
<id>sonatype-snapshots</id>
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
<repository>
<id>ossrh</id>
<url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>sonatype-snapshots</id>
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</pluginRepository>
<pluginRepository>
<id>ossrh</id>
<url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</pluginRepository>
</pluginRepositories>
</profile></profiles>`);
});
test('addOracleRepo', () => {
process.env['INPUT_ORACLEREPO'] = "true";
const xml = stringAsXml('<profiles/>');
settings.addOracleRepo(xml);
const xmlStr = new XMLSerializer().serializeToString(xml);
expect(xmlStr).toBe(`<profiles>
<profile>
<id>_maven.oracle.com_</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<repositories>
<repository>
<id>maven.oracle.com</id>
<url>https://maven.oracle.com</url>
<releases>
<enabled>true</enabled>
</releases>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>maven.oracle.com</id>
<url>https://maven.oracle.com</url>
<releases>
<enabled>true</enabled>
</releases>
<snapshots>
<enabled>false</enabled>
</snapshots>
</pluginRepository>
</pluginRepositories>
</profile></profiles>`);
});
test('fillProperties', () => {
process.env['INPUT_PROPERTIES'] = '[{"propertyName1": "propertyValue1"}, {"propertyName2": "propertyValue2"}]';
settings.fillProperties(xmlTestProfile);
const xml = stringAsXml('<profiles/>');
const xmlStr = new XMLSerializer().serializeToString(xmlTestProfile);
expect(xmlStr).toBe(`<settings>
<profiles>
<profile>
<id>_properties_</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<properties><propertyName1>propertyValue1</propertyName1><propertyName2>propertyValue2</propertyName2></properties>
</profile>
<profile>
<id>_sonatype-snapshots_</id>
<activation>
<activeByDefault>false</activeByDefault>
</activation>
</profile>
</profiles>
</settings>`);
settings.fillProperties(xml);
const xmlStr = new XMLSerializer().serializeToString(xml);
expect(xmlStr).toBe(`<profiles>
<profile>
<id>_properties_</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<properties><propertyName1>propertyValue1</propertyName1><propertyName2>propertyValue2</propertyName2></properties>
</profile></profiles>`);
})
test('fillProperties do nothing if no params', () => {
@ -411,3 +709,18 @@ test('genereate - override', () => {
])
);
})
test('generate - custom path', () => {
if (!fs.existsSync(testHomePath)) {
fs.mkdirSync(testHomePath);
}
const mySettings = path.join(testHomePath, 'settings_custom.xml');
process.env['INPUT_PATH'] = mySettings;
settings.generate();
const settingsStatus = fs.lstatSync(mySettings);
expect(settingsStatus.isFile()).toBeTruthy();
expect(settingsStatus.size).toBeGreaterThan(0);
});

View File

@ -0,0 +1,31 @@
<profile>
<id>_apache-snapshots_</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<repositories>
<repository>
<id>apache.snapshots.https</id>
<url>https://repository.apache.org/snapshots/</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>apache.snapshots.https</id>
<url>https://repository.apache.org/snapshots/</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</pluginRepository>
</pluginRepositories>
</profile>

7
templates/mirrors.xml Normal file
View File

@ -0,0 +1,7 @@
<mirror>
<id/>
<name/>
<mirrorOf/>
<url/>
</mirror>

31
templates/oracle-repo.xml Normal file
View File

@ -0,0 +1,31 @@
<profile>
<id>_maven.oracle.com_</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<repositories>
<repository>
<id>maven.oracle.com</id>
<url>https://maven.oracle.com</url>
<releases>
<enabled>true</enabled>
</releases>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>maven.oracle.com</id>
<url>https://maven.oracle.com</url>
<releases>
<enabled>true</enabled>
</releases>
<snapshots>
<enabled>false</enabled>
</snapshots>
</pluginRepository>
</pluginRepositories>
</profile>

View File

@ -0,0 +1,27 @@
<server>
<id />
<username />
<password />
<privateKey />
<passphrase />
<filePermissions />
<directoryPermissions />
<configuration>
<basicAuthScope>
<host>ANY</host>
<port>ANY</port>
<realm>OAM 11g</realm>
</basicAuthScope>
<httpConfiguration>
<all>
<params>
<property>
<name>http.protocol.allow-circular-redirects</name>
<value>%b,true</value>
</property>
</params>
</all>
</httpConfiguration>
</configuration>
</server>

8
templates/properties.xml Normal file
View File

@ -0,0 +1,8 @@
<profile>
<id>_properties_</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<properties />
</profile>

11
templates/servers.xml Normal file
View File

@ -0,0 +1,11 @@
<server>
<id />
<username />
<password />
<privateKey />
<passphrase />
<filePermissions />
<directoryPermissions />
<configuration />
</server>

View File

@ -1,46 +1,6 @@
<settings>
<interactiveMode>false</interactiveMode>
<profiles>
<!-- generic ############################################################# -->
<profile>
<id>_properties_</id>
<activation>
<activeByDefault>false</activeByDefault>
</activation>
<properties />
</profile>
<!-- sonatype ############################################################# -->
<profile>
<id>_sonatype-snapshots_</id>
<activation>
<activeByDefault>false</activeByDefault>
</activation>
<repositories>
<repository>
<id>sonatype-snapshots</id>
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>sonatype-snapshots</id>
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</pluginRepository>
</pluginRepositories>
</profile>
</profiles>
<servers />
<mirrors />
<interactiveMode>false</interactiveMode>
<profiles/>
<servers />
<mirrors />
</settings>

View File

@ -0,0 +1,51 @@
<profile>
<id>_sonatype-snapshots_</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<repositories>
<repository>
<id>sonatype-snapshots</id>
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
<repository>
<id>ossrh</id>
<url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>sonatype-snapshots</id>
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</pluginRepository>
<pluginRepository>
<id>ossrh</id>
<url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</pluginRepository>
</pluginRepositories>
</profile>

9
update-readme.sh Executable file
View File

@ -0,0 +1,9 @@
#!/bin/sh
echo "old_version: $npm_old_version"
echo "new_version: $npm_new_version"
echo "package_name: $npm_package_name"
sed -i '' "s/$npm_package_name@v$npm_old_version/$npm_package_name@v$npm_new_version/g" README.md
git add README.md