Add missing types
This commit is contained in:
parent
7e7fa32a5f
commit
86ccd8cdef
4 changed files with 1921 additions and 1840 deletions
18
dist/index.js
vendored
18
dist/index.js
vendored
|
@ -4861,14 +4861,16 @@ function bytesToUuid(buf, offset) {
|
|||
var i = offset || 0;
|
||||
var bth = byteToHex;
|
||||
// join used to fix memory issue caused by concatenation: https://bugs.chromium.org/p/v8/issues/detail?id=3175#c4
|
||||
return ([bth[buf[i++]], bth[buf[i++]],
|
||||
bth[buf[i++]], bth[buf[i++]], '-',
|
||||
bth[buf[i++]], bth[buf[i++]], '-',
|
||||
bth[buf[i++]], bth[buf[i++]], '-',
|
||||
bth[buf[i++]], bth[buf[i++]], '-',
|
||||
bth[buf[i++]], bth[buf[i++]],
|
||||
bth[buf[i++]], bth[buf[i++]],
|
||||
bth[buf[i++]], bth[buf[i++]]]).join('');
|
||||
return ([
|
||||
bth[buf[i++]], bth[buf[i++]],
|
||||
bth[buf[i++]], bth[buf[i++]], '-',
|
||||
bth[buf[i++]], bth[buf[i++]], '-',
|
||||
bth[buf[i++]], bth[buf[i++]], '-',
|
||||
bth[buf[i++]], bth[buf[i++]], '-',
|
||||
bth[buf[i++]], bth[buf[i++]],
|
||||
bth[buf[i++]], bth[buf[i++]],
|
||||
bth[buf[i++]], bth[buf[i++]]
|
||||
]).join('');
|
||||
}
|
||||
|
||||
module.exports = bytesToUuid;
|
||||
|
|
3719
package-lock.json
generated
3719
package-lock.json
generated
File diff suppressed because it is too large
Load diff
22
src/git.ts
22
src/git.ts
|
@ -50,7 +50,11 @@ export async function execGit(
|
|||
return result
|
||||
}
|
||||
|
||||
export async function addConfigOption(repoPath, name, value): Promise<boolean> {
|
||||
export async function addConfigOption(
|
||||
repoPath: string,
|
||||
name: string,
|
||||
value: string
|
||||
): Promise<boolean> {
|
||||
const result = await execGit(
|
||||
repoPath,
|
||||
['config', '--local', '--add', name, value],
|
||||
|
@ -60,8 +64,8 @@ export async function addConfigOption(repoPath, name, value): Promise<boolean> {
|
|||
}
|
||||
|
||||
export async function unsetConfigOption(
|
||||
repoPath,
|
||||
name,
|
||||
repoPath: string,
|
||||
name: string,
|
||||
valueRegex = '.'
|
||||
): Promise<boolean> {
|
||||
const result = await execGit(
|
||||
|
@ -73,8 +77,8 @@ export async function unsetConfigOption(
|
|||
}
|
||||
|
||||
export async function configOptionExists(
|
||||
repoPath,
|
||||
name,
|
||||
repoPath: string,
|
||||
name: string,
|
||||
valueRegex = '.'
|
||||
): Promise<boolean> {
|
||||
const result = await execGit(
|
||||
|
@ -86,8 +90,8 @@ export async function configOptionExists(
|
|||
}
|
||||
|
||||
export async function getConfigOption(
|
||||
repoPath,
|
||||
name,
|
||||
repoPath: string,
|
||||
name: string,
|
||||
valueRegex = '.'
|
||||
): Promise<ConfigOption> {
|
||||
const option = new ConfigOption()
|
||||
|
@ -102,8 +106,8 @@ export async function getConfigOption(
|
|||
}
|
||||
|
||||
export async function getAndUnsetConfigOption(
|
||||
repoPath,
|
||||
name,
|
||||
repoPath: string,
|
||||
name: string,
|
||||
valueRegex = '.'
|
||||
): Promise<ConfigOption> {
|
||||
if (await configOptionExists(repoPath, name, valueRegex)) {
|
||||
|
|
|
@ -10,7 +10,7 @@ import * as semver from 'semver'
|
|||
* @param {string} versionSpec version of Python
|
||||
* @param {string} arch architecture (x64|x32)
|
||||
*/
|
||||
export function setupPython(versionSpec, arch): Promise<void> {
|
||||
export function setupPython(versionSpec: string, arch: string): Promise<void> {
|
||||
return new Promise(resolve => {
|
||||
const IS_WINDOWS = process.platform === 'win32'
|
||||
|
||||
|
|
Loading…
Reference in a new issue