vendor/bundle/ruby/2.6.0/gems/lumberjack-1.2.8/lib/lumberjack/device/date_rolling_log_file.rb
def roll_file?
        if @manual
          true
        else
          date = Date.today
          if date.year > @file_date.year
            true
          elsif @roll_period == :daily && date.yday > @file_date.yday
            true
          elsif @roll_period == :weekly && date.cweek != @file_date.cweek
            true
          elsif @roll_period == :monthly && date.month > @file_date.month
            true
          else
            false
          end
        end
      end
# Create a new logging device to the specified file. The period to roll the file is specified
# with the :roll option which may contain a value of :daily, :weekly,
# or :monthly.
Create a new logging device to the specified file. The period to roll the file is specified
with the :roll option which may contain a value of :daily, :weekly,
or :monthly.
Create a new logging device to the specified file . The period to roll the file is specified with the : roll option which may contain a value of : daily : weekly or : monthly .
def roll_file?
        if @manual
          true
        else
          date = Date.today
          if date.year > @file_date.year
            true
          elsif @roll_period == :daily && date.yday > @file_date.yday
            true
          elsif @roll_period == :weekly && date.cweek != @file_date.cweek
            true
          elsif @roll_period == :monthly && date.month > @file_date.month
            true
          else
            false
          end
        end
      end
def roll_file? if @manual true else date = Date . today if date . year > @file_date . year true elsif @roll_period == :daily && date . yday > @file_date . yday true elsif @roll_period == :weekly && date . cweek != @file_date . cweek true elsif @roll_period == :monthly && date . month > @file_date . month true else false end end end
Create a new logging device to the specified file.
Create a new logging device to the specified file .