Class: LicenseFinder::Govendor
Class Method Summary
collapse
Instance Method Summary
collapse
#active?, #command_exists?, #current_packages_with_relations, #detected_package_path, id, #initialize, #installed?, #prepare, #project_root?
Class Method Details
.takes_priority_over ⇒ Object
24
25
26
|
# File 'lib/license_finder/package_managers/govendor.rb', line 24
def self.takes_priority_over
Go15VendorExperiment
end
|
Instance Method Details
#current_packages ⇒ Object
12
13
14
15
16
17
18
19
20
21
22
|
# File 'lib/license_finder/package_managers/govendor.rb', line 12
def current_packages
file = File.read(detected_package_path)
packages = packages_from_json(file)
packages.map do |package|
GoPackage.from_dependency({
'ImportPath' => package[:path],
'InstallPath' => project_path.join('vendor', package[:path]),
'Rev' => package[:sha]
}, nil, true)
end
end
|
#package_management_command ⇒ Object
28
29
30
|
# File 'lib/license_finder/package_managers/govendor.rb', line 28
def package_management_command
'govendor'
end
|
#possible_package_paths ⇒ Object
8
9
10
|
# File 'lib/license_finder/package_managers/govendor.rb', line 8
def possible_package_paths
[project_path.join('vendor', 'vendor.json')]
end
|
#prepare_command ⇒ Object
32
33
34
|
# File 'lib/license_finder/package_managers/govendor.rb', line 32
def prepare_command
'govendor sync'
end
|