PHP WebShell
Текущая директория: /opt/BitGoJS/node_modules/@lerna/diff/lib
Просмотр файла: has-commit.js
"use strict";
const log = require("npmlog");
const childProcess = require("@lerna/child-process");
module.exports.hasCommit = hasCommit;
/**
* @param {import("@lerna/child-process").ExecOpts} opts
*/
function hasCommit(opts) {
log.silly("hasCommit");
let retVal;
try {
childProcess.execSync("git", ["log"], opts);
retVal = true;
} catch (e) {
retVal = false;
}
log.verbose("hasCommit", retVal);
return retVal;
}
Выполнить команду
Для локальной разработки. Не используйте в интернете!