Class: AlpacaBuildTool::Nuget
- Inherits:
-
Tool
- Object
- Tool
- AlpacaBuildTool::Nuget
show all
- Defined in:
- lib/alpacabuildtool/tools/nuget.rb
Overview
Instance Attribute Summary
Attributes included from Log
#log
Instance Method Summary
collapse
Methods inherited from Tool
#call, #initialize
Instance Method Details
#install(package, outputdir = nil, prerelease = false, exclude_version = false, source = nil) ⇒ Object
11
12
13
14
15
16
17
18
19
20
21
22
|
# File 'lib/alpacabuildtool/tools/nuget.rb', line 11
def install(package,
outputdir = nil,
prerelease = false,
exclude_version = false,
source = nil)
= {}
['OutputDirectory'] = outputdir if outputdir
['Prerelease'] = prerelease if prerelease
['ExcludeVersion'] = exclude_version if exclude_version
['Source'] = source if source
run_command 'install', package,
end
|
#pack(nuspec_or_project, configuration = nil) ⇒ Object
24
25
26
27
28
|
# File 'lib/alpacabuildtool/tools/nuget.rb', line 24
def pack(nuspec_or_project, configuration = nil)
= {}
['Prop'] = "Configuration=#{configuration}" if configuration
run_command 'pack', nuspec_or_project,
end
|
#push(package, source) ⇒ Object
30
31
32
|
# File 'lib/alpacabuildtool/tools/nuget.rb', line 30
def push(package, source)
run_command 'install', package, 'Source' => source
end
|
#restore(solution_file) ⇒ Object
7
8
9
|
# File 'lib/alpacabuildtool/tools/nuget.rb', line 7
def restore(solution_file)
run_command 'restore', solution_file
end
|