avm-tools 0.105.0 → 0.109.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/avm/instances/entry.rb +3 -3
- data/lib/avm/patches/eac_ruby_gems_utils/gem.rb +2 -2
- data/lib/avm/ruby/rubocop/_configured.rb +2 -2
- data/lib/avm/tools/app_src.rb +68 -0
- data/lib/avm/tools/runner/app_src/info.rb +26 -2
- data/lib/avm/tools/runner/app_src/ruby/bundler/gemfile_lock/git.rb +62 -0
- data/lib/avm/tools/runner/app_src/ruby/bundler/gemfile_lock.rb +11 -41
- data/lib/avm/tools/runner/app_src/ruby/bundler/incompatible.rb +2 -4
- data/lib/avm/tools/runner/app_src/update.rb +2 -2
- data/lib/avm/tools/runner/app_src.rb +6 -2
- data/lib/avm/tools/runner/config/load_path.rb +10 -5
- data/lib/avm/tools/runner/git/deploy.rb +2 -2
- data/lib/avm/tools/runner/self/registry.rb +25 -0
- data/lib/avm/tools/runner.rb +0 -4
- data/lib/avm/tools/version.rb +1 -1
- data/template/avm/ruby/gems/generator/static/spec/rubocop_spec.rb +1 -1
- data/template/avm/ruby/gems/generator/static/spec/spec_helper.rb +2 -100
- data/vendor/avm/avm.gemspec +4 -1
- data/{lib → vendor/avm/lib}/avm/data/instance/files_unit.rb +0 -0
- data/{lib → vendor/avm/lib}/avm/data/instance/package.rb +0 -0
- data/{lib → vendor/avm/lib}/avm/data/instance/unit.rb +0 -0
- data/{lib → vendor/avm/lib}/avm/data/instance.rb +0 -0
- data/{lib → vendor/avm/lib}/avm/data/package/dump.rb +0 -0
- data/{lib → vendor/avm/lib}/avm/data/package/load.rb +0 -0
- data/{lib → vendor/avm/lib}/avm/data/package.rb +0 -0
- data/{lib → vendor/avm/lib}/avm/data/unit.rb +0 -0
- data/vendor/avm/lib/avm/jobs/base.rb +62 -0
- data/vendor/avm/lib/avm/jobs/variables_source.rb +22 -0
- data/vendor/{avm-apps/lib/avm/apps.rb → avm/lib/avm/jobs.rb} +1 -1
- data/{lib → vendor/avm/lib}/avm/path_string.rb +0 -0
- data/vendor/avm/lib/avm/registry/base.rb +65 -0
- data/vendor/avm/lib/avm/registry.rb +29 -0
- data/vendor/avm/lib/avm/rspec/setup.rb +22 -0
- data/vendor/avm/lib/avm/rspec/shared_examples/in_avm_registry.rb +11 -0
- data/vendor/avm/lib/avm/rspec/shared_examples/not_in_avm_registry.rb +14 -0
- data/vendor/avm/lib/avm/rspec.rb +9 -0
- data/vendor/avm/lib/avm/scms/base.rb +28 -0
- data/vendor/avm/lib/avm/scms/commit.rb +43 -0
- data/vendor/avm/lib/avm/source_stereotypes/base.rb +21 -0
- data/vendor/avm/lib/avm/sources/base.rb +67 -0
- data/vendor/avm/lib/avm/sources/configuration/_locale.rb +16 -0
- data/vendor/avm/lib/avm/sources/configuration/_rubocop.rb +24 -0
- data/vendor/avm/lib/avm/sources/configuration/_tests.rb +27 -0
- data/vendor/avm/lib/avm/sources/configuration.rb +55 -0
- data/vendor/avm/lib/avm/sources.rb +9 -0
- data/{lib → vendor/avm/lib}/avm/sync.rb +0 -0
- data/vendor/avm/lib/avm/version.rb +1 -1
- data/vendor/avm/spec/lib/avm/scms/base_spec.rb +7 -0
- data/vendor/avm/spec/lib/avm/source_stereotypes/base_spec.rb +7 -0
- data/vendor/avm-eac_redmine_base0/avm-eac_redmine_base0.gemspec +2 -0
- data/vendor/avm-eac_redmine_base0/lib/avm/eac_redmine_base0/core_update.rb +3 -2
- data/vendor/avm-eac_redmine_base0/lib/avm/eac_redmine_base0/version.rb +1 -1
- data/vendor/{avm-apps → avm-eac_ruby_base1}/Gemfile +0 -0
- data/vendor/avm-eac_ruby_base1/avm-eac_ruby_base1.gemspec +19 -0
- data/vendor/avm-eac_ruby_base1/lib/avm/eac_ruby_base1/patches/i18n.rb +7 -0
- data/{lib/avm/patches/class.rb → vendor/avm-eac_ruby_base1/lib/avm/eac_ruby_base1/patches.rb} +0 -0
- data/vendor/avm-eac_ruby_base1/lib/avm/eac_ruby_base1/source_stereotypes/base.rb +25 -0
- data/vendor/avm-eac_ruby_base1/lib/avm/eac_ruby_base1/source_stereotypes/update/sub_update.rb +56 -0
- data/vendor/avm-eac_ruby_base1/lib/avm/eac_ruby_base1/source_stereotypes/update.rb +53 -0
- data/vendor/avm-eac_ruby_base1/lib/avm/eac_ruby_base1/source_stereotypes.rb +11 -0
- data/vendor/avm-eac_ruby_base1/lib/avm/eac_ruby_base1/version.rb +7 -0
- data/vendor/avm-eac_ruby_base1/lib/avm/eac_ruby_base1.rb +9 -0
- data/vendor/avm-eac_ruby_base1/locale/en.yaml +8 -0
- data/vendor/avm-eac_ruby_base1/locale/pt-BR.yaml +8 -0
- data/vendor/avm-eac_ruby_base1/spec/lib/avm/eac_ruby_base1/source_stereotypes/base_spec.rb +7 -0
- data/vendor/{avm-apps → avm-eac_ruby_base1}/spec/rubocop_spec.rb +0 -0
- data/vendor/{avm-apps → avm-eac_ruby_base1}/spec/spec_helper.rb +0 -0
- data/vendor/avm-eac_webapp_base0/lib/avm/eac_webapp_base0/apache_host.rb +2 -2
- data/vendor/avm-eac_webapp_base0/lib/avm/eac_webapp_base0/apache_path.rb +2 -2
- data/vendor/avm-eac_webapp_base0/lib/avm/eac_webapp_base0/deploy.rb +2 -2
- data/vendor/avm-files/Gemfile +5 -0
- data/vendor/avm-files/avm-files.gemspec +21 -0
- data/vendor/{avm → avm-files}/lib/avm/files/appendable/file_content.rb +0 -0
- data/vendor/{avm → avm-files}/lib/avm/files/appendable/plain_directory.rb +0 -0
- data/vendor/{avm → avm-files}/lib/avm/files/appendable/resource_base.rb +0 -0
- data/vendor/{avm → avm-files}/lib/avm/files/appendable/tar_output_command.rb +0 -0
- data/vendor/{avm → avm-files}/lib/avm/files/appendable/templatized_directory.rb +0 -0
- data/vendor/{avm → avm-files}/lib/avm/files/appendable.rb +0 -0
- data/vendor/{avm → avm-files}/lib/avm/files/appender.rb +0 -0
- data/vendor/{avm → avm-files}/lib/avm/files/deploy.rb +0 -0
- data/vendor/{avm → avm-files}/lib/avm/files/formatter/formats/base.rb +2 -2
- data/vendor/{avm → avm-files}/lib/avm/files/formatter/formats/generic_plain.rb +0 -0
- data/vendor/{avm → avm-files}/lib/avm/files/formatter/formats/html.rb +0 -0
- data/vendor/{avm → avm-files}/lib/avm/files/formatter/formats/javascript.rb +1 -0
- data/vendor/{avm → avm-files}/lib/avm/files/formatter/formats/json.rb +0 -0
- data/vendor/{avm → avm-files}/lib/avm/files/formatter/formats/php.rb +1 -0
- data/vendor/{avm → avm-files}/lib/avm/files/formatter/formats/python.rb +1 -0
- data/vendor/{avm → avm-files}/lib/avm/files/formatter/formats/ruby.rb +0 -0
- data/vendor/{avm → avm-files}/lib/avm/files/formatter/formats/xml.rb +1 -0
- data/vendor/{avm → avm-files}/lib/avm/files/formatter/formats.rb +0 -0
- data/vendor/{avm → avm-files}/lib/avm/files/formatter/utf8_assert.rb +3 -1
- data/vendor/{avm → avm-files}/lib/avm/files/formatter.rb +0 -0
- data/vendor/{avm → avm-files}/lib/avm/files/rotate.rb +0 -0
- data/vendor/avm-files/lib/avm/files/version.rb +7 -0
- data/vendor/avm-files/lib/avm/files.rb +9 -0
- data/vendor/avm-files/spec/rubocop_spec.rb +3 -0
- data/vendor/avm-files/spec/spec_helper.rb +4 -0
- data/vendor/avm-git/Gemfile +5 -0
- data/vendor/avm-git/avm-git.gemspec +21 -0
- data/vendor/{avm → avm-git}/lib/avm/git/auto_commit/commit_info.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/auto_commit/rules/base.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/auto_commit/rules/last.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/auto_commit/rules/manual.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/auto_commit/rules/new.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/auto_commit/rules/nth.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/auto_commit/rules/unique.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/auto_commit/rules.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/auto_commit_path/ruby.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/auto_commit_path.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/commit/class_methods.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/commit/deploy.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/commit/deploy_methods.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/commit/diff_tree_line.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/commit/file.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/commit.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/file_auto_fixup.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/issue/complete/commits.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/issue/complete/git_subrepos.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/issue/complete/local_branch.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/issue/complete/local_tag.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/issue/complete/push.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/issue/complete/remote.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/issue/complete/test.rb +2 -2
- data/vendor/{avm → avm-git}/lib/avm/git/issue/complete/tracker.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/issue/complete/validation.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/issue/complete/validations.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/issue/complete/working_tree.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/issue/complete.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/issue/deliver.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/issue.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/organize/reference_update.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/organize/repository.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/organize.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/revision_test.rb +2 -3
- data/vendor/avm-git/lib/avm/git/scms/git/change_tracker.rb +35 -0
- data/vendor/avm-git/lib/avm/git/scms/git/commit.rb +55 -0
- data/vendor/avm-git/lib/avm/git/scms/git.rb +65 -0
- data/vendor/avm-git/lib/avm/git/scms/git_subrepo.rb +41 -0
- data/vendor/avm-git/lib/avm/git/scms/provider.rb +19 -0
- data/vendor/{avm-apps/lib/avm/apps/jobs.rb → avm-git/lib/avm/git/scms.rb} +2 -2
- data/vendor/{avm → avm-git}/lib/avm/git/subrepo_check/parent.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/subrepo_check/remote.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/subrepo_check/show_result.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/subrepo_check.rb +0 -0
- data/vendor/{avm → avm-git}/lib/avm/git/subrepo_checks.rb +0 -0
- data/vendor/{avm-apps/lib/avm/apps → avm-git/lib/avm/git}/version.rb +2 -2
- data/vendor/{avm → avm-git}/lib/avm/git.rb +3 -2
- data/vendor/{avm → avm-git}/spec/lib/avm/git/auto_commit_path_spec.rb +4 -3
- data/vendor/{avm → avm-git}/spec/lib/avm/git/commit/deploy_spec.rb +0 -0
- data/vendor/{avm → avm-git}/spec/lib/avm/git/commit/diff_tree_line_spec.rb +0 -0
- data/vendor/{avm → avm-git}/spec/lib/avm/git/commit/diff_tree_line_spec_files/add.source.out +0 -0
- data/vendor/{avm → avm-git}/spec/lib/avm/git/commit/diff_tree_line_spec_files/add.target.yaml +0 -0
- data/vendor/{avm → avm-git}/spec/lib/avm/git/commit/diff_tree_line_spec_files/modify.source.out +0 -0
- data/vendor/{avm → avm-git}/spec/lib/avm/git/commit/diff_tree_line_spec_files/modify.target.yaml +0 -0
- data/vendor/{avm → avm-git}/spec/lib/avm/git/commit/diff_tree_line_spec_files/remove.source.out +0 -0
- data/vendor/{avm → avm-git}/spec/lib/avm/git/commit/diff_tree_line_spec_files/remove.target.yaml +0 -0
- data/vendor/{avm → avm-git}/spec/lib/avm/git/commit/diff_tree_line_spec_files/rename.source.out +0 -0
- data/vendor/{avm → avm-git}/spec/lib/avm/git/commit/diff_tree_line_spec_files/rename.target.yaml +0 -0
- data/vendor/{avm → avm-git}/spec/lib/avm/git/commit/diff_tree_line_spec_files/rename_modify.source.out +0 -0
- data/vendor/{avm → avm-git}/spec/lib/avm/git/commit/diff_tree_line_spec_files/rename_modify.target.yaml +0 -0
- data/vendor/{avm → avm-git}/spec/lib/avm/git/commit_spec.rb +0 -0
- data/vendor/avm-git/spec/lib/avm/git/scms/git_spec.rb +8 -0
- data/vendor/avm-git/spec/lib/avm/git/scms/git_subrepo_spec.rb +8 -0
- data/vendor/avm-git/spec/rubocop_spec.rb +3 -0
- data/vendor/avm-git/spec/spec_helper.rb +4 -0
- data/vendor/eac_cli/lib/eac_cli/config.rb +6 -3
- data/vendor/eac_cli/lib/eac_cli/definition/argument_option.rb +1 -1
- data/vendor/eac_cli/lib/eac_cli/definition/base_option.rb +9 -1
- data/vendor/eac_cli/lib/eac_cli/definition/boolean_option.rb +6 -0
- data/vendor/eac_cli/lib/eac_cli/runner_with/help/builder.rb +3 -3
- data/vendor/eac_cli/lib/eac_cli/version.rb +1 -1
- data/vendor/eac_cli/spec/lib/eac_cli/runner_spec.rb +6 -5
- data/vendor/eac_fs/Gemfile +5 -0
- data/vendor/eac_fs/eac_fs.gemspec +20 -0
- data/vendor/{eac_ruby_utils/lib/eac_ruby_utils/filesystem_cache.rb → eac_fs/lib/eac_fs/cache.rb} +7 -2
- data/{lib/avm → vendor/eac_fs/lib/eac_fs}/cached_download.rb +4 -4
- data/vendor/eac_fs/lib/eac_fs/file_info.rb +29 -0
- data/vendor/eac_fs/lib/eac_fs/patches/module/fs_cache.rb +10 -0
- data/vendor/eac_fs/lib/eac_fs/patches/module.rb +4 -0
- data/vendor/eac_fs/lib/eac_fs/patches/object/fs_cache.rb +15 -0
- data/vendor/eac_fs/lib/eac_fs/patches/object.rb +4 -0
- data/vendor/eac_fs/lib/eac_fs/patches/pathname/info.rb +12 -0
- data/vendor/eac_fs/lib/eac_fs/patches/pathname.rb +4 -0
- data/vendor/{avm/lib/avm/files.rb → eac_fs/lib/eac_fs/patches.rb} +0 -5
- data/vendor/eac_fs/lib/eac_fs/version.rb +5 -0
- data/vendor/eac_fs/lib/eac_fs.rb +7 -0
- data/vendor/{eac_ruby_utils/spec/lib/eac_ruby_utils/filesystem_cache_spec.rb → eac_fs/spec/lib/eac_fs/cache_spec.rb} +2 -2
- data/vendor/eac_fs/spec/rubocop_spec.rb +3 -0
- data/vendor/eac_fs/spec/spec_helper.rb +4 -0
- data/vendor/eac_git/lib/eac_git/local/commit/archive.rb +1 -1
- data/vendor/eac_git/lib/eac_git/local/commit.rb +24 -5
- data/vendor/eac_git/lib/eac_git/local/log.rb +17 -0
- data/vendor/eac_git/lib/eac_git/local.rb +39 -0
- data/vendor/eac_git/lib/eac_git/rspec/stubbed_git_local_repo.rb +11 -0
- data/vendor/eac_git/lib/eac_git/version.rb +1 -1
- data/vendor/eac_ruby_base0/eac_ruby_base0.gemspec +2 -1
- data/vendor/eac_ruby_base0/lib/eac_ruby_base0/application.rb +4 -4
- data/vendor/eac_ruby_base0/lib/eac_ruby_base0/core_ext.rb +1 -0
- data/vendor/eac_ruby_base0/lib/eac_ruby_base0/runner.rb +16 -7
- data/vendor/eac_ruby_base0/lib/eac_ruby_base0/version.rb +1 -1
- data/vendor/eac_ruby_gems_utils/lib/eac_ruby_gems_utils/tests/base.rb +0 -5
- data/vendor/eac_ruby_gems_utils/lib/eac_ruby_gems_utils/version.rb +1 -1
- data/vendor/eac_ruby_utils/lib/eac_ruby_utils/abstract_methods.rb +7 -0
- data/vendor/eac_ruby_utils/lib/eac_ruby_utils/compact.rb +22 -0
- data/vendor/eac_ruby_utils/lib/eac_ruby_utils/patches/class/abstract.rb +9 -0
- data/vendor/eac_ruby_utils/lib/eac_ruby_utils/patches/class/self_included_modules.rb +7 -0
- data/{lib/avm/patches/class/i18n.rb → vendor/eac_ruby_utils/lib/eac_ruby_utils/patches/module/i18n_translate.rb} +8 -7
- data/vendor/eac_ruby_utils/lib/eac_ruby_utils/patches/object/call_if_proc.rb +11 -0
- data/vendor/eac_ruby_utils/lib/eac_ruby_utils/patches/object/compact.rb +20 -0
- data/vendor/eac_ruby_utils/lib/eac_ruby_utils/patches/object/i18n_translate.rb +13 -0
- data/vendor/eac_ruby_utils/lib/eac_ruby_utils/patches/string/delimited.rb +16 -0
- data/vendor/eac_ruby_utils/lib/eac_ruby_utils/speaker/receiver.rb +10 -10
- data/vendor/eac_ruby_utils/lib/eac_ruby_utils/string_delimited.rb +70 -0
- data/vendor/eac_ruby_utils/lib/eac_ruby_utils/version.rb +1 -1
- data/vendor/eac_ruby_utils/spec/lib/eac_ruby_utils/compact_spec.rb +20 -0
- data/vendor/eac_ruby_utils/spec/lib/eac_ruby_utils/patches/class/abstract_spec.rb +25 -0
- data/vendor/eac_ruby_utils/spec/lib/eac_ruby_utils/patches/class/self_included_modules_spec.rb +30 -0
- data/vendor/eac_ruby_utils/spec/lib/eac_ruby_utils/patches/object/call_if_proc_spec.rb +11 -0
- data/vendor/eac_ruby_utils/spec/lib/eac_ruby_utils/patches/object/compact_spec.rb +20 -0
- data/vendor/eac_ruby_utils/spec/lib/eac_ruby_utils/patches/string/delimited_spec.rb +34 -0
- data/vendor/eac_templates/lib/eac_templates/patches/module/erb_template.rb +9 -0
- data/vendor/eac_templates/lib/eac_templates/patches/module.rb +4 -0
- data/vendor/eac_templates/lib/eac_templates/patches/object/erb_template.rb +9 -0
- data/vendor/eac_templates/lib/eac_templates/patches/object.rb +4 -0
- data/vendor/eac_templates/lib/eac_templates/patches.rb +4 -0
- data/vendor/eac_templates/lib/eac_templates/version.rb +1 -1
- metadata +192 -279
- data/lib/avm/app_src.rb +0 -61
- data/lib/avm/fs_cache.rb +0 -11
- data/lib/avm/patches/i18n.rb +0 -22
- data/lib/avm/patches/object/fs_cache.rb +0 -16
- data/lib/avm/patches/object/i18n.rb +0 -9
- data/lib/avm/projects/stereotypes/git/update/subrepo.rb +0 -85
- data/lib/avm/projects/stereotypes/git/update.rb +0 -41
- data/lib/avm/projects/stereotypes/ruby_gem/update.rb +0 -66
- data/vendor/avm/lib/avm/files/info.rb +0 -24
- data/vendor/avm-apps/avm-apps.gemspec +0 -18
- data/vendor/avm-apps/lib/avm/apps/config.rb +0 -19
- data/vendor/avm-apps/lib/avm/apps/jobs/base.rb +0 -64
- data/vendor/avm-apps/lib/avm/apps/jobs/variables_source.rb +0 -24
- data/vendor/avm-apps/lib/avm/apps/sources/configuration/_locale.rb +0 -18
- data/vendor/avm-apps/lib/avm/apps/sources/configuration/_rubocop.rb +0 -26
- data/vendor/avm-apps/lib/avm/apps/sources/configuration/_tests.rb +0 -29
- data/vendor/avm-apps/lib/avm/apps/sources/configuration.rb +0 -57
- data/vendor/eac_ruby_utils/lib/eac_ruby_utils/fs_cache.rb +0 -12
@@ -0,0 +1,56 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Avm
|
4
|
+
module EacRubyBase1
|
5
|
+
module SourceStereotypes
|
6
|
+
class Update
|
7
|
+
class SubUpdate
|
8
|
+
enable_simple_cache
|
9
|
+
enable_speaker
|
10
|
+
common_constructor :source_update, :sub do
|
11
|
+
perform
|
12
|
+
end
|
13
|
+
delegate :source, to: :source_update
|
14
|
+
|
15
|
+
protected
|
16
|
+
|
17
|
+
def on_scm_updated(commit)
|
18
|
+
if commit.no_scm_changed_files.any?
|
19
|
+
commit = commit.reword(no_scm_update_commit_message)
|
20
|
+
source.scm.commit_if_change { source_update.bundle_update }
|
21
|
+
.if_present { |v| v.merge_with(commit) }
|
22
|
+
else
|
23
|
+
commit.reword(scm_update_commit_message)
|
24
|
+
end
|
25
|
+
end
|
26
|
+
|
27
|
+
def perform
|
28
|
+
update_scm.if_present { |commit| on_scm_updated(commit) }
|
29
|
+
end
|
30
|
+
|
31
|
+
def ruby_gem_uncached
|
32
|
+
::EacRubyGemsUtils::Gem.new(sub.path)
|
33
|
+
end
|
34
|
+
|
35
|
+
def no_scm_update_commit_message
|
36
|
+
source_update.i18n_translate(__method__, __locale: source.locale,
|
37
|
+
name: ruby_gem.name,
|
38
|
+
version: ruby_gem.version)
|
39
|
+
end
|
40
|
+
|
41
|
+
def scm_update_commit_message
|
42
|
+
source_update.i18n_translate(__method__, __locale: source.locale)
|
43
|
+
end
|
44
|
+
|
45
|
+
# @return [Avm::Scms::Commit]
|
46
|
+
def update_scm
|
47
|
+
infom "Updating \"#{sub}\"..."
|
48
|
+
source.scm.commit_if_change do
|
49
|
+
sub.scm.update
|
50
|
+
end
|
51
|
+
end
|
52
|
+
end
|
53
|
+
end
|
54
|
+
end
|
55
|
+
end
|
56
|
+
end
|
@@ -0,0 +1,53 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require 'avm/eac_ruby_base1/patches/i18n'
|
4
|
+
require 'eac_ruby_utils/core_ext'
|
5
|
+
|
6
|
+
module Avm
|
7
|
+
module EacRubyBase1
|
8
|
+
module SourceStereotypes
|
9
|
+
class Update
|
10
|
+
require_sub __FILE__
|
11
|
+
enable_simple_cache
|
12
|
+
enable_speaker
|
13
|
+
common_constructor :source do
|
14
|
+
perform
|
15
|
+
end
|
16
|
+
|
17
|
+
def bundle_update
|
18
|
+
infom 'Running "bundle update"...'
|
19
|
+
ruby_gem.bundle('update').execute!
|
20
|
+
infom 'Running "bundle install"...'
|
21
|
+
ruby_gem.bundle('install').execute!
|
22
|
+
end
|
23
|
+
|
24
|
+
protected
|
25
|
+
|
26
|
+
def perform
|
27
|
+
update_gemfile_lock
|
28
|
+
update_subs
|
29
|
+
end
|
30
|
+
|
31
|
+
def update_gemfile_lock
|
32
|
+
source.scm.commit_if_change(-> { update_gemfile_lock_commit_message }) do
|
33
|
+
bundle_update
|
34
|
+
end
|
35
|
+
end
|
36
|
+
|
37
|
+
def update_gemfile_lock_commit_message
|
38
|
+
i18n_translate(__method__, __locale: source.locale)
|
39
|
+
end
|
40
|
+
|
41
|
+
def update_subs
|
42
|
+
source.subs.each do |sub|
|
43
|
+
::Avm::EacRubyBase1::SourceStereotypes::Update::SubUpdate.new(self, sub)
|
44
|
+
end
|
45
|
+
end
|
46
|
+
|
47
|
+
def ruby_gem_uncached
|
48
|
+
::EacRubyGemsUtils::Gem.new(source.path)
|
49
|
+
end
|
50
|
+
end
|
51
|
+
end
|
52
|
+
end
|
53
|
+
end
|
@@ -0,0 +1,8 @@
|
|
1
|
+
pt-BR:
|
2
|
+
avm:
|
3
|
+
eac_ruby_base1:
|
4
|
+
source_stereotypes:
|
5
|
+
update:
|
6
|
+
no_scm_update_commit_message: "Gem \"%{name}\" (Local): atualiza para '%{version}'."
|
7
|
+
scm_update_commit_message: '**/.gitrepo: conserta/atualiza.'
|
8
|
+
update_gemfile_lock_commit_message: 'Todas as gems: atualiza.'
|
File without changes
|
File without changes
|
@@ -1,7 +1,7 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
3
|
require 'eac_ruby_utils/core_ext'
|
4
|
-
require 'avm/
|
4
|
+
require 'avm/jobs/base'
|
5
5
|
require 'avm/patches/object/template'
|
6
6
|
require 'avm/eac_ubuntu_base0/apache'
|
7
7
|
require 'avm/patches/object/template'
|
@@ -11,7 +11,7 @@ module Avm
|
|
11
11
|
class ApacheHost
|
12
12
|
JOBS = %w[write_available_no_ssl_site enable_no_ssl_site remove_ssl_site reload_apache
|
13
13
|
run_certbot enable_ssl_site reload_apache].freeze
|
14
|
-
include ::Avm::
|
14
|
+
include ::Avm::Jobs::Base
|
15
15
|
|
16
16
|
def no_ssl_site_content
|
17
17
|
::Avm::EacWebappBase0::ApacheHost
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
-
require 'avm/
|
3
|
+
require 'avm/jobs/base'
|
4
4
|
require 'avm/eac_ubuntu_base0/apache'
|
5
5
|
require 'eac_ruby_utils/core_ext'
|
6
6
|
|
@@ -8,7 +8,7 @@ module Avm
|
|
8
8
|
module EacWebappBase0
|
9
9
|
class ApachePath
|
10
10
|
JOBS = %w[write_available_conf enable_conf reload_apache].freeze
|
11
|
-
include ::Avm::
|
11
|
+
include ::Avm::Jobs::Base
|
12
12
|
|
13
13
|
def content
|
14
14
|
::Avm::EacWebappBase0::ApachePath.template.child('default.conf').apply(variables_source)
|
@@ -1,7 +1,7 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
3
|
require 'active_support/callbacks'
|
4
|
-
require 'avm/
|
4
|
+
require 'avm/jobs/base'
|
5
5
|
require 'avm/git'
|
6
6
|
require 'avm/patches/object/template'
|
7
7
|
require 'eac_ruby_utils/core_ext'
|
@@ -19,7 +19,7 @@ module Avm
|
|
19
19
|
JOBS = (%w[create_build_dir build_content append_instance_content write_on_target
|
20
20
|
setup_files_units assert_instance_branch] + [REQUEST_TEST_JOB]).freeze
|
21
21
|
|
22
|
-
include ::Avm::
|
22
|
+
include ::Avm::Jobs::Base
|
23
23
|
|
24
24
|
lists.add_symbol :option, :appended_directories, :no_request_test, :reference
|
25
25
|
|
@@ -0,0 +1,21 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
$LOAD_PATH.push File.expand_path('lib', __dir__)
|
4
|
+
|
5
|
+
require 'avm/files/version'
|
6
|
+
|
7
|
+
Gem::Specification.new do |s|
|
8
|
+
s.name = 'avm-files'
|
9
|
+
s.version = Avm::Files::VERSION
|
10
|
+
s.authors = ['Put here the authors']
|
11
|
+
s.summary = 'Put here de description.'
|
12
|
+
|
13
|
+
s.files = Dir['{lib}/**/*']
|
14
|
+
|
15
|
+
s.add_dependency 'avm', '~> 0.6'
|
16
|
+
s.add_dependency 'eac_fs', '~> 0.5'
|
17
|
+
s.add_dependency 'eac_ruby_utils', '~> 0.76'
|
18
|
+
s.add_dependency 'eac_templates', '~> 0.2'
|
19
|
+
|
20
|
+
s.add_development_dependency 'eac_ruby_gem_support', '~> 0.4'
|
21
|
+
end
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
-
require '
|
3
|
+
require 'eac_fs/file_info'
|
4
4
|
require 'ostruct'
|
5
5
|
|
6
6
|
module Avm
|
@@ -50,7 +50,7 @@ module Avm
|
|
50
50
|
end
|
51
51
|
|
52
52
|
def match_by_type?(file)
|
53
|
-
info = ::
|
53
|
+
info = ::EacFs::FileInfo.new(file)
|
54
54
|
return unless info.content_type.type == 'text'
|
55
55
|
|
56
56
|
valid_types.include?(info.content_type.subtype)
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
@@ -1,5 +1,7 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
+
require 'eac_fs/file_info'
|
4
|
+
|
3
5
|
module Avm
|
4
6
|
module Files
|
5
7
|
class Formatter
|
@@ -37,7 +39,7 @@ module Avm
|
|
37
39
|
private
|
38
40
|
|
39
41
|
def original_info_uncached
|
40
|
-
::
|
42
|
+
::EacFs::FileInfo.new(path)
|
41
43
|
end
|
42
44
|
|
43
45
|
def original_charset_uncached
|
File without changes
|
File without changes
|
@@ -0,0 +1,21 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
$LOAD_PATH.push File.expand_path('lib', __dir__)
|
4
|
+
|
5
|
+
require 'avm/git/version'
|
6
|
+
|
7
|
+
Gem::Specification.new do |s|
|
8
|
+
s.name = 'avm-git'
|
9
|
+
s.version = Avm::Git::VERSION
|
10
|
+
s.authors = ['Put here the authors']
|
11
|
+
s.summary = 'Put here de description.'
|
12
|
+
|
13
|
+
s.files = Dir['{lib}/**/*']
|
14
|
+
|
15
|
+
s.add_dependency 'avm-files', '~> 0.1'
|
16
|
+
s.add_dependency 'eac_git', '~> 0.9'
|
17
|
+
s.add_dependency 'eac_ruby_utils', '~> 0.76'
|
18
|
+
|
19
|
+
s.add_development_dependency 'aranha-parsers', '~> 0.8', '>= 0.8.5'
|
20
|
+
s.add_development_dependency 'eac_ruby_gem_support', '~> 0.4'
|
21
|
+
end
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
@@ -1,6 +1,6 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
-
require 'avm/
|
3
|
+
require 'avm/sources/configuration'
|
4
4
|
require 'avm/result'
|
5
5
|
require 'eac_ruby_utils/fs/temp'
|
6
6
|
|
@@ -36,7 +36,7 @@ module Avm
|
|
36
36
|
end
|
37
37
|
|
38
38
|
def configuration_uncached
|
39
|
-
::Avm::
|
39
|
+
::Avm::Sources::Configuration.find_by_path(@git)
|
40
40
|
end
|
41
41
|
end
|
42
42
|
end
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
@@ -1,6 +1,5 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
-
require 'avm/fs_cache'
|
4
3
|
require 'eac_ruby_utils/core_ext'
|
5
4
|
require 'eac_ruby_utils/ruby'
|
6
5
|
|
@@ -53,8 +52,8 @@ module Avm
|
|
53
52
|
end
|
54
53
|
|
55
54
|
def root_cache
|
56
|
-
|
57
|
-
|
55
|
+
fs_cache.child(git_absolute_path.parameterize, sha1,
|
56
|
+
options.fetch(:test_command).to_s.parameterize)
|
58
57
|
end
|
59
58
|
|
60
59
|
def run_test
|
@@ -0,0 +1,35 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require 'eac_ruby_utils/core_ext'
|
4
|
+
|
5
|
+
module Avm
|
6
|
+
module Git
|
7
|
+
module Scms
|
8
|
+
class Git < ::Avm::Scms::Base
|
9
|
+
class ChangeTracker
|
10
|
+
common_constructor :git_scm, :message
|
11
|
+
attr_reader :starting_commit
|
12
|
+
delegate :git_repo, to: :git_scm
|
13
|
+
|
14
|
+
def start
|
15
|
+
raise 'Repository is dirty' if git_repo.dirty?
|
16
|
+
|
17
|
+
self.starting_commit = git_repo.head
|
18
|
+
end
|
19
|
+
|
20
|
+
# @return [Avm::Git::Scms::Git::Commit, nil]
|
21
|
+
def stop
|
22
|
+
git_scm.commit_dirty
|
23
|
+
return nil if starting_commit == git_repo.head
|
24
|
+
|
25
|
+
git_scm.reset_and_commit(starting_commit, message)
|
26
|
+
end
|
27
|
+
|
28
|
+
private
|
29
|
+
|
30
|
+
attr_writer :starting_commit
|
31
|
+
end
|
32
|
+
end
|
33
|
+
end
|
34
|
+
end
|
35
|
+
end
|
@@ -0,0 +1,55 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require 'avm/scms/commit'
|
4
|
+
require 'eac_ruby_utils/core_ext'
|
5
|
+
|
6
|
+
module Avm
|
7
|
+
module Git
|
8
|
+
module Scms
|
9
|
+
class Git < ::Avm::Scms::Base
|
10
|
+
class Commit < ::Avm::Scms::Commit
|
11
|
+
common_constructor :git_scm, :git_commit do
|
12
|
+
git_commit.assert_argument(::EacGit::Local::Commit, 'git_commit')
|
13
|
+
end
|
14
|
+
delegate :git_repo, to: :git_scm
|
15
|
+
|
16
|
+
# @return [Array<Pathname>]
|
17
|
+
def changed_files
|
18
|
+
git_commit.changed_files.map { |cf| cf.path.to_pathname }
|
19
|
+
end
|
20
|
+
|
21
|
+
# @param other [Avm::Git::Scms::Git::Commit]
|
22
|
+
# @return [Avm::Git::Scms::Git::Commit]
|
23
|
+
def merge_with(other)
|
24
|
+
validate_clean_and_head
|
25
|
+
raise 'Implemented for only if other is parent' unless
|
26
|
+
other.git_commit == git_commit.parent
|
27
|
+
|
28
|
+
git_scm.reset_and_commit(other.git_commit.parent, other.git_commit.raw_body)
|
29
|
+
end
|
30
|
+
|
31
|
+
def reword(new_message)
|
32
|
+
validate_clean_and_head
|
33
|
+
|
34
|
+
git_repo.command('commit', '--amend', '-m', new_message).execute!
|
35
|
+
self.class.new(git_scm, git_repo.head)
|
36
|
+
end
|
37
|
+
|
38
|
+
# @param path [Pathname]
|
39
|
+
# @return [TrueClass,FalseClass]
|
40
|
+
def scm_file?(path)
|
41
|
+
%w[.gitrepo .gitmodules].any? { |file| file.include?(path.basename.to_path) }
|
42
|
+
end
|
43
|
+
|
44
|
+
private
|
45
|
+
|
46
|
+
def validate_clean_and_head
|
47
|
+
raise 'Implemented for only if repository is no dirty' if git_repo.dirty?
|
48
|
+
raise 'Implemented for only if self is HEAD' unless
|
49
|
+
git_commit == git_repo.head
|
50
|
+
end
|
51
|
+
end
|
52
|
+
end
|
53
|
+
end
|
54
|
+
end
|
55
|
+
end
|