lib/hexapdf/cli/modify.rb in hexapdf-0.6.0 vs lib/hexapdf/cli/modify.rb in hexapdf-0.7.0

- old
+ new

@@ -1,12 +1,12 @@ -# -*- encoding: utf-8 -*- +# -*- encoding: utf-8; frozen_string_literal: true -*- # #-- # This file is part of HexaPDF. # # HexaPDF - A Versatile PDF Creation and Manipulation Library For Ruby -# Copyright (C) 2014-2017 Thomas Leitner +# Copyright (C) 2014-2018 Thomas Leitner # # HexaPDF is free software: you can redistribute it and/or modify it # under the terms of the GNU Affero General Public License version 3 as # published by the Free Software Foundation with the addition of the # following permission added to Section 15 as permitted in Section 7(a): @@ -47,11 +47,11 @@ class Modify < Command def initialize #:nodoc: super('modify', takes_commands: false) short_desc("Modify a PDF file") - long_desc(<<-EOF.gsub!(/^ */, '')) + long_desc(<<~EOF) This command modifies a PDF file. It can be used to select pages that should appear in the output file and/or rotate them. The output file can also be encrypted/decrypted and optimized in various ways. EOF @@ -77,10 +77,10 @@ def execute(in_file, out_file) #:nodoc: maybe_raise_on_existing_file(out_file) with_document(in_file, password: @password, out_file: out_file) do |doc| arrange_pages(doc) unless @pages == '1-e' - @embed_files.each {|file| doc.files.add(file, embed: true)} + @embed_files.each {|file| doc.files.add(file, embed: true) } apply_encryption_options(doc) apply_optimization_options(doc) end end