autoproj 2.12.0 → 2.15.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/lint.yml +25 -0
- data/.github/workflows/test.yml +30 -0
- data/.rubocop.yml +79 -91
- data/.rubocop_todo.yml +1473 -0
- data/Gemfile +9 -9
- data/Rakefile +24 -24
- data/autoproj.gemspec +22 -22
- data/bin/alocate +4 -4
- data/bin/alog +6 -7
- data/bin/amake +4 -4
- data/bin/aup +4 -4
- data/bin/autoproj +2 -2
- data/bin/autoproj_bootstrap +186 -183
- data/bin/autoproj_bootstrap.in +7 -8
- data/bin/autoproj_install +185 -182
- data/bin/autoproj_install.in +6 -7
- data/lib/autoproj/aruba_minitest.rb +6 -11
- data/lib/autoproj/autobuild.rb +5 -6
- data/lib/autoproj/autobuild_extensions/archive_importer.rb +10 -11
- data/lib/autoproj/autobuild_extensions/dsl.rb +61 -44
- data/lib/autoproj/autobuild_extensions/git.rb +27 -26
- data/lib/autoproj/autobuild_extensions/package.rb +23 -22
- data/lib/autoproj/autobuild_extensions/svn.rb +1 -2
- data/lib/autoproj/base.rb +1 -1
- data/lib/autoproj/bash_completion.rb +5 -6
- data/lib/autoproj/build_option.rb +22 -24
- data/lib/autoproj/cli/base.rb +27 -27
- data/lib/autoproj/cli/bootstrap.rb +14 -16
- data/lib/autoproj/cli/build.rb +18 -10
- data/lib/autoproj/cli/cache.rb +51 -8
- data/lib/autoproj/cli/clean.rb +10 -10
- data/lib/autoproj/cli/commit.rb +7 -8
- data/lib/autoproj/cli/doc.rb +2 -2
- data/lib/autoproj/cli/envsh.rb +1 -2
- data/lib/autoproj/cli/exec.rb +60 -20
- data/lib/autoproj/cli/inspection_tool.rb +18 -13
- data/lib/autoproj/cli/locate.rb +30 -41
- data/lib/autoproj/cli/log.rb +7 -7
- data/lib/autoproj/cli/main.rb +217 -205
- data/lib/autoproj/cli/main_doc.rb +22 -21
- data/lib/autoproj/cli/main_global.rb +44 -19
- data/lib/autoproj/cli/main_plugin.rb +18 -18
- data/lib/autoproj/cli/main_test.rb +28 -27
- data/lib/autoproj/cli/manifest.rb +7 -7
- data/lib/autoproj/cli/osdeps.rb +12 -11
- data/lib/autoproj/cli/patcher.rb +2 -3
- data/lib/autoproj/cli/query.rb +17 -18
- data/lib/autoproj/cli/reconfigure.rb +1 -2
- data/lib/autoproj/cli/reset.rb +9 -12
- data/lib/autoproj/cli/show.rb +48 -55
- data/lib/autoproj/cli/status.rb +56 -44
- data/lib/autoproj/cli/switch_config.rb +5 -6
- data/lib/autoproj/cli/tag.rb +12 -11
- data/lib/autoproj/cli/test.rb +7 -7
- data/lib/autoproj/cli/update.rb +104 -51
- data/lib/autoproj/cli/utility.rb +14 -12
- data/lib/autoproj/cli/version.rb +42 -40
- data/lib/autoproj/cli/versions.rb +14 -15
- data/lib/autoproj/cli/watch.rb +33 -37
- data/lib/autoproj/cli/which.rb +16 -20
- data/lib/autoproj/cli.rb +4 -2
- data/lib/autoproj/configuration.rb +78 -85
- data/lib/autoproj/default.osdeps +29 -3
- data/lib/autoproj/environment.rb +42 -23
- data/lib/autoproj/exceptions.rb +9 -3
- data/lib/autoproj/find_workspace.rb +20 -25
- data/lib/autoproj/git_server_configuration.rb +40 -44
- data/lib/autoproj/gitorious.rb +1 -1
- data/lib/autoproj/installation_manifest.rb +64 -29
- data/lib/autoproj/local_package_set.rb +13 -11
- data/lib/autoproj/manifest.rb +145 -135
- data/lib/autoproj/metapackage.rb +2 -6
- data/lib/autoproj/ops/atomic_write.rb +7 -6
- data/lib/autoproj/ops/build.rb +4 -6
- data/lib/autoproj/ops/cache.rb +64 -53
- data/lib/autoproj/ops/cached_env.rb +7 -6
- data/lib/autoproj/ops/configuration.rb +511 -506
- data/lib/autoproj/ops/import.rb +90 -61
- data/lib/autoproj/ops/install.rb +179 -175
- data/lib/autoproj/ops/loader.rb +77 -76
- data/lib/autoproj/ops/main_config_switcher.rb +36 -45
- data/lib/autoproj/ops/phase_reporting.rb +4 -4
- data/lib/autoproj/ops/snapshot.rb +250 -247
- data/lib/autoproj/ops/tools.rb +76 -78
- data/lib/autoproj/ops/watch.rb +6 -6
- data/lib/autoproj/ops/which.rb +17 -14
- data/lib/autoproj/options.rb +13 -2
- data/lib/autoproj/os_package_installer.rb +102 -92
- data/lib/autoproj/os_package_query.rb +7 -13
- data/lib/autoproj/os_package_resolver.rb +189 -140
- data/lib/autoproj/os_repository_installer.rb +4 -4
- data/lib/autoproj/os_repository_resolver.rb +8 -6
- data/lib/autoproj/package_definition.rb +12 -13
- data/lib/autoproj/package_managers/apt_dpkg_manager.rb +46 -31
- data/lib/autoproj/package_managers/bundler_manager.rb +156 -118
- data/lib/autoproj/package_managers/debian_version.rb +25 -21
- data/lib/autoproj/package_managers/emerge_manager.rb +2 -3
- data/lib/autoproj/package_managers/gem_manager.rb +68 -77
- data/lib/autoproj/package_managers/homebrew_manager.rb +3 -4
- data/lib/autoproj/package_managers/manager.rb +8 -3
- data/lib/autoproj/package_managers/pacman_manager.rb +2 -3
- data/lib/autoproj/package_managers/pip_manager.rb +37 -27
- data/lib/autoproj/package_managers/pkg_manager.rb +3 -4
- data/lib/autoproj/package_managers/port_manager.rb +2 -3
- data/lib/autoproj/package_managers/shell_script_manager.rb +66 -36
- data/lib/autoproj/package_managers/unknown_os_manager.rb +5 -8
- data/lib/autoproj/package_managers/yum_manager.rb +12 -15
- data/lib/autoproj/package_managers/zypper_manager.rb +11 -14
- data/lib/autoproj/package_manifest.rb +66 -53
- data/lib/autoproj/package_selection.rb +187 -187
- data/lib/autoproj/package_set.rb +128 -114
- data/lib/autoproj/python.rb +285 -0
- data/lib/autoproj/query_base.rb +20 -14
- data/lib/autoproj/reporter.rb +19 -19
- data/lib/autoproj/repository_managers/apt.rb +101 -67
- data/lib/autoproj/repository_managers/unknown_os_manager.rb +3 -3
- data/lib/autoproj/shell_completion.rb +16 -13
- data/lib/autoproj/source_package_query.rb +29 -36
- data/lib/autoproj/system.rb +32 -21
- data/lib/autoproj/test.rb +131 -106
- data/lib/autoproj/variable_expansion.rb +10 -10
- data/lib/autoproj/vcs_definition.rb +53 -37
- data/lib/autoproj/version.rb +1 -1
- data/lib/autoproj/workspace.rb +162 -117
- data/lib/autoproj/zsh_completion.rb +8 -9
- data/lib/autoproj.rb +53 -53
- data/samples/autoproj/init.rb +1 -2
- metadata +62 -72
- data/.travis.yml +0 -22
@@ -3,7 +3,7 @@ module Autoproj
|
|
3
3
|
# in autoproj/
|
4
4
|
class LocalPackageSet < PackageSet
|
5
5
|
def initialize(ws, local_dir: ws.config_dir)
|
6
|
-
super(ws, VCSDefinition.none, name:
|
6
|
+
super(ws, VCSDefinition.none, name: "main configuration", raw_local_dir: local_dir)
|
7
7
|
@local_dir = local_dir
|
8
8
|
end
|
9
9
|
|
@@ -28,7 +28,7 @@ module Autoproj
|
|
28
28
|
end
|
29
29
|
|
30
30
|
def overrides_file_path
|
31
|
-
if d = local_dir
|
31
|
+
if (d = local_dir)
|
32
32
|
File.join(d, "overrides.yml")
|
33
33
|
end
|
34
34
|
end
|
@@ -47,7 +47,7 @@ module Autoproj
|
|
47
47
|
# Load the files in overrides.d in addition to the overrides: field in
|
48
48
|
# the yaml file
|
49
49
|
def load_overrides(source_definition)
|
50
|
-
files = Dir.glob(File.join(
|
50
|
+
files = Dir.glob(File.join(ws.overrides_dir, "*.yml")).sort
|
51
51
|
overrides = files.map do |file|
|
52
52
|
source_data = Autoproj.in_file(file, Autoproj::YAML_LOAD_ERROR) do
|
53
53
|
YAML.load(File.read(file)) || Array.new
|
@@ -55,7 +55,8 @@ module Autoproj
|
|
55
55
|
source_data =
|
56
56
|
if source_data.respond_to?(:to_ary)
|
57
57
|
source_data
|
58
|
-
else
|
58
|
+
else
|
59
|
+
source_data["overrides"] || Hash.new
|
59
60
|
end
|
60
61
|
[file, source_data]
|
61
62
|
end
|
@@ -64,24 +65,25 @@ module Autoproj
|
|
64
65
|
|
65
66
|
def raw_description_file
|
66
67
|
description = Hash[
|
67
|
-
|
68
|
-
|
69
|
-
|
68
|
+
"imports" => Array.new,
|
69
|
+
"version_control" => Array.new,
|
70
|
+
"overrides" => Array.new]
|
70
71
|
if File.file?(overrides_file_path)
|
71
72
|
overrides_data = Autoproj.in_file(overrides_file_path, Autoproj::YAML_LOAD_ERROR) do
|
72
73
|
YAML.load(File.read(overrides_file_path)) || Hash.new
|
73
74
|
end
|
74
75
|
overrides_data = PackageSet.validate_and_normalize_source_file(
|
75
|
-
overrides_file_path, overrides_data
|
76
|
+
overrides_file_path, overrides_data
|
77
|
+
)
|
76
78
|
description = description.merge(overrides_data)
|
77
79
|
end
|
78
80
|
|
79
81
|
manifest_data = Autoproj.in_file(manifest_path, Autoproj::YAML_LOAD_ERROR) do
|
80
82
|
YAML.load(File.read(manifest_path)) || Hash.new
|
81
83
|
end
|
82
|
-
description[
|
83
|
-
|
84
|
-
description[
|
84
|
+
description["imports"] = description["imports"]
|
85
|
+
.concat(manifest_data["package_sets"] || Array.new)
|
86
|
+
description["name"] = name
|
85
87
|
description
|
86
88
|
end
|
87
89
|
end
|