tsds-lib-test 1.19.4 → 1.19.6
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.
|
@@ -16,110 +16,170 @@ var _path = /*#__PURE__*/ _interop_require_default(require("path"));
|
|
|
16
16
|
var _queuecb = /*#__PURE__*/ _interop_require_default(require("queue-cb"));
|
|
17
17
|
var _tsdslib = require("tsds-lib");
|
|
18
18
|
var _url = /*#__PURE__*/ _interop_require_default(require("url"));
|
|
19
|
+
function _define_property(obj, key, value) {
|
|
20
|
+
if (key in obj) {
|
|
21
|
+
Object.defineProperty(obj, key, {
|
|
22
|
+
value: value,
|
|
23
|
+
enumerable: true,
|
|
24
|
+
configurable: true,
|
|
25
|
+
writable: true
|
|
26
|
+
});
|
|
27
|
+
} else {
|
|
28
|
+
obj[key] = value;
|
|
29
|
+
}
|
|
30
|
+
return obj;
|
|
31
|
+
}
|
|
19
32
|
function _interop_require_default(obj) {
|
|
20
33
|
return obj && obj.__esModule ? obj : {
|
|
21
34
|
default: obj
|
|
22
35
|
};
|
|
23
36
|
}
|
|
37
|
+
function _object_spread(target) {
|
|
38
|
+
for(var i = 1; i < arguments.length; i++){
|
|
39
|
+
var source = arguments[i] != null ? arguments[i] : {};
|
|
40
|
+
var ownKeys = Object.keys(source);
|
|
41
|
+
if (typeof Object.getOwnPropertySymbols === "function") {
|
|
42
|
+
ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(source).filter(function(sym) {
|
|
43
|
+
return Object.getOwnPropertyDescriptor(source, sym).enumerable;
|
|
44
|
+
}));
|
|
45
|
+
}
|
|
46
|
+
ownKeys.forEach(function(key) {
|
|
47
|
+
_define_property(target, key, source[key]);
|
|
48
|
+
});
|
|
49
|
+
}
|
|
50
|
+
return target;
|
|
51
|
+
}
|
|
52
|
+
function ownKeys(object, enumerableOnly) {
|
|
53
|
+
var keys = Object.keys(object);
|
|
54
|
+
if (Object.getOwnPropertySymbols) {
|
|
55
|
+
var symbols = Object.getOwnPropertySymbols(object);
|
|
56
|
+
if (enumerableOnly) {
|
|
57
|
+
symbols = symbols.filter(function(sym) {
|
|
58
|
+
return Object.getOwnPropertyDescriptor(object, sym).enumerable;
|
|
59
|
+
});
|
|
60
|
+
}
|
|
61
|
+
keys.push.apply(keys, symbols);
|
|
62
|
+
}
|
|
63
|
+
return keys;
|
|
64
|
+
}
|
|
65
|
+
function _object_spread_props(target, source) {
|
|
66
|
+
source = source != null ? source : {};
|
|
67
|
+
if (Object.getOwnPropertyDescriptors) {
|
|
68
|
+
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
69
|
+
} else {
|
|
70
|
+
ownKeys(Object(source)).forEach(function(key) {
|
|
71
|
+
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
72
|
+
});
|
|
73
|
+
}
|
|
74
|
+
return target;
|
|
75
|
+
}
|
|
24
76
|
var __dirname = _path.default.dirname(typeof __filename === 'undefined' ? _url.default.fileURLToPath(require("url").pathToFileURL(__filename).toString()) : __filename);
|
|
25
77
|
var major = +process.versions.node.split('.')[0];
|
|
26
78
|
var dist = _path.default.join(__dirname, '..', '..');
|
|
27
79
|
var version = major > 14 ? 'local' : 'stable';
|
|
28
80
|
var workerWrapper = (0, _tsdslib.wrapWorker)(_path.default.join(dist, 'cjs', 'lib', 'installGitRepo.js'));
|
|
29
|
-
function
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
function
|
|
33
|
-
installOptions.clean ? (0, _fsremovecompat.safeRm)(dest, function() {
|
|
34
|
-
return callback(new Error('clone'));
|
|
35
|
-
}) : _fs.default.stat(dest, callback);
|
|
36
|
-
}
|
|
37
|
-
checkOrClean(dest, function(err) {
|
|
38
|
-
var queue = new _queuecb.default(1);
|
|
39
|
-
queue.defer(_mkdirpclassic.default.bind(null, dest));
|
|
40
|
-
// does not exist - clone
|
|
81
|
+
function spawnQuiet(command, args, options, callback) {
|
|
82
|
+
(0, _crossspawncb.default)(command, args, _object_spread_props(_object_spread({}, options), {
|
|
83
|
+
encoding: 'utf8'
|
|
84
|
+
}), function(err) {
|
|
41
85
|
if (err) {
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
} else {
|
|
51
|
-
// Remove stale lock files first
|
|
52
|
-
queue.defer(function(cb) {
|
|
53
|
-
var gitDir = _path.default.join(dest, '.git');
|
|
54
|
-
try {
|
|
55
|
-
var files = _fs.default.readdirSync(gitDir);
|
|
56
|
-
for(var i = 0; i < files.length; i++){
|
|
57
|
-
if (files[i].indexOf('.lock') >= 0) {
|
|
58
|
-
try {
|
|
59
|
-
_fs.default.unlinkSync(_path.default.join(gitDir, files[i]));
|
|
60
|
-
} catch (_e) {
|
|
61
|
-
/* ignore */ }
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
} catch (_e) {
|
|
65
|
-
/* ignore */ }
|
|
66
|
-
cb();
|
|
67
|
-
});
|
|
68
|
-
// Abort any in-progress merge/rebase (ignore errors if none in progress)
|
|
69
|
-
queue.defer(function(cb) {
|
|
70
|
-
return (0, _crossspawncb.default)('git', [
|
|
71
|
-
'merge',
|
|
72
|
-
'--abort'
|
|
73
|
-
], {
|
|
74
|
-
cwd: dest,
|
|
75
|
-
stdio: 'inherit'
|
|
76
|
-
}, function() {
|
|
77
|
-
return cb();
|
|
78
|
-
});
|
|
79
|
-
});
|
|
80
|
-
queue.defer(function(cb) {
|
|
81
|
-
return (0, _crossspawncb.default)('git', [
|
|
82
|
-
'rebase',
|
|
83
|
-
'--abort'
|
|
84
|
-
], {
|
|
85
|
-
cwd: dest,
|
|
86
|
-
stdio: 'inherit'
|
|
87
|
-
}, function() {
|
|
88
|
-
return cb();
|
|
89
|
-
});
|
|
90
|
-
});
|
|
91
|
-
queue.defer(_crossspawncb.default.bind(null, 'git', [
|
|
92
|
-
'clean',
|
|
93
|
-
'-fd'
|
|
94
|
-
], {
|
|
95
|
-
cwd: dest,
|
|
96
|
-
stdio: 'inherit'
|
|
97
|
-
}));
|
|
98
|
-
queue.defer(_crossspawncb.default.bind(null, 'git', [
|
|
99
|
-
'reset',
|
|
100
|
-
'--hard',
|
|
101
|
-
'HEAD'
|
|
102
|
-
], {
|
|
103
|
-
cwd: dest,
|
|
104
|
-
stdio: 'inherit'
|
|
105
|
-
}));
|
|
106
|
-
queue.defer(_crossspawncb.default.bind(null, 'git', [
|
|
107
|
-
'pull',
|
|
108
|
-
'--rebase'
|
|
109
|
-
], {
|
|
110
|
-
cwd: dest,
|
|
111
|
-
stdio: 'inherit'
|
|
112
|
-
}));
|
|
86
|
+
var qerr = err;
|
|
87
|
+
var cmdString = "".concat(command, " ").concat(args.join(' '));
|
|
88
|
+
qerr.message = "Command failed: ".concat(cmdString, "\n").concat(qerr.message);
|
|
89
|
+
qerr.command = command;
|
|
90
|
+
qerr.args = args;
|
|
91
|
+
qerr.cwd = options.cwd;
|
|
92
|
+
if (qerr.stderr) qerr.message += "\nstderr: ".concat(qerr.stderr);
|
|
93
|
+
if (qerr.stdout) qerr.message += "\nstdout: ".concat(qerr.stdout);
|
|
113
94
|
}
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
95
|
+
callback(err);
|
|
96
|
+
});
|
|
97
|
+
}
|
|
98
|
+
function checkDirectoryExists(dest, callback) {
|
|
99
|
+
_fs.default.stat(dest, function(err) {
|
|
100
|
+
if (err && err.code === 'ENOENT') callback(null, false);
|
|
101
|
+
else if (err) callback(err);
|
|
102
|
+
else callback(null, true);
|
|
121
103
|
});
|
|
122
104
|
}
|
|
105
|
+
function cloneRepository(repo, dest, callback) {
|
|
106
|
+
var parentDir = _path.default.dirname(dest);
|
|
107
|
+
var repoName = _path.default.basename(dest);
|
|
108
|
+
var queue = new _queuecb.default(1);
|
|
109
|
+
queue.defer(_mkdirpclassic.default.bind(null, dest));
|
|
110
|
+
queue.defer(_crossspawncb.default.bind(null, 'git', [
|
|
111
|
+
'clone',
|
|
112
|
+
repo,
|
|
113
|
+
repoName
|
|
114
|
+
], {
|
|
115
|
+
cwd: parentDir,
|
|
116
|
+
stdio: 'inherit'
|
|
117
|
+
}));
|
|
118
|
+
queue.await(callback);
|
|
119
|
+
}
|
|
120
|
+
function updateRepository(dest, callback) {
|
|
121
|
+
var queue = new _queuecb.default(1);
|
|
122
|
+
queue.defer(_crossspawncb.default.bind(null, 'git', [
|
|
123
|
+
'clean',
|
|
124
|
+
'-fd'
|
|
125
|
+
], {
|
|
126
|
+
cwd: dest,
|
|
127
|
+
stdio: 'inherit'
|
|
128
|
+
}));
|
|
129
|
+
queue.defer(_crossspawncb.default.bind(null, 'git', [
|
|
130
|
+
'reset',
|
|
131
|
+
'--hard',
|
|
132
|
+
'HEAD'
|
|
133
|
+
], {
|
|
134
|
+
cwd: dest,
|
|
135
|
+
stdio: 'inherit'
|
|
136
|
+
}));
|
|
137
|
+
queue.defer(_crossspawncb.default.bind(null, 'git', [
|
|
138
|
+
'pull',
|
|
139
|
+
'--rebase'
|
|
140
|
+
], {
|
|
141
|
+
cwd: dest,
|
|
142
|
+
stdio: 'inherit'
|
|
143
|
+
}));
|
|
144
|
+
queue.await(callback);
|
|
145
|
+
}
|
|
146
|
+
function installDependencies(dest, callback) {
|
|
147
|
+
spawnQuiet('npm', [
|
|
148
|
+
'install'
|
|
149
|
+
], {
|
|
150
|
+
cwd: dest
|
|
151
|
+
}, callback);
|
|
152
|
+
}
|
|
153
|
+
function cleanInstall(repo, dest, callback) {
|
|
154
|
+
var queue = new _queuecb.default(1);
|
|
155
|
+
queue.defer(_fsremovecompat.safeRm.bind(null, dest));
|
|
156
|
+
queue.defer(cloneRepository.bind(null, repo, dest));
|
|
157
|
+
queue.defer(installDependencies.bind(null, dest));
|
|
158
|
+
queue.await(callback);
|
|
159
|
+
}
|
|
160
|
+
function worker(repo, dest, options, callback) {
|
|
161
|
+
var installOptions = options;
|
|
162
|
+
if (installOptions.clean) {
|
|
163
|
+
cleanInstall(repo, dest, callback);
|
|
164
|
+
} else {
|
|
165
|
+
checkDirectoryExists(dest, function(err, exists) {
|
|
166
|
+
if (err) return callback(err);
|
|
167
|
+
var queue = new _queuecb.default(1);
|
|
168
|
+
if (!exists) {
|
|
169
|
+
queue.defer(cloneRepository.bind(null, repo, dest));
|
|
170
|
+
queue.defer(installDependencies.bind(null, dest));
|
|
171
|
+
} else {
|
|
172
|
+
queue.defer(function(cb) {
|
|
173
|
+
updateRepository(dest, function(err2) {
|
|
174
|
+
if (err2) return cleanInstall(repo, dest, cb);
|
|
175
|
+
installDependencies(dest, cb);
|
|
176
|
+
});
|
|
177
|
+
});
|
|
178
|
+
}
|
|
179
|
+
queue.await(callback);
|
|
180
|
+
});
|
|
181
|
+
}
|
|
182
|
+
}
|
|
123
183
|
function installGitRepo(repo, dest, options, callback) {
|
|
124
184
|
if (typeof options === 'function') {
|
|
125
185
|
callback = options;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["/Users/kevin/Dev/OpenSource/ts-dev-stack/tsds-lib-test/src/lib/installGitRepo.ts"],"sourcesContent":["import spawn from 'cross-spawn-cb';\nimport fs from 'fs';\nimport { safeRm } from 'fs-remove-compat';\nimport mkdirp from 'mkdirp-classic';\nimport path from 'path';\nimport Queue from 'queue-cb';\nimport type { CommandCallback, CommandOptions } from 'tsds-lib';\nimport { wrapWorker } from 'tsds-lib';\nimport url from 'url';\nimport type { InstallOptions } from '../types.ts';\n\nconst __dirname = path.dirname(typeof __filename === 'undefined' ? url.fileURLToPath(import.meta.url) : __filename);\nconst major = +process.versions.node.split('.')[0];\nconst dist = path.join(__dirname, '..', '..');\nconst version = major > 14 ? 'local' : 'stable';\nconst workerWrapper = wrapWorker(path.join(dist, 'cjs', 'lib', 'installGitRepo.js'));\n\
|
|
1
|
+
{"version":3,"sources":["/Users/kevin/Dev/OpenSource/ts-dev-stack/tsds-lib-test/src/lib/installGitRepo.ts"],"sourcesContent":["import spawn, { type SpawnError } from 'cross-spawn-cb';\nimport fs from 'fs';\nimport { safeRm } from 'fs-remove-compat';\nimport mkdirp from 'mkdirp-classic';\nimport path from 'path';\nimport Queue from 'queue-cb';\nimport type { CommandCallback, CommandOptions } from 'tsds-lib';\nimport { wrapWorker } from 'tsds-lib';\nimport url from 'url';\nimport type { InstallOptions } from '../types.ts';\n\nconst __dirname = path.dirname(typeof __filename === 'undefined' ? url.fileURLToPath(import.meta.url) : __filename);\nconst major = +process.versions.node.split('.')[0];\nconst dist = path.join(__dirname, '..', '..');\nconst version = major > 14 ? 'local' : 'stable';\nconst workerWrapper = wrapWorker(path.join(dist, 'cjs', 'lib', 'installGitRepo.js'));\n\ninterface QuietSpawnError extends SpawnError {\n command?: string;\n args?: string[];\n cwd?: string;\n}\n\nfunction spawnQuiet(command: string, args: string[], options: { cwd: string }, callback: (err?: Error | null) => void) {\n spawn(command, args, { ...options, encoding: 'utf8' }, (err?: SpawnError) => {\n if (err) {\n const qerr = err as QuietSpawnError;\n const cmdString = `${command} ${args.join(' ')}`;\n qerr.message = `Command failed: ${cmdString}\\n${qerr.message}`;\n qerr.command = command;\n qerr.args = args;\n qerr.cwd = options.cwd;\n if (qerr.stderr) qerr.message += `\\nstderr: ${qerr.stderr}`;\n if (qerr.stdout) qerr.message += `\\nstdout: ${qerr.stdout}`;\n }\n callback(err);\n });\n}\n\nfunction checkDirectoryExists(dest: string, callback: (err: Error | null, exists?: boolean) => void) {\n fs.stat(dest, (err) => {\n if (err && err.code === 'ENOENT') callback(null, false);\n else if (err) callback(err);\n else callback(null, true);\n });\n}\n\nfunction cloneRepository(repo: string, dest: string, callback) {\n const parentDir = path.dirname(dest);\n const repoName = path.basename(dest);\n const queue = new Queue(1);\n queue.defer(mkdirp.bind(null, dest));\n queue.defer(spawn.bind(null, 'git', ['clone', repo, repoName], { cwd: parentDir, stdio: 'inherit' }));\n queue.await(callback);\n}\n\nfunction updateRepository(dest: string, callback) {\n const queue = new Queue(1);\n queue.defer(spawn.bind(null, 'git', ['clean', '-fd'], { cwd: dest, stdio: 'inherit' }));\n queue.defer(spawn.bind(null, 'git', ['reset', '--hard', 'HEAD'], { cwd: dest, stdio: 'inherit' }));\n queue.defer(spawn.bind(null, 'git', ['pull', '--rebase'], { cwd: dest, stdio: 'inherit' }));\n queue.await(callback);\n}\n\nfunction installDependencies(dest: string, callback) {\n spawnQuiet('npm', ['install'], { cwd: dest }, callback);\n}\n\nfunction cleanInstall(repo: string, dest: string, callback) {\n const queue = new Queue(1);\n queue.defer(safeRm.bind(null, dest));\n queue.defer(cloneRepository.bind(null, repo, dest));\n queue.defer(installDependencies.bind(null, dest));\n queue.await(callback);\n}\n\nfunction worker(repo: string, dest: string, options: CommandOptions | InstallOptions, callback: CommandCallback) {\n const installOptions = options as InstallOptions;\n\n if (installOptions.clean) {\n cleanInstall(repo, dest, callback);\n } else {\n checkDirectoryExists(dest, (err, exists) => {\n if (err) return callback(err);\n const queue = new Queue(1);\n if (!exists) {\n queue.defer(cloneRepository.bind(null, repo, dest));\n queue.defer(installDependencies.bind(null, dest));\n } else {\n queue.defer((cb) => {\n updateRepository(dest, (err2) => {\n if (err2) return cleanInstall(repo, dest, cb);\n installDependencies(dest, cb);\n });\n });\n }\n queue.await(callback);\n });\n }\n}\n\nexport default function installGitRepo(repo: string, dest: string, options: CommandOptions | CommandCallback, callback?: CommandCallback): undefined {\n if (typeof options === 'function') {\n callback = options;\n options = {};\n }\n options = options || {};\n version !== 'local' ? workerWrapper(version, repo, dest, options, callback) : worker(repo, dest, options, callback);\n}\n"],"names":["installGitRepo","__dirname","path","dirname","__filename","url","fileURLToPath","major","process","versions","node","split","dist","join","version","workerWrapper","wrapWorker","spawnQuiet","command","args","options","callback","spawn","encoding","err","qerr","cmdString","message","cwd","stderr","stdout","checkDirectoryExists","dest","fs","stat","code","cloneRepository","repo","parentDir","repoName","basename","queue","Queue","defer","mkdirp","bind","stdio","await","updateRepository","installDependencies","cleanInst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versions.node.split('.')[0];
|
|
|
11
11
|
const dist = path.join(__dirname, '..', '..');
|
|
12
12
|
const version = major > 14 ? 'local' : 'stable';
|
|
13
13
|
const workerWrapper = wrapWorker(path.join(dist, 'cjs', 'lib', 'installGitRepo.js'));
|
|
14
|
-
function
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
}
|
|
20
|
-
checkOrClean(dest, (err)=>{
|
|
21
|
-
const queue = new Queue(1);
|
|
22
|
-
queue.defer(mkdirp.bind(null, dest));
|
|
23
|
-
// does not exist - clone
|
|
14
|
+
function spawnQuiet(command, args, options, callback) {
|
|
15
|
+
spawn(command, args, {
|
|
16
|
+
...options,
|
|
17
|
+
encoding: 'utf8'
|
|
18
|
+
}, (err)=>{
|
|
24
19
|
if (err) {
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
}
|
|
33
|
-
} else {
|
|
34
|
-
// Remove stale lock files first
|
|
35
|
-
queue.defer((cb)=>{
|
|
36
|
-
const gitDir = path.join(dest, '.git');
|
|
37
|
-
try {
|
|
38
|
-
const files = fs.readdirSync(gitDir);
|
|
39
|
-
for(let i = 0; i < files.length; i++){
|
|
40
|
-
if (files[i].indexOf('.lock') >= 0) {
|
|
41
|
-
try {
|
|
42
|
-
fs.unlinkSync(path.join(gitDir, files[i]));
|
|
43
|
-
} catch (_e) {
|
|
44
|
-
/* ignore */ }
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
} catch (_e) {
|
|
48
|
-
/* ignore */ }
|
|
49
|
-
cb();
|
|
50
|
-
});
|
|
51
|
-
// Abort any in-progress merge/rebase (ignore errors if none in progress)
|
|
52
|
-
queue.defer((cb)=>spawn('git', [
|
|
53
|
-
'merge',
|
|
54
|
-
'--abort'
|
|
55
|
-
], {
|
|
56
|
-
cwd: dest,
|
|
57
|
-
stdio: 'inherit'
|
|
58
|
-
}, ()=>cb()));
|
|
59
|
-
queue.defer((cb)=>spawn('git', [
|
|
60
|
-
'rebase',
|
|
61
|
-
'--abort'
|
|
62
|
-
], {
|
|
63
|
-
cwd: dest,
|
|
64
|
-
stdio: 'inherit'
|
|
65
|
-
}, ()=>cb()));
|
|
66
|
-
queue.defer(spawn.bind(null, 'git', [
|
|
67
|
-
'clean',
|
|
68
|
-
'-fd'
|
|
69
|
-
], {
|
|
70
|
-
cwd: dest,
|
|
71
|
-
stdio: 'inherit'
|
|
72
|
-
}));
|
|
73
|
-
queue.defer(spawn.bind(null, 'git', [
|
|
74
|
-
'reset',
|
|
75
|
-
'--hard',
|
|
76
|
-
'HEAD'
|
|
77
|
-
], {
|
|
78
|
-
cwd: dest,
|
|
79
|
-
stdio: 'inherit'
|
|
80
|
-
}));
|
|
81
|
-
queue.defer(spawn.bind(null, 'git', [
|
|
82
|
-
'pull',
|
|
83
|
-
'--rebase'
|
|
84
|
-
], {
|
|
85
|
-
cwd: dest,
|
|
86
|
-
stdio: 'inherit'
|
|
87
|
-
}));
|
|
20
|
+
const qerr = err;
|
|
21
|
+
const cmdString = `${command} ${args.join(' ')}`;
|
|
22
|
+
qerr.message = `Command failed: ${cmdString}\n${qerr.message}`;
|
|
23
|
+
qerr.command = command;
|
|
24
|
+
qerr.args = args;
|
|
25
|
+
qerr.cwd = options.cwd;
|
|
26
|
+
if (qerr.stderr) qerr.message += `\nstderr: ${qerr.stderr}`;
|
|
27
|
+
if (qerr.stdout) qerr.message += `\nstdout: ${qerr.stdout}`;
|
|
88
28
|
}
|
|
89
|
-
|
|
90
|
-
'install',
|
|
91
|
-
'--silent'
|
|
92
|
-
], {
|
|
93
|
-
cwd: dest
|
|
94
|
-
}));
|
|
95
|
-
queue.await(callback);
|
|
29
|
+
callback(err);
|
|
96
30
|
});
|
|
97
31
|
}
|
|
32
|
+
function checkDirectoryExists(dest, callback) {
|
|
33
|
+
fs.stat(dest, (err)=>{
|
|
34
|
+
if (err && err.code === 'ENOENT') callback(null, false);
|
|
35
|
+
else if (err) callback(err);
|
|
36
|
+
else callback(null, true);
|
|
37
|
+
});
|
|
38
|
+
}
|
|
39
|
+
function cloneRepository(repo, dest, callback) {
|
|
40
|
+
const parentDir = path.dirname(dest);
|
|
41
|
+
const repoName = path.basename(dest);
|
|
42
|
+
const queue = new Queue(1);
|
|
43
|
+
queue.defer(mkdirp.bind(null, dest));
|
|
44
|
+
queue.defer(spawn.bind(null, 'git', [
|
|
45
|
+
'clone',
|
|
46
|
+
repo,
|
|
47
|
+
repoName
|
|
48
|
+
], {
|
|
49
|
+
cwd: parentDir,
|
|
50
|
+
stdio: 'inherit'
|
|
51
|
+
}));
|
|
52
|
+
queue.await(callback);
|
|
53
|
+
}
|
|
54
|
+
function updateRepository(dest, callback) {
|
|
55
|
+
const queue = new Queue(1);
|
|
56
|
+
queue.defer(spawn.bind(null, 'git', [
|
|
57
|
+
'clean',
|
|
58
|
+
'-fd'
|
|
59
|
+
], {
|
|
60
|
+
cwd: dest,
|
|
61
|
+
stdio: 'inherit'
|
|
62
|
+
}));
|
|
63
|
+
queue.defer(spawn.bind(null, 'git', [
|
|
64
|
+
'reset',
|
|
65
|
+
'--hard',
|
|
66
|
+
'HEAD'
|
|
67
|
+
], {
|
|
68
|
+
cwd: dest,
|
|
69
|
+
stdio: 'inherit'
|
|
70
|
+
}));
|
|
71
|
+
queue.defer(spawn.bind(null, 'git', [
|
|
72
|
+
'pull',
|
|
73
|
+
'--rebase'
|
|
74
|
+
], {
|
|
75
|
+
cwd: dest,
|
|
76
|
+
stdio: 'inherit'
|
|
77
|
+
}));
|
|
78
|
+
queue.await(callback);
|
|
79
|
+
}
|
|
80
|
+
function installDependencies(dest, callback) {
|
|
81
|
+
spawnQuiet('npm', [
|
|
82
|
+
'install'
|
|
83
|
+
], {
|
|
84
|
+
cwd: dest
|
|
85
|
+
}, callback);
|
|
86
|
+
}
|
|
87
|
+
function cleanInstall(repo, dest, callback) {
|
|
88
|
+
const queue = new Queue(1);
|
|
89
|
+
queue.defer(safeRm.bind(null, dest));
|
|
90
|
+
queue.defer(cloneRepository.bind(null, repo, dest));
|
|
91
|
+
queue.defer(installDependencies.bind(null, dest));
|
|
92
|
+
queue.await(callback);
|
|
93
|
+
}
|
|
94
|
+
function worker(repo, dest, options, callback) {
|
|
95
|
+
const installOptions = options;
|
|
96
|
+
if (installOptions.clean) {
|
|
97
|
+
cleanInstall(repo, dest, callback);
|
|
98
|
+
} else {
|
|
99
|
+
checkDirectoryExists(dest, (err, exists)=>{
|
|
100
|
+
if (err) return callback(err);
|
|
101
|
+
const queue = new Queue(1);
|
|
102
|
+
if (!exists) {
|
|
103
|
+
queue.defer(cloneRepository.bind(null, repo, dest));
|
|
104
|
+
queue.defer(installDependencies.bind(null, dest));
|
|
105
|
+
} else {
|
|
106
|
+
queue.defer((cb)=>{
|
|
107
|
+
updateRepository(dest, (err2)=>{
|
|
108
|
+
if (err2) return cleanInstall(repo, dest, cb);
|
|
109
|
+
installDependencies(dest, cb);
|
|
110
|
+
});
|
|
111
|
+
});
|
|
112
|
+
}
|
|
113
|
+
queue.await(callback);
|
|
114
|
+
});
|
|
115
|
+
}
|
|
116
|
+
}
|
|
98
117
|
export default function installGitRepo(repo, dest, options, callback) {
|
|
99
118
|
if (typeof options === 'function') {
|
|
100
119
|
callback = options;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["/Users/kevin/Dev/OpenSource/ts-dev-stack/tsds-lib-test/src/lib/installGitRepo.ts"],"sourcesContent":["import spawn from 'cross-spawn-cb';\nimport fs from 'fs';\nimport { safeRm } from 'fs-remove-compat';\nimport mkdirp from 'mkdirp-classic';\nimport path from 'path';\nimport Queue from 'queue-cb';\nimport type { CommandCallback, CommandOptions } from 'tsds-lib';\nimport { wrapWorker } from 'tsds-lib';\nimport url from 'url';\nimport type { InstallOptions } from '../types.ts';\n\nconst __dirname = path.dirname(typeof __filename === 'undefined' ? url.fileURLToPath(import.meta.url) : __filename);\nconst major = +process.versions.node.split('.')[0];\nconst dist = path.join(__dirname, '..', '..');\nconst version = major > 14 ? 'local' : 'stable';\nconst workerWrapper = wrapWorker(path.join(dist, 'cjs', 'lib', 'installGitRepo.js'));\n\
|
|
1
|
+
{"version":3,"sources":["/Users/kevin/Dev/OpenSource/ts-dev-stack/tsds-lib-test/src/lib/installGitRepo.ts"],"sourcesContent":["import spawn, { type SpawnError } from 'cross-spawn-cb';\nimport fs from 'fs';\nimport { safeRm } from 'fs-remove-compat';\nimport mkdirp from 'mkdirp-classic';\nimport path from 'path';\nimport Queue from 'queue-cb';\nimport type { CommandCallback, CommandOptions } from 'tsds-lib';\nimport { wrapWorker } from 'tsds-lib';\nimport url from 'url';\nimport type { InstallOptions } from '../types.ts';\n\nconst __dirname = path.dirname(typeof __filename === 'undefined' ? url.fileURLToPath(import.meta.url) : __filename);\nconst major = +process.versions.node.split('.')[0];\nconst dist = path.join(__dirname, '..', '..');\nconst version = major > 14 ? 'local' : 'stable';\nconst workerWrapper = wrapWorker(path.join(dist, 'cjs', 'lib', 'installGitRepo.js'));\n\ninterface QuietSpawnError extends SpawnError {\n command?: string;\n args?: string[];\n cwd?: string;\n}\n\nfunction spawnQuiet(command: string, args: string[], options: { cwd: string }, callback: (err?: Error | null) => void) {\n spawn(command, args, { ...options, encoding: 'utf8' }, (err?: SpawnError) => {\n if (err) {\n const qerr = err as QuietSpawnError;\n const cmdString = `${command} ${args.join(' ')}`;\n qerr.message = `Command failed: ${cmdString}\\n${qerr.message}`;\n qerr.command = command;\n qerr.args = args;\n qerr.cwd = options.cwd;\n if (qerr.stderr) qerr.message += `\\nstderr: ${qerr.stderr}`;\n if (qerr.stdout) qerr.message += `\\nstdout: ${qerr.stdout}`;\n }\n callback(err);\n });\n}\n\nfunction checkDirectoryExists(dest: string, callback: (err: Error | null, exists?: boolean) => void) {\n fs.stat(dest, (err) => {\n if (err && err.code === 'ENOENT') callback(null, false);\n else if (err) callback(err);\n else callback(null, true);\n });\n}\n\nfunction cloneRepository(repo: string, dest: string, callback) {\n const parentDir = path.dirname(dest);\n const repoName = path.basename(dest);\n const queue = new Queue(1);\n queue.defer(mkdirp.bind(null, dest));\n queue.defer(spawn.bind(null, 'git', ['clone', repo, repoName], { cwd: parentDir, stdio: 'inherit' }));\n queue.await(callback);\n}\n\nfunction updateRepository(dest: string, callback) {\n const queue = new Queue(1);\n queue.defer(spawn.bind(null, 'git', ['clean', '-fd'], { cwd: dest, stdio: 'inherit' }));\n queue.defer(spawn.bind(null, 'git', ['reset', '--hard', 'HEAD'], { cwd: dest, stdio: 'inherit' }));\n queue.defer(spawn.bind(null, 'git', ['pull', '--rebase'], { cwd: dest, stdio: 'inherit' }));\n queue.await(callback);\n}\n\nfunction installDependencies(dest: string, callback) {\n spawnQuiet('npm', ['install'], { cwd: dest }, callback);\n}\n\nfunction cleanInstall(repo: string, dest: string, callback) {\n const queue = new Queue(1);\n queue.defer(safeRm.bind(null, dest));\n queue.defer(cloneRepository.bind(null, repo, dest));\n queue.defer(installDependencies.bind(null, dest));\n queue.await(callback);\n}\n\nfunction worker(repo: string, dest: string, options: CommandOptions | InstallOptions, callback: CommandCallback) {\n const installOptions = options as InstallOptions;\n\n if (installOptions.clean) {\n cleanInstall(repo, dest, callback);\n } else {\n checkDirectoryExists(dest, (err, exists) => {\n if (err) return callback(err);\n const queue = new Queue(1);\n if (!exists) {\n queue.defer(cloneRepository.bind(null, repo, dest));\n queue.defer(installDependencies.bind(null, dest));\n } else {\n queue.defer((cb) => {\n updateRepository(dest, (err2) => {\n if (err2) return cleanInstall(repo, dest, cb);\n installDependencies(dest, cb);\n });\n });\n }\n queue.await(callback);\n });\n }\n}\n\nexport default function installGitRepo(repo: string, dest: string, options: CommandOptions | CommandCallback, callback?: CommandCallback): undefined {\n if (typeof options === 'function') {\n callback = options;\n options = {};\n }\n options = options || {};\n version !== 'local' ? workerWrapper(version, repo, dest, options, callback) : worker(repo, dest, options, callback);\n}\n"],"names":["spawn","fs","safeRm","mkdirp","path","Queue","wrapWorker","url","__dirname","dirname","__filename","fileURLToPath","major","process","versions","node","split","dist","join","version","workerWrapper","spawnQuiet","command","args","options","callback","encoding","err","qerr","cmdString","message","cwd","stderr","stdout","checkDirectoryExists","dest","stat","code","cloneRepository","repo","parentDir","repoName","basename","queue","defer","bind","stdio","await","updateRepository","installDependencies","cleanInstall","worker","installOptions","clean","exists","cb","err2","installGitRepo"],"mappings":"AAAA,OAAOA,WAAgC,iBAAiB;AACxD,OAAOC,QAAQ,KAAK;AACpB,SAASC,MAAM,QAAQ,mBAAmB;AAC1C,OAAOC,YAAY,iBAAiB;AACpC,OAAOC,UAAU,OAAO;AACxB,OAAOC,WAAW,WAAW;AAE7B,SAASC,UAAU,QAAQ,WAAW;AACtC,OAAOC,SAAS,MAAM;AAGtB,MAAMC,YAAYJ,KAAKK,OAAO,CAAC,OAAOC,eAAe,cAAcH,IAAII,aAAa,CAAC,YAAYJ,GAAG,IAAIG;AACxG,MAAME,QAAQ,CAACC,QAAQC,QAAQ,CAACC,IAAI,CAACC,KAAK,CAAC,IAAI,CAAC,EAAE;AAClD,MAAMC,OAAOb,KAAKc,IAAI,CAACV,WAAW,MAAM;AACxC,MAAMW,UAAUP,QAAQ,KAAK,UAAU;AACvC,MAAMQ,gBAAgBd,WAAWF,KAAKc,IAAI,CAACD,MAAM,OAAO,OAAO;AAQ/D,SAASI,WAAWC,OAAe,EAAEC,IAAc,EAAEC,OAAwB,EAAEC,QAAsC;IACnHzB,MAAMsB,SAASC,MAAM;QAAE,GAAGC,OAAO;QAAEE,UAAU;IAAO,GAAG,CAACC;QACtD,IAAIA,KAAK;YACP,MAAMC,OAAOD;YACb,MAAME,YAAY,GAAGP,QAAQ,CAAC,EAAEC,KAAKL,IAAI,CAAC,MAAM;YAChDU,KAAKE,OAAO,GAAG,CAAC,gBAAgB,EAAED,UAAU,EAAE,EAAED,KAAKE,OAAO,EAAE;YAC9DF,KAAKN,OAAO,GAAGA;YACfM,KAAKL,IAAI,GAAGA;YACZK,KAAKG,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0B;IACtI,IAAI,OAAOD,YAAY,YAAY;QACjCC,WAAWD;QACXA,UAAU,CAAC;IACb;IACAA,UAAUA,WAAW,CAAC;IACtBL,YAAY,UAAUC,cAAcD,SAASoB,MAAMJ,MAAMX,SAASC,YAAY0B,OAAOZ,MAAMJ,MAAMX,SAASC;AAC5G"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "tsds-lib-test",
|
|
3
|
-
"version": "1.19.
|
|
3
|
+
"version": "1.19.6",
|
|
4
4
|
"description": "Development stack for TypeScript libraries",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"dev",
|
|
@@ -39,23 +39,20 @@
|
|
|
39
39
|
"version": "tsds version"
|
|
40
40
|
},
|
|
41
41
|
"dependencies": {
|
|
42
|
-
"cross-spawn-cb": "
|
|
43
|
-
"fs-remove-compat": "
|
|
44
|
-
"mkdirp-classic": "
|
|
45
|
-
"queue-cb": "
|
|
46
|
-
"tsds-lib": "
|
|
42
|
+
"cross-spawn-cb": "^2.4.14",
|
|
43
|
+
"fs-remove-compat": "^0.2.3",
|
|
44
|
+
"mkdirp-classic": "^0.5.3",
|
|
45
|
+
"queue-cb": "^1.6.3",
|
|
46
|
+
"tsds-lib": "^1.20.0"
|
|
47
47
|
},
|
|
48
48
|
"devDependencies": {
|
|
49
|
-
"@types/mocha": "
|
|
50
|
-
"@types/node": "
|
|
51
|
-
"
|
|
52
|
-
"
|
|
53
|
-
"
|
|
54
|
-
"
|
|
55
|
-
"
|
|
56
|
-
"ts-dev-stack": "*",
|
|
57
|
-
"ts-swc-loaders": "*",
|
|
58
|
-
"tsds-config": "*"
|
|
49
|
+
"@types/mocha": "^10.0.10",
|
|
50
|
+
"@types/node": "^25.0.1",
|
|
51
|
+
"node-version-use": "^2.1.6",
|
|
52
|
+
"os-shim": "^0.1.3",
|
|
53
|
+
"short-hash": "^1.0.0",
|
|
54
|
+
"ts-dev-stack": "^1.21.3",
|
|
55
|
+
"tsds-config": "^0.2.1"
|
|
59
56
|
},
|
|
60
57
|
"engines": {
|
|
61
58
|
"node": ">=0.8"
|