Last change
on this file since 6a3a178 was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago |
initial commit
|
-
Property mode
set to
100644
|
File size:
346 bytes
|
Line | |
---|
1 | const util = require('util')
|
---|
2 | const fs = require('fs')
|
---|
3 | const {stat} = fs.promises || { stat: util.promisify(fs.stat) };
|
---|
4 |
|
---|
5 | async function isNodeGypPackage(path) {
|
---|
6 | return await stat(`${path}/binding.gyp`)
|
---|
7 | .then(st => st.isFile())
|
---|
8 | .catch(() => false)
|
---|
9 | }
|
---|
10 |
|
---|
11 | module.exports = {
|
---|
12 | isNodeGypPackage,
|
---|
13 | defaultGypInstallScript: 'node-gyp rebuild'
|
---|
14 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.