mirror of
https://code.forgejo.org/actions/setup-node.git
synced 2025-05-21 13:34:46 +00:00
.
This commit is contained in:
parent
a004f0ae58
commit
fc725ba36b
7280 changed files with 19 additions and 1796407 deletions
26
node_modules/read-pkg-up/index.js
generated
vendored
26
node_modules/read-pkg-up/index.js
generated
vendored
|
@ -1,26 +0,0 @@
|
|||
'use strict';
|
||||
const findUp = require('find-up');
|
||||
const readPkg = require('read-pkg');
|
||||
|
||||
module.exports = options => {
|
||||
return findUp('package.json', options).then(fp => {
|
||||
if (!fp) {
|
||||
return {};
|
||||
}
|
||||
|
||||
return readPkg(fp, options).then(pkg => ({pkg, path: fp}));
|
||||
});
|
||||
};
|
||||
|
||||
module.exports.sync = options => {
|
||||
const fp = findUp.sync('package.json', options);
|
||||
|
||||
if (!fp) {
|
||||
return {};
|
||||
}
|
||||
|
||||
return {
|
||||
pkg: readPkg.sync(fp, options),
|
||||
path: fp
|
||||
};
|
||||
};
|
Loading…
Add table
Add a link
Reference in a new issue