Browse Source

gem: adopt frozen string literals

tags/v2.2.0
cn 6 months ago
parent
commit
b597ecb15e
19 changed files with 27 additions and 8 deletions
  1. +0
    -3
      .rubocop.yml
  2. +1
    -0
      CHANGELOG.md
  3. +2
    -0
      Gemfile
  4. +2
    -0
      Rakefile
  5. +1
    -0
      dyndnsd.gemspec
  6. +2
    -0
      exe/dyndnsd
  7. +1
    -1
      lib/dyndnsd.rb
  8. +1
    -0
      lib/dyndnsd/database.rb
  9. +1
    -0
      lib/dyndnsd/generator/bind.rb
  10. +1
    -0
      lib/dyndnsd/helper.rb
  11. +1
    -0
      lib/dyndnsd/responder/dyndns_style.rb
  12. +1
    -0
      lib/dyndnsd/responder/rest_style.rb
  13. +1
    -0
      lib/dyndnsd/textfile_reporter.rb
  14. +1
    -0
      lib/dyndnsd/updater/command_with_bind_zone.rb
  15. +2
    -1
      lib/dyndnsd/version.rb
  16. +3
    -1
      spec/daemon_spec.rb
  17. +4
    -2
      spec/spec_helper.rb
  18. +1
    -0
      spec/support/dummy_database.rb
  19. +1
    -0
      spec/support/dummy_updater.rb

+ 0
- 3
.rubocop.yml View File

@@ -53,9 +53,6 @@ Style/Documentation:
Style/FormatStringToken:
Enabled: false

Style/FrozenStringLiteralComment:
Enabled: false

Style/GuardClause:
Enabled: false



+ 1
- 0
CHANGELOG.md View File

@@ -5,6 +5,7 @@
IMPROVEMENTS:

- Refactor gemspec based on [recommendations](https://piotrmurach.com/articles/writing-a-ruby-gem-specification/) so tests are now excluded from gem and binaries move to `./exe` directory
- Adopt Ruby 2.3 frozen string literals for source code potentially reducing memory consumption

## 2.1.1 (March 1, 2020)



+ 2
- 0
Gemfile View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

source 'https://rubygems.org'

gemspec

+ 2
- 0
Rakefile View File

@@ -1,3 +1,5 @@
# frozen_string_literal: true

require 'bundler/gem_tasks'
require 'rspec/core/rake_task'
require 'rubocop/rake_task'


+ 1
- 0
dyndnsd.gemspec View File

@@ -1,3 +1,4 @@
# frozen_string_literal: true

require_relative 'lib/dyndnsd/version'



+ 2
- 0
exe/dyndnsd View File

@@ -1,3 +1,5 @@
#!/usr/bin/env ruby
# frozen_string_literal: true

require 'dyndnsd'



+ 1
- 1
lib/dyndnsd.rb View File

@@ -1,4 +1,4 @@
#!/usr/bin/env ruby
# frozen_string_literal: true

require 'etc'
require 'logger'


+ 1
- 0
lib/dyndnsd/database.rb View File

@@ -1,3 +1,4 @@
# frozen_string_literal: true

require 'forwardable'



+ 1
- 0
lib/dyndnsd/generator/bind.rb View File

@@ -1,3 +1,4 @@
# frozen_string_literal: true

module Dyndnsd
module Generator


+ 1
- 0
lib/dyndnsd/helper.rb View File

@@ -1,3 +1,4 @@
# frozen_string_literal: true

require 'ipaddr'



+ 1
- 0
lib/dyndnsd/responder/dyndns_style.rb View File

@@ -1,3 +1,4 @@
# frozen_string_literal: true

module Dyndnsd
module Responder


+ 1
- 0
lib/dyndnsd/responder/rest_style.rb View File

@@ -1,3 +1,4 @@
# frozen_string_literal: true

module Dyndnsd
module Responder


+ 1
- 0
lib/dyndnsd/textfile_reporter.rb View File

@@ -1,3 +1,4 @@
# frozen_string_literal: true

# Adapted from https://github.com/eric/metriks-graphite/blob/master/lib/metriks/reporter/graphite.rb



+ 1
- 0
lib/dyndnsd/updater/command_with_bind_zone.rb View File

@@ -1,3 +1,4 @@
# frozen_string_literal: true

module Dyndnsd
module Updater


+ 2
- 1
lib/dyndnsd/version.rb View File

@@ -1,4 +1,5 @@
# frozen_string_literal: true

module Dyndnsd
VERSION = '2.1.1'.freeze
VERSION = '2.1.1'
end

+ 3
- 1
spec/daemon_spec.rb View File

@@ -1,4 +1,6 @@
require 'spec_helper'
# frozen_string_literal: true

require_relative 'spec_helper'

describe Dyndnsd::Daemon do
include Rack::Test::Methods


+ 4
- 2
spec/spec_helper.rb View File

@@ -1,8 +1,10 @@
# frozen_string_literal: true

require 'rubygems'
require 'bundler/setup'
require 'rack/test'

require 'dyndnsd'
require 'support/dummy_database'
require 'support/dummy_updater'

require_relative 'support/dummy_database'
require_relative 'support/dummy_updater'

+ 1
- 0
spec/support/dummy_database.rb View File

@@ -1,3 +1,4 @@
# frozen_string_literal: true

require 'forwardable'



+ 1
- 0
spec/support/dummy_updater.rb View File

@@ -1,3 +1,4 @@
# frozen_string_literal: true

module Dyndnsd
module Updater


Loading…
Cancel
Save