Class: Nbuild::NCacheCmd
Instance Method Summary collapse
- #command ⇒ Object
-
#initialize(params = {}) ⇒ NCacheCmd
constructor
A new instance of NCacheCmd.
Methods inherited from Cmd
Constructor Details
#initialize(params = {}) ⇒ NCacheCmd
Returns a new instance of NCacheCmd.
5 6 7 8 |
# File 'lib/nbuild/ncache_cmd.rb', line 5 def initialize params={} @path = ENV['NCACHE_HOME'] || 'C:\Program Files\NCache\bin\tools' @params = params end |
Instance Method Details
#command ⇒ Object
10 11 12 13 14 |
# File 'lib/nbuild/ncache_cmd.rb', line 10 def command cmd = @params[:stop] ? 'stopcache' : 'startcache' cache = @params[:cache] "\"#{@path}\\#{cmd}\" #{cache}" end |