@modernpoacher/deps 2.1.16 → 2.1.17
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/bin/common/index.mjs +4 -4
- package/package.json +2 -1
- package/src/common/git/index.mjs +4 -2
- package/src/index.mjs +4 -4
package/bin/common/index.mjs
CHANGED
|
@@ -2,6 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
import debug from 'debug'
|
|
4
4
|
|
|
5
|
+
import stripAnsi from 'strip-ansi'
|
|
6
|
+
|
|
5
7
|
import {
|
|
6
8
|
argv
|
|
7
9
|
} from 'node:process'
|
|
@@ -92,16 +94,14 @@ export function getArgs () {
|
|
|
92
94
|
}
|
|
93
95
|
|
|
94
96
|
function filter (v) {
|
|
95
|
-
return Boolean(v.trim())
|
|
97
|
+
return Boolean(stripAnsi(v).trim())
|
|
96
98
|
}
|
|
97
99
|
|
|
98
100
|
export function use (key) {
|
|
99
101
|
const log = debug(`@modernpoacher/deps:${key}`)
|
|
100
102
|
|
|
101
103
|
function write (v) {
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
if (s) log(s)
|
|
104
|
+
log(v.trimEnd())
|
|
105
105
|
}
|
|
106
106
|
|
|
107
107
|
return function use (value) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@modernpoacher/deps",
|
|
3
|
-
"version": "2.1.
|
|
3
|
+
"version": "2.1.17",
|
|
4
4
|
"description": "Update NPM package dependencies from the command line",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"deps",
|
|
@@ -55,6 +55,7 @@
|
|
|
55
55
|
"commander": "^12.1.0",
|
|
56
56
|
"debug": "^4.3.7",
|
|
57
57
|
"glob-all": "^3.3.1",
|
|
58
|
+
"strip-ansi": "^7.1.0",
|
|
58
59
|
"supports-color": "^9.4.0"
|
|
59
60
|
},
|
|
60
61
|
"devDependencies": {
|
package/src/common/git/index.mjs
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import debug from 'debug'
|
|
2
2
|
|
|
3
|
+
import stripAnsi from 'strip-ansi'
|
|
4
|
+
|
|
3
5
|
import {
|
|
4
6
|
normalize
|
|
5
7
|
} from 'node:path'
|
|
@@ -60,7 +62,7 @@ log(`\`git\` (${VERSION} - ${PLATFORM}) is awake`)
|
|
|
60
62
|
const trim = (v) => v.split(String.fromCharCode(10)).map((v) => v.trimEnd()).join(String.fromCharCode(10)).trim()
|
|
61
63
|
|
|
62
64
|
function filter (v) {
|
|
63
|
-
return Boolean(v.trim())
|
|
65
|
+
return Boolean(stripAnsi(v).trim())
|
|
64
66
|
}
|
|
65
67
|
|
|
66
68
|
export function getIsDirectory (directory) {
|
|
@@ -77,7 +79,7 @@ export function use (key) {
|
|
|
77
79
|
const log = debug(`@modernpoacher/deps:${key}`)
|
|
78
80
|
|
|
79
81
|
function write (v) {
|
|
80
|
-
|
|
82
|
+
log(v.trimEnd())
|
|
81
83
|
}
|
|
82
84
|
|
|
83
85
|
return function use (value) {
|
package/src/index.mjs
CHANGED
|
@@ -10,6 +10,8 @@
|
|
|
10
10
|
|
|
11
11
|
import debug from 'debug'
|
|
12
12
|
|
|
13
|
+
import stripAnsi from 'strip-ansi'
|
|
14
|
+
|
|
13
15
|
import {
|
|
14
16
|
normalize
|
|
15
17
|
} from 'node:path'
|
|
@@ -46,16 +48,14 @@ const log = debug('@modernpoacher/deps')
|
|
|
46
48
|
log(`\`deps\` (${VERSION} - ${PLATFORM}) is awake`)
|
|
47
49
|
|
|
48
50
|
function filter (v) {
|
|
49
|
-
return Boolean(v.trim())
|
|
51
|
+
return Boolean(stripAnsi(v).trim())
|
|
50
52
|
}
|
|
51
53
|
|
|
52
54
|
export function use (key) {
|
|
53
55
|
const log = debug(`@modernpoacher/deps:${key}`)
|
|
54
56
|
|
|
55
57
|
function write (v) {
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
if (s) log(s)
|
|
58
|
+
log(v.trimEnd())
|
|
59
59
|
}
|
|
60
60
|
|
|
61
61
|
return function use (value) {
|