npm-update-package 0.23.0 → 0.23.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -77,13 +77,23 @@ Pull request title template
77
77
  ## GitHub token
78
78
 
79
79
  GitHub token is required to run npm-update-package.
80
- For example, the following tokens can be used.
80
+ Available tokens and permissions required for each token are as follows.
81
81
 
82
- |GitHub token|Owner|Author of pull requests|Trigger other actions|
82
+ - [GitHub Actions](https://docs.github.com/en/actions/security-guides/automatic-token-authentication)
83
+ - [GitHub App](https://docs.github.com/en/developers/apps/building-github-apps/authenticating-with-github-apps)
84
+ - Contents: Read-only
85
+ - Metadata: Read-only
86
+ - Pull requests: Read & write
87
+ - [Personal access token](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token)
88
+ - repo
89
+
90
+ Features of each token are as follows.
91
+
92
+ ||GitHub Actions|GitHub App|Personal access token|
83
93
  |---|---|---|---|
84
- |[GitHub Actions](https://docs.github.com/en/actions/security-guides/automatic-token-authentication)|GitHub|`github-actions`||
85
- |[GitHub App](https://docs.github.com/en/developers/apps/building-github-apps/authenticating-with-github-apps)|organization or personal account|app which issued the token|✓|
86
- |[Personal access token](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token)|personal account|user who issued the token|✓|
94
+ |Owner of token|GitHub|organization or user|user|
95
+ |Author of pull requests|`github-actions`|app|user|
96
+ |Trigger other actions|-|✓|✓|
87
97
 
88
98
  We recommend using GitHub App for the following reasons.
89
99
 
@@ -93,20 +103,6 @@ We recommend using GitHub App for the following reasons.
93
103
 
94
104
  Creating a GitHub App may be tedious, but you only have to do it once the first time.
95
105
 
96
- ### Token of GitHub App
97
-
98
- These permissions are required.
99
-
100
- - Contents: Read-only
101
- - Metadata: Read-only
102
- - Pull requests: Read & write
103
-
104
- ### Personal access token
105
-
106
- These permissions are required.
107
-
108
- - repo
109
-
110
106
  ## Examples
111
107
 
112
108
  - Use token of GitHub Actions
package/dist/app.js CHANGED
@@ -3,6 +3,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.app = void 0;
4
4
  exports.app = {
5
5
  name: 'npm-update-package',
6
- version: '0.23.0',
6
+ version: '0.23.1',
7
7
  web: 'https://github.com/npm-update-package/npm-update-package'
8
8
  };
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.OutdatedPackagesProcessor = void 0;
4
+ // TODO: add test
4
5
  class OutdatedPackagesProcessor {
5
6
  constructor({ outdatedPackageProcessor, logger }) {
6
7
  this.outdatedPackageProcessor = outdatedPackageProcessor;
@@ -3,7 +3,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.createOctokit = void 0;
4
4
  const rest_1 = require("@octokit/rest");
5
5
  const app_1 = require("../app");
6
- // TODO: add test
7
6
  const createOctokit = ({ repository, token }) => {
8
7
  const auth = `token ${token}`;
9
8
  const userAgent = `${app_1.app.name}/${app_1.app.version}`;
@@ -2,7 +2,6 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.createPullRequestMetadata = void 0;
4
4
  const app_1 = require("../../../app");
5
- // TODO: Add test
6
5
  const createPullRequestMetadata = (outdatedPackages) => {
7
6
  return {
8
7
  version: app_1.app.version,
@@ -1,7 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.toJSON = void 0;
4
- // TODO: Add test
5
4
  const toJSON = (value, options) => {
6
5
  var _a;
7
6
  const pretty = (_a = options === null || options === void 0 ? void 0 : options.pretty) !== null && _a !== void 0 ? _a : false;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "npm-update-package",
3
- "version": "0.23.0",
3
+ "version": "0.23.1",
4
4
  "description": "CLI tool for creating pull requests to update npm packages",
5
5
  "scripts": {
6
6
  "build": "tsc --project tsconfig.build.json",
@@ -20,7 +20,7 @@
20
20
  "@octokit/rest": "18.12.0",
21
21
  "commander": "8.3.0",
22
22
  "execa": "5.1.1",
23
- "fp-ts": "2.11.7",
23
+ "fp-ts": "2.11.8",
24
24
  "io-ts": "2.2.16",
25
25
  "log4js": "6.3.0",
26
26
  "mustache": "4.1.0",
@@ -38,10 +38,10 @@
38
38
  "@types/parse-github-url": "1.0.0",
39
39
  "@types/semver": "7.3.9",
40
40
  "@typescript-eslint/eslint-plugin": "5.9.1",
41
- "eslint": "8.6.0",
41
+ "eslint": "8.7.0",
42
42
  "eslint-config-standard-with-typescript": "21.0.1",
43
43
  "eslint-plugin-import": "2.25.4",
44
- "eslint-plugin-jest": "25.3.4",
44
+ "eslint-plugin-jest": "25.7.0",
45
45
  "eslint-plugin-node": "11.1.0",
46
46
  "eslint-plugin-promise": "6.0.0",
47
47
  "eslint-plugin-tsdoc": "0.2.14",