ssh-config 4.4.0 → 4.4.2
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/package.json +1 -1
- package/src/ssh-config.js +7 -2
package/package.json
CHANGED
package/src/ssh-config.js
CHANGED
|
@@ -140,7 +140,6 @@ class SSHConfig extends Array {
|
|
|
140
140
|
}
|
|
141
141
|
}
|
|
142
142
|
}
|
|
143
|
-
console.log(canonicalizeHostName, canonicalDomains);
|
|
144
143
|
if (canonicalDomains.length > 0 && canonicalizeHostName) {
|
|
145
144
|
for (const domain of canonicalDomains) {
|
|
146
145
|
const host = `${line.value}.${domain}`;
|
|
@@ -358,6 +357,9 @@ function parse(text) {
|
|
|
358
357
|
else if (chr === '\\') {
|
|
359
358
|
escaped = true;
|
|
360
359
|
}
|
|
360
|
+
else if (chr === '#' && !quoted) {
|
|
361
|
+
break;
|
|
362
|
+
}
|
|
361
363
|
else {
|
|
362
364
|
val += chr;
|
|
363
365
|
}
|
|
@@ -399,13 +401,16 @@ function parse(text) {
|
|
|
399
401
|
else if (quoted) {
|
|
400
402
|
val += chr;
|
|
401
403
|
}
|
|
402
|
-
else if (/[ \t]/.test(chr)) {
|
|
404
|
+
else if (/[ \t=]/.test(chr)) {
|
|
403
405
|
if (val) {
|
|
404
406
|
results.push(val);
|
|
405
407
|
val = '';
|
|
406
408
|
}
|
|
407
409
|
// otherwise ignore the space
|
|
408
410
|
}
|
|
411
|
+
else if (chr === '#') {
|
|
412
|
+
break;
|
|
413
|
+
}
|
|
409
414
|
else {
|
|
410
415
|
val += chr;
|
|
411
416
|
}
|