Skip to content

Commit

Permalink
ypdを設定ファイルで保存できるようにした
Browse files Browse the repository at this point in the history
  • Loading branch information
加藤 真透 committed Oct 6, 2016
1 parent ee983dc commit 76cc284
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions exe/aws_billing2
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,9 @@ Class.new(Thor) do
type: :string,
default: ENV['REGION']
option :ypd,
desc: 'yen per $ (125)',
desc: 'yen per $',
type: :numeric,
default: 125
default: ENV['YPD'] || 125
option :yearmonth,
desc: 'target year-month(2016-03)',
type: :string,
Expand Down Expand Up @@ -68,7 +68,7 @@ Class.new(Thor) do
puts ab.gets_table
if options['save_param']
File.open(File.expand_path(PARAM_FILE), 'w') do |f|
%w(BUCKET_NAME INVOICE_ID ACCESS_KEY_ID SECRET_ACCESS_KEY REGION).each do |e|
%w(BUCKET_NAME INVOICE_ID ACCESS_KEY_ID SECRET_ACCESS_KEY REGION YPD).each do |e|
f.puts("#{e}=#{ENV[e]}")
end
end
Expand Down

0 comments on commit 76cc284

Please sign in to comment.