Sha256: 53e73fca828146fc5e4b554f4239cad89060861af6b697fdf61b65e200db41e9
Contents?: true
Size: 581 Bytes
Versions: 20
Compression:
Stored size: 581 Bytes
Contents
module DPL class Provider class NPM < Provider NPMRC_FILE = '~/.npmrc' def needs_key? false end def check_app end def setup_auth File.open(File.expand_path(NPMRC_FILE), 'w') do |f| f.puts("_auth = ${NPM_API_KEY}") f.puts("email = #{option(:email)}") end end def check_auth setup_auth log "Authenticated with email #{option(:email)}" end def push_app context.shell "env NPM_API_KEY=#{option(:api_key)} npm publish" end end end end
Version data entries
20 entries across 20 versions & 1 rubygems