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.8.0 lib/specinfra/command/base/cron.rb
specinfra-2.7.0 lib/specinfra/command/base/cron.rb
specinfra-2.6.0 lib/specinfra/command/base/cron.rb
specinfra-2.5.0 lib/specinfra/command/base/cron.rb
specinfra-2.4.5 lib/specinfra/command/base/cron.rb
specinfra-2.4.4 lib/specinfra/command/base/cron.rb
specinfra-2.4.3 lib/specinfra/command/base/cron.rb
specinfra-2.4.2 lib/specinfra/command/base/cron.rb
specinfra-2.4.1 lib/specinfra/command/base/cron.rb
specinfra-2.4.0 lib/specinfra/command/base/cron.rb
specinfra-2.3.2 lib/specinfra/command/base/cron.rb
specinfra-2.3.1 lib/specinfra/command/base/cron.rb
specinfra-2.3.0 lib/specinfra/command/base/cron.rb
specinfra-2.2.4 lib/specinfra/command/base/cron.rb
specinfra-2.2.3 lib/specinfra/command/base/cron.rb
specinfra-2.2.2 lib/specinfra/command/base/cron.rb
specinfra-2.2.1 lib/specinfra/command/base/cron.rb
specinfra-2.2.0 lib/specinfra/command/base/cron.rb
specinfra-2.1.1 lib/specinfra/command/base/cron.rb
specinfra-2.1.0 lib/specinfra/command/base/cron.rb