# class Chef::Resource::Execute

### Public Class Methods

new(name, run_context=nil) click to toggle source
Calls superclass method Chef::Resource.new

    # File lib/chef/resource/execute.rb, line 28
    def initialize(name, run_context=nil)
      super
      @resource_name = :execute
      @command = name
      @backup = 5
      @action = "run"
      @creates = nil
      @cwd = nil
      @environment = nil
      @group = nil
      @path = nil
      @returns = 0
      @timeout = nil
      @user = nil
      @allowed_actions.push(:run)
      @umask = nil
    end

### Public Instance Methods

command(arg=nil) click to toggle source

    # File lib/chef/resource/execute.rb, line 54
    def command(arg=nil)
      set_or_return(
        :command,
        arg,
        :kind_of => [ String, Array ]
      )
    end

creates(arg=nil) click to toggle source

    # File lib/chef/resource/execute.rb, line 62
    def creates(arg=nil)
      set_or_return(
        :creates,
        arg,
        :kind_of => [ String ]
      )
    end

cwd(arg=nil) click to toggle source

    # File lib/chef/resource/execute.rb, line 70
    def cwd(arg=nil)
      set_or_return(
        :cwd,
        arg,
        :kind_of => [ String ]
      )
    end

env(arg=nil)
Alias for: environment
environment(arg=nil) click to toggle source

    # File lib/chef/resource/execute.rb, line 78
    def environment(arg=nil)
      set_or_return(
        :environment,
        arg,
        :kind_of => [ Hash ]
      )
    end

Also aliased as: env
group(arg=nil) click to toggle source

    # File lib/chef/resource/execute.rb, line 88
    def group(arg=nil)
      set_or_return(
        :group,
        arg,
        :kind_of => [ String, Integer ]
      )
    end

path(arg=nil) click to toggle source

    # File lib/chef/resource/execute.rb, line 96
    def path(arg=nil)
      set_or_return(
        :path,
        arg,
        :kind_of => [ Array ]
      )
    end

returns(arg=nil) click to toggle source

    # File lib/chef/resource/execute.rb, line 104
    def returns(arg=nil)
      set_or_return(
        :returns,
        arg,
        :kind_of => [ Integer, Array ]
      )
    end

timeout(arg=nil) click to toggle source

    # File lib/chef/resource/execute.rb, line 112
    def timeout(arg=nil)
      set_or_return(
        :timeout,
        arg,
        :kind_of => [ Integer ]
      )
    end

umask(arg=nil) click to toggle source

    # File lib/chef/resource/execute.rb, line 46
    def umask(arg=nil)
      set_or_return(
        :umask,
        arg,
        :kind_of => [ String, Integer ]
      )
    end

user(arg=nil) click to toggle source

    # File lib/chef/resource/execute.rb, line 120
    def user(arg=nil)
      set_or_return(
        :user,
        arg,
        :kind_of => [ String, Integer ]
      )
    end