chore: fix mess made by merge

This commit is contained in:
Federico Grandi
2020-12-19 21:44:23 +01:00
parent 6f812a4e2c
commit 9e04524704
3 changed files with 11 additions and 30 deletions

File diff suppressed because one or more lines are too long

10
package-lock.json generated
View File

@@ -1908,6 +1908,16 @@
"integrity": "sha512-yr2icI4glYaNG+KWONODapy2/jDdMSDnrONSjblABjD9B4Z5LgiircSt8m8sRZFNi08kG9Sm0uSHtEmP3zaEGg==",
"dev": true
},
"yamljs": {
"version": "0.3.0",
"resolved": "https://registry.npmjs.org/yamljs/-/yamljs-0.3.0.tgz",
"integrity": "sha512-C/FsVVhht4iPQYXOInoxUM/1ELSf9EsgKH34FofQOp6hwCPrW4vG4w5++TED3xRUo8gD7l0P1J1dLlDYzODsTQ==",
"dev": true,
"requires": {
"argparse": "^1.0.7",
"glob": "^7.0.5"
}
},
"yargs": {
"version": "15.4.1",
"resolved": "https://registry.npmjs.org/yargs/-/yargs-15.4.1.tgz",

View File

@@ -12,19 +12,6 @@ import simpleGit, { Response } from 'simple-git'
import YAML from 'js-yaml'
import { getInput, Input, log, outputs, parseBool, setOutput } from './util'
type Input =
| 'add'
| 'author_name'
| 'author_email'
| 'branch'
| 'cwd'
| 'message'
| 'pull_strategy'
| 'push'
| 'remove'
| 'signoff'
| 'tag'
const baseDir = path.join(process.cwd(), getInput('cwd') || '')
const git = simpleGit({ baseDir })
console.log(`Running in ${baseDir}`)
@@ -326,22 +313,6 @@ async function checkInputs() {
// #endregion
}
function getInput(name: Input) {
return getInputCore(name)
}
function parseBool(value: any) {
try {
const parsed = JSON.parse(value)
if (typeof parsed == 'boolean') return parsed
} catch {}
}
function log(err: any | Error, data?: any) {
if (data) console.log(data)
if (err) error(err)
}
async function add({ logWarning = true, ignoreErrors = false } = {}): Promise<
(void | Response<void>)[]
> {