diff options
author | Hiroshi SHIBATA <hsbt@ruby-lang.org> | 2023-04-11 14:56:08 +0900 |
---|---|---|
committer | Hiroshi SHIBATA <hsbt@ruby-lang.org> | 2023-04-11 19:12:28 +0900 |
commit | d89cc317c642848008f5b17a82196d25ddcdf124 (patch) | |
tree | b1a0dea2ae57246ff407a7608618ff12bb77204f /lib/rubygems/config_file.rb | |
parent | 65e276096f2b5ace95d07ac15af545362e0714c1 (diff) |
util/rubocop -A --only Style/NumericLiteralPrefix
Diffstat (limited to 'lib/rubygems/config_file.rb')
-rw-r--r-- | lib/rubygems/config_file.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/rubygems/config_file.rb b/lib/rubygems/config_file.rb index 0a5f6ffad2..9d38d8b134 100644 --- a/lib/rubygems/config_file.rb +++ b/lib/rubygems/config_file.rb @@ -241,9 +241,9 @@ class Gem::ConfigFile return if Gem.win_platform? # windows doesn't write 0600 as 0600 return unless File.exist? credentials_path - existing_permissions = File.stat(credentials_path).mode & 0777 + existing_permissions = File.stat(credentials_path).mode & 0o777 - return if existing_permissions == 0600 + return if existing_permissions == 0o600 alert_error <<-ERROR Your gem push credentials file located at: @@ -326,7 +326,7 @@ if you believe they were disclosed to a third party. Gem.load_yaml - permissions = 0600 & (~File.umask) + permissions = 0o600 & (~File.umask) File.open(credentials_path, "w", permissions) do |f| f.write config.to_yaml end |