/
githubmirror
/
immutable-js
Обзор
Документация
Войти
/
githubmirror
/
immutable-js
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
resources/prepare-dist.sh
25 строк
806 B
Lee Byron
Make it more clear in package.json which keys will be included in published packages (#1846)
08 июл 2021, 21:35
Не верифицирован
08 июл 2021, 21:35
e310574
Код
Авторство
О чём код?
#!/bin/sh -e # This script prepares an npm directory with files safe to publish to npm or the # npm git branch: # # "immutable": "git://github.com/immutable-js/immutable-js.git#npm" # # Create empty npm directory rm -rf npm mkdir -p npm # Copy over necessary files cp -r dist npm/ cp README.md npm/ cp LICENSE npm/ # Ensure a vanilla package.json before deploying so other tools do not interpret # The built output as requiring any further transformation. node -e "var package = require('./package.json'); \ package = Object.fromEntries(Object.entries(package).filter(([key]) => package.publishKeys.includes(key))); \ require('fs').writeFileSync('./npm/package.json', JSON.stringify(package, null, 2));" # Retain marginal support for bower on the npm branch cp npm/package.json npm/bower.json