UNPKG

build-a-npm

Version:

A tool to create and publish Node packages with automatic version bumping and GitHub integration.

41 lines (39 loc) 807 B
function generateNpmIgnore(useTypeScript) { const baseIgnores = [ 'node_modules/', '.gitignore', '.npmrc', 'build-a-npm.log', '.build-a-npm-state.json', 'test/', '*.md', '.github/', '.gitlab-ci.yml', '.circleci/', '.vscode/', '.idea/', '.DS_Store', 'coverage/', '.prettierrc', '.eslintrc.json', '.eslintignore', 'tsconfig.json', 'package-lock.json', 'yarn.lock', 'pnpm-lock.yaml', '*.tgz', '.env', '.env.local', '.env.development.local', '.env.test.local', '.env.production.local', 'WEBPAGE.md', 'index.html', 'generateIndex.js', ]; if (useTypeScript) { baseIgnores.push('src/', '!dist/'); } return baseIgnores.join('\n') + '\n'; } module.exports = { generateNpmIgnore };