Skip to content

Commit

Permalink
rubocop 1.21.0
Browse files Browse the repository at this point in the history
  • Loading branch information
toy committed Sep 14, 2021
1 parent 859dc72 commit f2435db
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion lib/image_optim/runner.rb
Expand Up @@ -38,7 +38,7 @@ def size_percent(size_a, size_b)
if size_a == size_b
"------ #{Space::EMPTY_SPACE}"
else
percent = 100 - 100.0 * size_b / size_a
percent = 100 - (100.0 * size_b / size_a)
space = Space.space(size_a - size_b)
format('%5.2f%% %s', percent, space)
end
Expand Down
2 changes: 1 addition & 1 deletion lib/image_optim/runner/option_parser.rb
Expand Up @@ -38,7 +38,7 @@ def help
columns = terminal_columns - 1
# 1 for distance between summary and description
# 2 for additional indent
wrapped_indent = summary_indent + ' ' * (summary_width + 1 + 2)
wrapped_indent = summary_indent + (' ' * (summary_width + 1 + 2))
wrapped_width = columns - wrapped_indent.length
# don't try to wrap if there is too little space for description
return text if wrapped_width < 20
Expand Down
2 changes: 1 addition & 1 deletion spec/images/invisiblepixels/generate
Expand Up @@ -17,7 +17,7 @@ IO.popen(%W[
].shelljoin, 'w') do |f|
side.times do |a|
side.times do |b|
alpha = [0, 1, 0x7f, 0xff][(a / 8 + b / 8) % 4]
alpha = [0, 1, 0x7f, 0xff][((a / 8) + (b / 8)) % 4]
f << [rand(256), rand(256), rand(256), alpha].pack('C*')
end
end
Expand Down

0 comments on commit f2435db

Please sign in to comment.