avm-tools 0.74.1 → 0.77.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (87) hide show
  1. checksums.yaml +4 -4
  2. data/lib/avm/eac_rails_base1/runner/bundle.rb +2 -2
  3. data/lib/avm/eac_rails_base1/runner/code_runner.rb +3 -3
  4. data/lib/avm/eac_webapp_base0/deploy.rb +17 -40
  5. data/lib/avm/eac_webapp_base0/deploy/build.rb +48 -0
  6. data/lib/avm/eac_webapp_base0/deploy/git_info.rb +13 -0
  7. data/lib/avm/eac_webapp_base0/deploy/version.rb +4 -0
  8. data/lib/avm/eac_webapp_base0/deploy/write_on_target.rb +18 -0
  9. data/lib/avm/eac_webapp_base0/runner/deploy.rb +1 -0
  10. data/lib/avm/eac_writings_base0/apache_host.rb +17 -0
  11. data/lib/avm/eac_writings_base0/deploy.rb +36 -0
  12. data/lib/avm/eac_writings_base0/instance.rb +11 -0
  13. data/lib/avm/files/appendable.rb +55 -0
  14. data/lib/avm/files/appendable/file_content.rb +24 -0
  15. data/lib/avm/files/appendable/plain_directory.rb +25 -0
  16. data/lib/avm/files/appendable/resource_base.rb +13 -0
  17. data/lib/avm/files/appendable/tar_output_command.rb +26 -0
  18. data/lib/avm/files/appendable/templatized_directory.rb +28 -0
  19. data/lib/avm/files/appender.rb +11 -0
  20. data/lib/avm/files/deploy.rb +72 -0
  21. data/lib/avm/files/formatter.rb +8 -4
  22. data/lib/avm/git/auto_commit_path.rb +2 -4
  23. data/lib/avm/git/auto_commit_path/ruby.rb +20 -0
  24. data/lib/avm/git/commit/deploy.rb +8 -61
  25. data/lib/avm/tools/runner/eac_rails_base0/rails_server.rb +1 -0
  26. data/lib/avm/tools/runner/eac_redmine_base0/project_rename.rb +7 -16
  27. data/lib/avm/tools/runner/eac_writings_base0.rb +15 -0
  28. data/lib/avm/tools/runner/files/format.rb +3 -2
  29. data/lib/avm/tools/runner/git/auto_commit.rb +11 -0
  30. data/lib/avm/tools/runner/git/deploy.rb +1 -1
  31. data/lib/avm/tools/version.rb +1 -1
  32. data/template/avm/eac_redmine_base0/deploy/config/install.sh.template +12 -0
  33. data/template/avm/{stereotypes/eac_ubuntu_base0 → eac_ubuntu_base0}/docker_image/Dockerfile +0 -0
  34. data/template/avm/{stereotypes/eac_wordpress_base0 → eac_wordpress_base0}/deploy/wp-config.php.template +0 -0
  35. data/template/avm/eac_writings_base0/deploy/index.html.template +9 -0
  36. data/vendor/eac_cli/eac_cli.gemspec +1 -1
  37. data/vendor/eac_cli/lib/eac_cli/definition.rb +49 -22
  38. data/vendor/eac_cli/lib/eac_cli/definition/alternative.rb +83 -0
  39. data/vendor/eac_cli/lib/eac_cli/definition/base_option.rb +17 -1
  40. data/vendor/eac_cli/lib/eac_cli/{parser/options_collection.rb → definition/help_formatter.rb} +20 -49
  41. data/vendor/eac_cli/lib/eac_cli/definition/positional_argument.rb +21 -4
  42. data/vendor/eac_cli/lib/eac_cli/docopt/doc_builder.rb +18 -40
  43. data/vendor/eac_cli/lib/eac_cli/docopt/doc_builder/alternative.rb +50 -0
  44. data/vendor/eac_cli/lib/eac_cli/docopt/runner_extension.rb +1 -0
  45. data/vendor/eac_cli/lib/eac_cli/parser.rb +21 -3
  46. data/vendor/eac_cli/lib/eac_cli/parser/alternative.rb +88 -0
  47. data/vendor/eac_cli/lib/eac_cli/parser/alternative/argv.rb +17 -0
  48. data/vendor/eac_cli/lib/eac_cli/parser/alternative/double_dash.rb +24 -0
  49. data/vendor/eac_cli/lib/eac_cli/parser/alternative/options.rb +58 -0
  50. data/vendor/eac_cli/lib/eac_cli/parser/alternative/positionals.rb +30 -0
  51. data/vendor/eac_cli/lib/eac_cli/parser/collector.rb +4 -0
  52. data/vendor/eac_cli/lib/eac_cli/patches/object/runner_with.rb +2 -1
  53. data/vendor/eac_cli/lib/eac_cli/runner.rb +6 -2
  54. data/vendor/eac_cli/lib/eac_cli/runner_with/help.rb +1 -1
  55. data/vendor/eac_cli/lib/eac_cli/runner_with/subcommands.rb +96 -0
  56. data/vendor/eac_cli/lib/eac_cli/version.rb +1 -1
  57. data/vendor/eac_cli/spec/lib/eac_cli/definition/alternative_spec.rb +14 -0
  58. data/vendor/eac_cli/spec/lib/eac_cli/docopt/runner_extension_spec.rb +35 -0
  59. data/vendor/eac_cli/spec/lib/eac_cli/parser/alternative_spec.rb +140 -0
  60. data/vendor/eac_cli/spec/lib/eac_cli/runner_spec.rb +57 -40
  61. data/vendor/eac_cli/spec/lib/eac_cli/runner_with/subcommands_spec.rb +57 -0
  62. data/vendor/eac_ruby_base0/lib/eac_ruby_base0/application.rb +32 -1
  63. data/vendor/eac_ruby_base0/lib/eac_ruby_base0/runner.rb +1 -1
  64. data/vendor/eac_ruby_base0/lib/eac_ruby_base0/version.rb +1 -1
  65. data/vendor/eac_ruby_utils/lib/eac_ruby_utils/abstract_methods.rb +59 -0
  66. data/vendor/eac_ruby_utils/lib/eac_ruby_utils/console/configs.rb +7 -107
  67. data/vendor/eac_ruby_utils/lib/eac_ruby_utils/console/configs/entry_reader.rb +81 -0
  68. data/vendor/eac_ruby_utils/lib/eac_ruby_utils/console/configs/password_entry_reader.rb +18 -0
  69. data/vendor/eac_ruby_utils/lib/eac_ruby_utils/console/configs/read_entry_options.rb +46 -0
  70. data/vendor/eac_ruby_utils/lib/eac_ruby_utils/console/configs/store_passwords_entry_reader.rb +27 -0
  71. data/vendor/eac_ruby_utils/lib/eac_ruby_utils/patches/enumerator.rb +4 -0
  72. data/vendor/eac_ruby_utils/lib/eac_ruby_utils/patches/enumerator/current.rb +9 -0
  73. data/vendor/eac_ruby_utils/lib/eac_ruby_utils/patches/enumerator/stopped.rb +14 -0
  74. data/vendor/eac_ruby_utils/lib/eac_ruby_utils/patches/object/debug.rb +17 -0
  75. data/vendor/eac_ruby_utils/lib/eac_ruby_utils/version.rb +1 -1
  76. data/vendor/eac_ruby_utils/lib/eac_ruby_utils/yaml.rb +3 -2
  77. data/vendor/eac_ruby_utils/spec/lib/eac_ruby_utils/abstract_methods_spec.rb +28 -0
  78. data/vendor/eac_ruby_utils/spec/lib/eac_ruby_utils/patches/enumerator/current_spec.rb +26 -0
  79. data/vendor/eac_ruby_utils/spec/lib/eac_ruby_utils/patches/enumerator/stopped_spec.rb +32 -0
  80. metadata +45 -12
  81. data/lib/avm/git/commit/deploy/appended.rb +0 -37
  82. data/lib/avm/git/commit/deploy/appended/base.rb +0 -17
  83. data/lib/avm/git/commit/deploy/appended/directory.rb +0 -32
  84. data/lib/avm/git/commit/deploy/appended/file_content.rb +0 -28
  85. data/lib/avm/tools/runner/eac_rails_base0/bundle.rb +0 -14
  86. data/vendor/eac_cli/lib/eac_cli/parser/parse_result.rb +0 -21
  87. data/vendor/eac_cli/lib/eac_cli/parser/positional_collection.rb +0 -49
@@ -1,49 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require 'eac_ruby_utils/core_ext'
4
- require 'eac_cli/parser/error'
5
-
6
- module EacCli
7
- class Parser
8
- class PositionalCollection
9
- common_constructor(:definition, :argv, :collector) { collect }
10
-
11
- private
12
-
13
- def collected
14
- @collected ||= ::Set.new
15
- end
16
-
17
- def collect
18
- argv.each { |argv_value| colect_argv_value(argv_value) }
19
- return unless pending_required_positional?
20
-
21
- raise ::EacCli::Parser::Error.new(
22
- definition, argv, 'No value for required positional ' \
23
- "\"#{current_positional.identifier}\""
24
- )
25
- end
26
-
27
- def colect_argv_value(argv_value)
28
- collector.collect(current_positional, argv_value)
29
- collected << current_positional
30
- positional_enumerator.next unless current_positional.repeat?
31
- end
32
-
33
- def pending_required_positional?
34
- !(current_positional.blank? || current_positional.optional? ||
35
- collected.include?(current_positional))
36
- end
37
-
38
- def positional_enumerator
39
- @positional_enumerator ||= definition.positional.each
40
- end
41
-
42
- def current_positional
43
- positional_enumerator.peek
44
- rescue ::StopIteration
45
- nil
46
- end
47
- end
48
- end
49
- end