UNPKG

@nrwl/schematics

Version:

Extensible Dev Tools for Monorepos: Schematics

14 lines (13 loc) 491 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); const workspace_1 = require("@nrwl/workspace"); exports.default = { description: 'Add postinstall script to run nx-migrate:check', run: () => { workspace_1.updateJsonFile('package.json', json => { if (!json.scripts.postinstall) { json.scripts = Object.assign({}, json.scripts, { postinstall: './node_modules/.bin/nx migrate check' }); } }); } };