ts-node-client 2.1.1 → 2.1.3

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/CHANGELOG.md ADDED
@@ -0,0 +1,14 @@
1
+ # ts-node-client
2
+
3
+ ## Changelog
4
+
5
+ All notable changes to this project will be documented in this file.
6
+
7
+ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
8
+ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
9
+
10
+
11
+ ## 2.1.3 - 2022-12-26
12
+
13
+ ### Changed
14
+ * Migrate versions of dependencies
package/README.md CHANGED
@@ -90,6 +90,7 @@ You should upgrade to 2.* versions of ts-node-client
90
90
 
91
91
  #### 2.1.*
92
92
  - Migrate 1.6.* - 1.8.* changes to version 2.1
93
+ - Bump dependencies
93
94
 
94
95
  #### 2.0.*
95
96
  - Support new scan tool and fix problem with programmatic API for >= npm@8.0.0
@@ -39,7 +39,7 @@ Scanner.prototype.scan = function scan(cb) {
39
39
  const dependency = self.walk(data);
40
40
  const result = new ScanResult(
41
41
  options.project,
42
- data.name,
42
+ data.name,
43
43
  `npm:${data.name}`,
44
44
  dependency
45
45
  );
@@ -74,15 +74,15 @@ Scanner.prototype.walk = function walk(npmDependency, level) {
74
74
  printDependency(npmDependency, level);
75
75
 
76
76
  if (npmDependency.name) {
77
- const dependency = new Dependency(
78
- npmDependency.name,
79
- npmDependency.version,
80
- 'npm',
81
- npmDependency.description,
82
- npmDependency.private,
83
- npmDependency.licenses || npmDependency.license,
84
- npmDependency.homepage,
85
- npmDependency.repository ? npmDependency.repository.url : undefined
77
+ const dependency = new Dependency(
78
+ npmDependency.name,
79
+ npmDependency.version,
80
+ 'npm',
81
+ npmDependency.description,
82
+ npmDependency.private,
83
+ npmDependency.licenses || npmDependency.license,
84
+ npmDependency.homepage,
85
+ npmDependency.repository ? npmDependency.repository.url : undefined
86
86
  );
87
87
 
88
88
  if (npmDependency.dependencies) {
package/lib/pkg.js CHANGED
@@ -29,7 +29,7 @@ PackageURL.get = function get(manager, org, key, version) {
29
29
 
30
30
  function fixPart(str) {
31
31
  const newStr = encodeURI(str);
32
- return newStr.replace('%3A', ':');
32
+ return newStr.split('%3A').join(':');
33
33
  }
34
34
 
35
35
  module.exports = PackageURL;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "ts-node-client",
3
3
  "description": "npm / node module to transfer dependency information to TrustSource server.",
4
- "version": "2.1.1",
4
+ "version": "2.1.3",
5
5
  "private": false,
6
6
  "homepage": "https://app.trustsource.io/",
7
7
  "author": {
@@ -30,19 +30,19 @@
30
30
  "precommit": "npm run lint && npm run test"
31
31
  },
32
32
  "dependencies": {
33
- "npm": "6.14.17",
34
- "axios": "0.26.1",
33
+ "npm": "6.14.18",
34
+ "axios": "1.2.1",
35
35
  "debuglog": "1.0.1",
36
- "semver": "7.3.5",
37
- "yargs": "^17.5.0"
36
+ "semver": "7.3.8",
37
+ "yargs": "17.6.2"
38
38
  },
39
39
  "devDependencies": {
40
- "eslint": "^8.15.0",
41
- "eslint-config-airbnb-base": "^15.0.0",
42
- "eslint-plugin-import": "^2.26.0",
43
- "eslint-plugin-sonarjs": "^0.13.0",
44
- "mocha": "^9.2.2",
45
- "nock": "^12.0.3"
40
+ "eslint": "8.30.0",
41
+ "eslint-config-airbnb-base": "15.0.0",
42
+ "eslint-plugin-import": "2.26.0",
43
+ "eslint-plugin-sonarjs": "0.17.0",
44
+ "mocha": "10.2.0",
45
+ "nock": "13.2.9"
46
46
  },
47
47
  "keywords": [
48
48
  "node",
@@ -36,23 +36,23 @@ describe('Dependency', () => {
36
36
  it('should set license as object', () => {
37
37
  assert.deepEqual(new Dependency('---', '---', '---', '', true, 'MIT').licenses[0], { name: 'MIT' });
38
38
  assert.deepEqual(new Dependency('---', '---', '---', '', true, { type: 'MIT' }).licenses[0], { name: 'MIT' });
39
- assert.deepEqual(
39
+ assert.deepEqual(
40
40
  new Dependency('---', '---', '---', '', true, { type: 'MIT', url: 'https://test' }).licenses[0],
41
- { name: 'MIT', url: 'https://test' }
41
+ { name: 'MIT', url: 'https://test' }
42
42
  );
43
43
  });
44
44
 
45
45
  it('should set license as array', () => {
46
- assert.deepEqual(
46
+ assert.deepEqual(
47
47
  new Dependency('---', '---', '---', '', true, ['MIT', 'Apache']).licenses,
48
- [{ name: 'MIT' }, { name: 'Apache' }]
48
+ [{ name: 'MIT' }, { name: 'Apache' }]
49
49
  );
50
50
  });
51
51
 
52
52
  it('should set license as array of objects', () => {
53
- assert.deepEqual(
53
+ assert.deepEqual(
54
54
  new Dependency('---', '---', '---', '', true, [{ type: 'MIT', url: 'url' }, { type: 'Apache' }]).licenses,
55
- [{ name: 'MIT', url: 'url' }, { name: 'Apache' }]
55
+ [{ name: 'MIT', url: 'url' }, { name: 'Apache' }]
56
56
  );
57
57
  });
58
58
 
@@ -148,31 +148,31 @@ describe('Dependency', () => {
148
148
  });
149
149
 
150
150
  it('should extract additional repo-protocol from url', () => {
151
- assert.deepEqual(
152
- new Dependency(
153
- 'name',
154
- 'version',
155
- '---',
156
- 'description',
157
- '---',
158
- '---',
159
- 'home',
160
- 'git+https://github.com/eacg-gmbh/ecs-grunt-plugin.git'
151
+ assert.deepEqual(
152
+ new Dependency(
153
+ 'name',
154
+ 'version',
155
+ '---',
156
+ 'description',
157
+ '---',
158
+ '---',
159
+ 'home',
160
+ 'git+https://github.com/eacg-gmbh/ecs-grunt-plugin.git'
161
161
  ).repoUrl,
162
- 'https://github.com/eacg-gmbh/ecs-grunt-plugin.git'
162
+ 'https://github.com/eacg-gmbh/ecs-grunt-plugin.git'
163
163
  );
164
- assert.deepEqual(
165
- new Dependency(
166
- 'name',
167
- 'version',
168
- '---',
169
- 'description',
170
- '---',
171
- '---',
172
- 'home',
173
- 'svn+http://svnrepo.com/test.svn'
164
+ assert.deepEqual(
165
+ new Dependency(
166
+ 'name',
167
+ 'version',
168
+ '---',
169
+ 'description',
170
+ '---',
171
+ '---',
172
+ 'home',
173
+ 'svn+http://svnrepo.com/test.svn'
174
174
  ).repoUrl,
175
- 'http://svnrepo.com/test.svn'
175
+ 'http://svnrepo.com/test.svn'
176
176
  );
177
177
  });
178
178
 
@@ -9,7 +9,7 @@
9
9
 
10
10
 
11
11
  const assert = require('assert');
12
- const util = require('util');
12
+ const util = require('util');
13
13
 
14
14
  const SHOULD_CONTAIN = 'should contain \'name\' and \'message\' fields';
15
15