PHP 8.2.31
Preview: file_task.rb Size: 1.26 KB
/proc/thread-self/root/opt/alt/ruby22/lib64/ruby/2.2.0/rake/file_task.rb

require 'rake/task.rb'
require 'rake/early_time'

module Rake

  # A FileTask is a task that includes time based dependencies.  If any of a
  # FileTask's prerequisites have a timestamp that is later than the file
  # represented by this task, then the file must be rebuilt (using the
  # supplied actions).
  #
  class FileTask < Task

    # Is this file task needed?  Yes if it doesn't exist, or if its time stamp
    # is out of date.
    def needed?
      ! File.exist?(name) || out_of_date?(timestamp) || @application.options.build_all
    end

    # Time stamp for file task.
    def timestamp
      if File.exist?(name)
        File.mtime(name.to_s)
      else
        Rake::LATE
      end
    end

    private

    # Are there any prerequisites with a later time than the given time stamp?
    def out_of_date?(stamp)
      @prerequisites.any? { |n| application[n, @scope].timestamp > stamp }
    end

    # ----------------------------------------------------------------
    # Task class methods.
    #
    class << self
      # Apply the scope to the task name according to the rules for this kind
      # of task.  File based tasks ignore the scope when creating the name.
      def scope_name(scope, task_name)
        Rake.from_pathname(task_name)
      end
    end
  end
end

Directory Contents

Dirs: 4 × Files: 45

Name Size Perms Modified Actions
contrib DIR
- drwxr-xr-x 2024-03-03 22:53:17
Edit Download
ext DIR
- drwxr-xr-x 2024-03-03 22:53:17
Edit Download
lib DIR
- drwxr-xr-x 2023-07-26 14:31:55
Edit Download
loaders DIR
- drwxr-xr-x 2024-03-03 22:53:17
Edit Download
3.17 KB lrw-r--r-- 2014-07-15 03:07:37
Edit Download
23.14 KB lrw-r--r-- 2014-12-06 00:22:51
Edit Download
868 B lrw-r--r-- 2014-08-16 03:56:17
Edit Download
1.93 KB lrw-r--r-- 2014-07-15 03:07:37
Edit Download
418 B lrw-r--r-- 2014-09-06 09:31:37
Edit Download
2.83 KB lrw-r--r-- 2014-11-05 05:19:15
Edit Download
235 B lrw-r--r-- 2014-07-15 03:07:37
Edit Download
5.64 KB lrw-r--r-- 2014-12-06 00:22:51
Edit Download
340 B lrw-r--r-- 2014-07-15 03:07:37
Edit Download
670 B lrw-r--r-- 2011-06-23 22:11:55
Edit Download
12.13 KB lrw-r--r-- 2014-09-06 09:31:37
Edit Download
1.26 KB lrw-r--r-- 2014-11-25 07:03:36
Edit Download
3.66 KB lrw-r--r-- 2014-07-15 03:07:37
Edit Download
4.05 KB lrw-r--r-- 2013-10-11 21:35:01
Edit Download
144 B lrw-r--r-- 2014-07-15 03:07:37
Edit Download
1.16 KB lrw-r--r-- 2014-08-27 12:21:41
Edit Download
431 B lrw-r--r-- 2011-06-23 22:11:55
Edit Download
265 B lrw-r--r-- 2014-11-25 07:03:58
Edit Download
2.27 KB lrw-r--r-- 2014-07-15 03:07:37
Edit Download
315 B lrw-r--r-- 2012-11-15 21:59:37
Edit Download
673 B lrw-r--r-- 2014-07-15 03:07:37
Edit Download
5.28 KB lrw-r--r-- 2014-11-25 07:03:36
Edit Download
53 B lrw-r--r-- 2014-07-15 03:07:37
Edit Download
351 B lrw-r--r-- 2012-11-15 22:32:34
Edit Download
364 B lrw-r--r-- 2012-11-15 22:01:58
Edit Download
2.28 KB lrw-r--r-- 2013-10-11 21:35:01
Edit Download
375 B lrw-r--r-- 2014-07-15 03:07:37
Edit Download
770 B lrw-r--r-- 2014-07-15 03:07:37
Edit Download
341 B lrw-r--r-- 2011-06-28 02:45:29
Edit Download
153 B lrw-r--r-- 2014-07-15 03:07:37
Edit Download
897 B lrw-r--r-- 2014-07-15 03:07:37
Edit Download
353 B lrw-r--r-- 2011-06-23 22:11:55
Edit Download
594 B lrw-r--r-- 2014-07-15 03:07:37
Edit Download
882 B lrw-r--r-- 2014-07-15 03:07:37
Edit Download
11.02 KB lrw-r--r-- 2014-07-15 03:07:37
Edit Download
618 B lrw-r--r-- 2014-07-15 03:07:37
Edit Download
2.15 KB lrw-r--r-- 2014-07-15 03:07:37
Edit Download
119 B lrw-r--r-- 2011-06-23 22:11:55
Edit Download
8.84 KB lrw-r--r-- 2014-11-25 07:03:36
Edit Download
5.55 KB lrw-r--r-- 2014-07-15 03:07:37
Edit Download
1.11 KB lrw-r--r-- 2013-10-11 21:35:01
Edit Download
4.78 KB lrw-r--r-- 2014-07-15 03:07:37
Edit Download
543 B lrw-r--r-- 2014-07-15 03:07:37
Edit Download
156 B lrw-r--r-- 2014-07-15 03:07:37
Edit Download
1.55 KB lrw-r--r-- 2014-07-15 03:07:37
Edit Download

If ZipArchive is unavailable, a .tar will be created (no compression).