Sha256: 8b6c44ea67173e4dd9418b8acedd5ca0febc84bdbeaed8744085be573d8abca7

Contents?: true

Size: 500 Bytes

Versions: 19

Compression:

Stored size: 500 Bytes

Contents

# frozen_string_literal: true

require "rubocop"
require "rfix/log"

module Rfix
  include Log
  attr_accessor :repo
  attr_accessor :test

  alias test? test

  def global_enable!
    @global_enable = true
  end

  def global_enable?
    @global_enable
  end

  def refresh!(source)
    return true if global_enable?

    repo.refresh!(source.file_path)
  end

  def enabled?(path, line)
    return true if global_enable?

    repo.include?(path, line)
  end
end

# rubocop:enable Layout/LineLength

Version data entries

19 entries across 19 versions & 1 rubygems

Version Path
rfix-1.4.1 lib/rfix/rfix.rb
rfix-1.4.0.pre.201 lib/rfix/rfix.rb
rfix-1.4.0 lib/rfix/rfix.rb
rfix-1.3.0.pre.199 lib/rfix/rfix.rb
rfix-1.2.6.pre.198 lib/rfix/rfix.rb
rfix-1.2.6 lib/rfix/rfix.rb
rfix-1.2.2.pre.174 lib/rfix/rfix.rb
rfix-1.2.5 lib/rfix/rfix.rb
rfix-1.2.4 lib/rfix/rfix.rb
rfix-1.2.3.pre lib/rfix/rfix.rb
rfix-1.2.2.pre lib/rfix/rfix.rb
rfix-1.2.2.pre.172 lib/rfix/rfix.rb
rfix-1.2.2 lib/rfix/rfix.rb
rfix-1.1.0.pre.150 lib/rfix/rfix.rb
rfix-1.2.0 lib/rfix/rfix.rb
rfix-1.1.4.pre lib/rfix/rfix.rb
rfix-1.1.1.pre lib/rfix/rfix.rb
rfix-1.1.0.pre.149 lib/rfix/rfix.rb
rfix-1.1.0.pre.147 lib/rfix/rfix.rb