scripts/install/index.js
// Check some condition before installing hooks.
Check some condition before installing hooks.
Check some condition before installing hooks .
function checkBeforeInstall() {
    pleaseUpgradeNode(pkg, {
        exitCode: 0,
        message: function (requiredVersion) {
            return `ihook > ihook requires Node ${requiredVersion} , stop Git hooks installation.`;
        }
    });
    if (isInNestedNodeModules(__dirname)) {
        log('Trying to install in nested node_modules directory, stop Git hooks installation.', 0);
    }
}
function checkBeforeInstall ( ) { pleaseUpgradeNode ( pkg , { exitCode : 0 , message : function ( requiredVersion ) { return ` ${ requiredVersion } ` ; } } ) ; if ( isInNestedNodeModules ( __dirname ) ) { log ( 'Trying to install in nested node_modules directory, stop Git hooks installation.' , 0 ) ; } }
Check some condition before installing hooks.
Check some condition before installing hooks .
// Node version isn't supported, skip install // Prevent installing hooks if ihook is in nested node_modules