Sha256: ed6ee45a868426f146727cbb9497ad18f13aa08af626a6ee13184e31453d725d

Contents?: true

Size: 423 Bytes

Versions: 82

Compression:

Stored size: 423 Bytes

Contents

class Specinfra::Command::Base::Cron < Specinfra::Command::Base
  class << self
    def check_has_entry(user, entry)
      entry_escaped = entry.gsub(/\*/, '\\*').gsub(/\[/, '\\[').gsub(/\]/, '\\]')
      if user.nil?
        "crontab -l | grep -v \"#\" -- | grep -- #{escape(entry_escaped)}"
      else
        "crontab -u #{escape(user)} -l | grep -v \"#\" | grep -- #{escape(entry_escaped)}"
      end
    end
  end
end

Version data entries

82 entries across 82 versions & 1 rubygems

Version Path
specinfra-2.0.0.beta37 lib/specinfra/command/base/cron.rb
specinfra-2.0.0.beta36 lib/specinfra/command/base/cron.rb
specinfra-2.0.0.beta35 lib/specinfra/command/base/cron.rb
specinfra-2.0.0.beta34 lib/specinfra/command/base/cron.rb
specinfra-2.0.0.beta33 lib/specinfra/command/base/cron.rb
specinfra-2.0.0.beta32 lib/specinfra/command/base/cron.rb
specinfra-2.0.0.beta31 lib/specinfra/command/base/cron.rb
specinfra-2.0.0.beta30 lib/specinfra/command/base/cron.rb
specinfra-2.0.0.beta29 lib/specinfra/command/base/cron.rb
specinfra-2.0.0.beta28 lib/specinfra/command/base/cron.rb
specinfra-2.0.0.beta27 lib/specinfra/command/base/cron.rb
specinfra-2.0.0.beta26 lib/specinfra/command/base/cron.rb
specinfra-2.0.0.beta25 lib/specinfra/command/base/cron.rb
specinfra-2.0.0.beta24 lib/specinfra/command/base/cron.rb
specinfra-2.0.0.beta23 lib/specinfra/command/base/cron.rb
specinfra-2.0.0.beta22 lib/specinfra/command/base/cron.rb
specinfra-2.0.0.beta21 lib/specinfra/command/base/cron.rb
specinfra-2.0.0.beta20 lib/specinfra/command/base/cron.rb
specinfra-2.0.0.beta19 lib/specinfra/command/base/cron.rb
specinfra-2.0.0.beta18 lib/specinfra/command/base/cron.rb