Sha256: 225820ab7c8883d0c94a083222904231247d3724be23e8f650cc1ee5e47cada2
Contents?: true
Size: 500 Bytes
Versions: 25
Compression:
Stored size: 500 Bytes
Contents
#!/usr/bin/env node const {resolve} = require('path'); const {existsSync, writeFileSync, readFileSync} = require('fs'); const npmrc = resolve('.', '.npmrc'); const npmrcContents = process.argv[2]; if (!npmrcContents) { console.error('npmrc contents not specified.'); process.exit(1); } if (existsSync(npmrc)) { console.log('.npmrc already exists.') } else { writeFileSync(npmrc, npmrcContents) console.log('\nGenerated .npmrc:'); console.log(readFileSync(npmrc, {encoding: 'utf8'})) }
Version data entries
25 entries across 25 versions & 1 rubygems