From f4b8094ca63ef89a2a3ac7c89b41dbaf680f0a34 Mon Sep 17 00:00:00 2001 From: Tim Meusel Date: Tue, 17 Sep 2024 20:19:48 +0200 Subject: [PATCH] rubocop: autofix --- .github/workflows/ci.yml | 5 ++--- lib/puppet/modulebuilder/builder.rb | 8 ++++---- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 22ccaea..5823aff 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -21,9 +21,8 @@ jobs: - "3.3" - "3.2" - "3.1" - include: - - ruby_version: '3.2' - puppet_gem_version: '~> 8.0' # puppet8' + puppet_gem_version: + - '~> 8.0' runs_on: - "ubuntu-latest" - "windows-latest" diff --git a/lib/puppet/modulebuilder/builder.rb b/lib/puppet/modulebuilder/builder.rb index f0dd472..67344d2 100644 --- a/lib/puppet/modulebuilder/builder.rb +++ b/lib/puppet/modulebuilder/builder.rb @@ -199,7 +199,7 @@ def validate_path_encoding!(path) return unless /[^\x00-\x7F]/.match?(path) raise ArgumentError, format("'%s' can only include ASCII characters in its path or " \ - 'filename in order to be compatible with a wide range of hosts.', path: path) + 'filename in order to be compatible with a wide range of hosts.', path:) end # Creates a gzip compressed tarball of the build directory. @@ -232,7 +232,7 @@ def build_package entry_meta[:mode] = orig_mode | min_mode if entry_meta[:mode] != orig_mode - logger.debug(format('Updated permissions of packaged \'%s\' to %s', entry: entry, + logger.debug(format('Updated permissions of packaged \'%s\' to %s', entry:, new_mode: (entry_meta[:mode] & 0o7777).to_s(8))) end @@ -352,7 +352,7 @@ def release_name # # @return [nil] def validate_ustar_path!(path) - raise ArgumentError, format("The path '%s' is longer than 256 bytes.", path: path) if path.bytesize > 256 + raise ArgumentError, format("The path '%s' is longer than 256 bytes.", path:) if path.bytesize > 256 if path.bytesize <= 100 prefix = '' @@ -377,7 +377,7 @@ def validate_ustar_path!(path) raise ArgumentError, \ format("'%s' could not be split at a directory separator into two " \ 'parts, the first having a maximum length of 155 bytes and the ' \ - 'second having a maximum length of 100 bytes.', path: path) + 'second having a maximum length of 100 bytes.', path:) end private