mina 1.2.4 → 1.2.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.github/workflows/ci.yml +11 -3
- data/.gitignore +0 -1
- data/.rspec +1 -1
- data/.rubocop.yml +28 -1126
- data/CHANGELOG.md +89 -8
- data/Gemfile +2 -0
- data/Gemfile.lock +73 -0
- data/Rakefile +2 -0
- data/Readme.md +8 -12
- data/bin/mina +2 -0
- data/data/deploy.rb +6 -4
- data/docs/3rd_party_plugins.md +1 -0
- data/docs/assets/images/mina.png +0 -0
- data/docs/default_plugins.md +1 -1
- data/docs/how_mina_works.md +2 -2
- data/lib/Minafile +1 -0
- data/lib/mina/application.rb +45 -35
- data/lib/mina/backend/local.rb +2 -0
- data/lib/mina/backend/remote.rb +3 -1
- data/lib/mina/commands.rb +10 -7
- data/lib/mina/configuration.rb +6 -3
- data/lib/mina/dsl.rb +2 -2
- data/lib/mina/helpers/internal.rb +8 -8
- data/lib/mina/helpers/output.rb +5 -3
- data/lib/mina/runner/exec.rb +2 -0
- data/lib/mina/runner/pretty.rb +25 -19
- data/lib/mina/runner/printer.rb +2 -0
- data/lib/mina/runner/system.rb +2 -0
- data/lib/mina/runner.rb +9 -10
- data/lib/mina/version.rb +3 -1
- data/lib/mina/windows_patches.rb +4 -2
- data/lib/mina.rb +4 -3
- data/mina.gemspec +8 -7
- data/spec/configs/default.rb +8 -0
- data/spec/configs/dsl.rb +55 -0
- data/spec/configs/e2e.rb +25 -0
- data/spec/e2e/docker-compose.yml +21 -0
- data/spec/e2e/e2e_run.sh +11 -0
- data/spec/e2e/e2e_spec.rb +35 -0
- data/spec/e2e/ssh +27 -0
- data/spec/e2e/ssh.pub +1 -0
- data/spec/lib/mina/application_spec.rb +94 -35
- data/spec/lib/mina/backend/local_spec.rb +5 -2
- data/spec/lib/mina/backend/remote_spec.rb +5 -3
- data/spec/lib/mina/commands_spec.rb +7 -7
- data/spec/lib/mina/configuration_spec.rb +63 -3
- data/spec/lib/mina/dsl_spec.rb +94 -0
- data/spec/lib/mina/helpers/internal_spec.rb +88 -10
- data/spec/lib/mina/helpers/output_spec.rb +13 -10
- data/spec/lib/mina/runner/exec_spec.rb +19 -0
- data/spec/lib/mina/runner/pretty_spec.rb +17 -0
- data/spec/lib/mina/runner/printer_spec.rb +19 -0
- data/spec/lib/mina/runner/system_spec.rb +19 -0
- data/spec/lib/mina/runner_spec.rb +6 -10
- data/spec/spec_helper.rb +33 -14
- data/spec/support/outputs/bundle_clean.txt +2 -2
- data/spec/support/outputs/chruby_with_env.txt +7 -0
- data/spec/support/outputs/chruby_without_env.txt +2 -0
- data/spec/support/outputs/debug_configuration_variables.txt +11 -0
- data/spec/support/outputs/dsl_deploy.txt +4 -0
- data/spec/support/outputs/dsl_in_path.txt +1 -0
- data/spec/support/outputs/dsl_local_run.txt +5 -0
- data/spec/support/outputs/dsl_on.txt +6 -0
- data/spec/support/outputs/dsl_remote_run.txt +5 -0
- data/spec/support/outputs/dsl_reset.txt +2 -0
- data/spec/support/outputs/e2e_deploy_after_setup.txt +1 -0
- data/spec/support/outputs/e2e_deploy_without_setup.txt +1 -0
- data/spec/support/outputs/e2e_setup.txt +1 -0
- data/spec/support/outputs/environment.txt +1 -0
- data/spec/support/outputs/git_ensure_pushed.txt +15 -0
- data/spec/support/outputs/rails_assets_precompile_force_precompile.txt +2 -0
- data/spec/support/outputs/rails_assets_precompile_outside_deploy_block.txt +1 -0
- data/spec/support/outputs/rails_assets_precompile_with_diff.txt +7 -0
- data/spec/support/outputs/rails_console.txt +1 -0
- data/spec/support/outputs/rails_db_migrate_force_migrate.txt +2 -0
- data/spec/support/outputs/rails_db_migrate_outside_deploy_block.txt +1 -0
- data/spec/support/outputs/rails_db_migrate_with_diff.txt +7 -0
- data/spec/support/outputs/rails_log.txt +1 -0
- data/spec/support/outputs/rails_with_arguments.txt +1 -0
- data/spec/support/outputs/rails_without_arguments.txt +1 -0
- data/spec/support/outputs/rake_with_arguments.txt +1 -0
- data/spec/support/outputs/rake_without_arguments.txt +1 -0
- data/spec/support/outputs/rbenv_load.txt +9 -1
- data/spec/support/outputs/rvm_use_with_env.txt +8 -0
- data/spec/support/outputs/rvm_use_without_env.txt +2 -0
- data/spec/support/outputs/rvm_wrapper_with_arguments.txt +8 -0
- data/spec/support/outputs/rvm_wrapper_without_arguments.txt +2 -0
- data/spec/support/outputs/ry_with_env.txt +13 -0
- data/spec/support/outputs/ry_without_env.txt +13 -0
- data/spec/support/outputs/ssh.txt +1 -0
- data/spec/support/outputs/ssh_keyscan_domain.txt +3 -0
- data/spec/support/rake_example_group.rb +23 -19
- data/spec/tasks/bundler_spec.rb +6 -0
- data/spec/tasks/chruby_spec.rb +29 -0
- data/spec/tasks/default_spec.rb +79 -7
- data/spec/tasks/deploy_spec.rb +6 -0
- data/spec/tasks/git_spec.rb +12 -0
- data/spec/tasks/init_spec.rb +13 -4
- data/spec/tasks/rails_spec.rb +126 -15
- data/spec/tasks/rbenv_spec.rb +15 -0
- data/spec/tasks/rvm_spec.rb +51 -0
- data/spec/tasks/ry_spec.rb +43 -0
- data/tasks/mina/bundler.rb +7 -5
- data/tasks/mina/chruby.rb +7 -5
- data/tasks/mina/default.rb +19 -12
- data/tasks/mina/deploy.rb +26 -24
- data/tasks/mina/git.rb +28 -16
- data/tasks/mina/install.rb +3 -1
- data/tasks/mina/rails.rb +29 -27
- data/tasks/mina/rbenv.rb +8 -6
- data/tasks/mina/rvm.rb +13 -11
- data/tasks/mina/ry.rb +11 -11
- data/test_env/config/deploy.rb +9 -8
- metadata +64 -32
- data/spec/support/outputs/chruby.txt +0 -9
- data/spec/support/outputs/console.txt +0 -1
- data/spec/support/outputs/log.txt +0 -1
- data/spec/support/outputs/rails_db_migrate.txt +0 -1
- data/spec/support/outputs/rvm_use.txt +0 -1
- data/spec/support/outputs/ry.txt +0 -15
- data/spec/tasks/ruby_managers_spec.rb +0 -33
data/tasks/mina/ry.rb
CHANGED
|
@@ -1,26 +1,26 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
1
3
|
set :ry_path, '$HOME/.local'
|
|
2
4
|
|
|
3
5
|
task :ry, :env do |_, args|
|
|
4
|
-
unless args[:env]
|
|
5
|
-
puts "Task 'ry' without argument will use default Ruby version."
|
|
6
|
-
end
|
|
6
|
+
puts "Task 'ry' without argument will use default Ruby version." unless args[:env]
|
|
7
7
|
|
|
8
|
-
comment %
|
|
9
|
-
comment %
|
|
8
|
+
comment %(ry to version: \\"#{args[:env] || '**not specified**'}\\")
|
|
9
|
+
comment %(Loading ry)
|
|
10
10
|
|
|
11
|
-
command %
|
|
11
|
+
command %(
|
|
12
12
|
if [[ ! -e "#{fetch(:ry_path)}/bin" ]]; then
|
|
13
13
|
echo "! ry not found"
|
|
14
14
|
echo "! If ry is installed, check your :ry_path setting."
|
|
15
15
|
exit 1
|
|
16
16
|
fi
|
|
17
|
-
|
|
18
|
-
command %
|
|
17
|
+
)
|
|
18
|
+
command %(export PATH="#{fetch(:ry_path)}/bin:$PATH")
|
|
19
19
|
command %{eval "$(ry setup)"}
|
|
20
|
-
command %
|
|
21
|
-
command %
|
|
20
|
+
command %(RY_RUBY="#{args[:env]}")
|
|
21
|
+
command %(
|
|
22
22
|
if [ -n "$RY_RUBY" ]; then
|
|
23
23
|
#{echo_cmd 'ry use $RY_RUBY'} || exit 1
|
|
24
24
|
fi
|
|
25
|
-
|
|
25
|
+
)
|
|
26
26
|
end
|
data/test_env/config/deploy.rb
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
1
3
|
# # NOTE:
|
|
2
4
|
# # Yes, you can deploy this project. It will deploy into the ./deploy/
|
|
3
5
|
# # directory. The commands have been stubbed, so it's harmless. No rails or
|
|
@@ -23,11 +25,10 @@ require 'mina/rvm'
|
|
|
23
25
|
require 'mina/rbenv'
|
|
24
26
|
require 'mina/chruby'
|
|
25
27
|
require 'pry'
|
|
26
|
-
#
|
|
27
28
|
|
|
28
29
|
set :domain, 'localhost'
|
|
29
30
|
set :deploy_to, "#{Dir.pwd}/deploy"
|
|
30
|
-
set :repository,
|
|
31
|
+
set :repository, Mina.root_path.to_s
|
|
31
32
|
set :shared_paths, ['config/database.yml', 'log']
|
|
32
33
|
set :keep_releases, 2
|
|
33
34
|
|
|
@@ -49,7 +50,7 @@ task :deploy do
|
|
|
49
50
|
invoke :'deploy:cleanup'
|
|
50
51
|
|
|
51
52
|
on :launch do
|
|
52
|
-
comment %
|
|
53
|
+
comment %(in launch)
|
|
53
54
|
end
|
|
54
55
|
end
|
|
55
56
|
end
|
|
@@ -57,17 +58,17 @@ end
|
|
|
57
58
|
desc 'Task description'
|
|
58
59
|
task :test do
|
|
59
60
|
run :remote do
|
|
60
|
-
comment %
|
|
61
|
+
comment %(PWD)
|
|
61
62
|
in_path('/Users') do
|
|
62
|
-
command %
|
|
63
|
+
command %(ls -al)
|
|
63
64
|
end
|
|
64
65
|
on :after do
|
|
65
|
-
command %
|
|
66
|
+
command %(pwd)
|
|
66
67
|
end
|
|
67
68
|
end
|
|
68
69
|
|
|
69
70
|
run :local do
|
|
70
|
-
command %
|
|
71
|
+
command %(ls -al)
|
|
71
72
|
end
|
|
72
73
|
end
|
|
73
74
|
|
|
@@ -75,7 +76,7 @@ desc 'Fails test'
|
|
|
75
76
|
task :fail do
|
|
76
77
|
run :remote do
|
|
77
78
|
run :local do
|
|
78
|
-
command
|
|
79
|
+
command 'pwd'
|
|
79
80
|
end
|
|
80
81
|
end
|
|
81
82
|
end
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: mina
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.2.
|
|
4
|
+
version: 1.2.5
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Stjepan Hadjić
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date:
|
|
11
|
+
date: 2023-10-03 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: rake
|
|
@@ -25,35 +25,21 @@ dependencies:
|
|
|
25
25
|
- !ruby/object:Gem::Version
|
|
26
26
|
version: '0'
|
|
27
27
|
- !ruby/object:Gem::Dependency
|
|
28
|
-
name:
|
|
28
|
+
name: pry
|
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
|
30
30
|
requirements:
|
|
31
|
-
- - "
|
|
32
|
-
- !ruby/object:Gem::Version
|
|
33
|
-
version: 1.3.4
|
|
34
|
-
type: :runtime
|
|
35
|
-
prerelease: false
|
|
36
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
37
|
-
requirements:
|
|
38
|
-
- - "~>"
|
|
39
|
-
- !ruby/object:Gem::Version
|
|
40
|
-
version: 1.3.4
|
|
41
|
-
- !ruby/object:Gem::Dependency
|
|
42
|
-
name: rspec
|
|
43
|
-
requirement: !ruby/object:Gem::Requirement
|
|
44
|
-
requirements:
|
|
45
|
-
- - "~>"
|
|
31
|
+
- - ">="
|
|
46
32
|
- !ruby/object:Gem::Version
|
|
47
|
-
version:
|
|
33
|
+
version: '0'
|
|
48
34
|
type: :development
|
|
49
35
|
prerelease: false
|
|
50
36
|
version_requirements: !ruby/object:Gem::Requirement
|
|
51
37
|
requirements:
|
|
52
|
-
- - "
|
|
38
|
+
- - ">="
|
|
53
39
|
- !ruby/object:Gem::Version
|
|
54
|
-
version:
|
|
40
|
+
version: '0'
|
|
55
41
|
- !ruby/object:Gem::Dependency
|
|
56
|
-
name:
|
|
42
|
+
name: rspec
|
|
57
43
|
requirement: !ruby/object:Gem::Requirement
|
|
58
44
|
requirements:
|
|
59
45
|
- - ">="
|
|
@@ -67,7 +53,7 @@ dependencies:
|
|
|
67
53
|
- !ruby/object:Gem::Version
|
|
68
54
|
version: '0'
|
|
69
55
|
- !ruby/object:Gem::Dependency
|
|
70
|
-
name:
|
|
56
|
+
name: rubocop
|
|
71
57
|
requirement: !ruby/object:Gem::Requirement
|
|
72
58
|
requirements:
|
|
73
59
|
- - ">="
|
|
@@ -81,7 +67,7 @@ dependencies:
|
|
|
81
67
|
- !ruby/object:Gem::Version
|
|
82
68
|
version: '0'
|
|
83
69
|
- !ruby/object:Gem::Dependency
|
|
84
|
-
name:
|
|
70
|
+
name: rubocop-rspec
|
|
85
71
|
requirement: !ruby/object:Gem::Requirement
|
|
86
72
|
requirements:
|
|
87
73
|
- - ">="
|
|
@@ -95,7 +81,7 @@ dependencies:
|
|
|
95
81
|
- !ruby/object:Gem::Version
|
|
96
82
|
version: '0'
|
|
97
83
|
- !ruby/object:Gem::Dependency
|
|
98
|
-
name:
|
|
84
|
+
name: simplecov
|
|
99
85
|
requirement: !ruby/object:Gem::Requirement
|
|
100
86
|
requirements:
|
|
101
87
|
- - ">="
|
|
@@ -124,6 +110,7 @@ files:
|
|
|
124
110
|
- ".rubocop.yml"
|
|
125
111
|
- CHANGELOG.md
|
|
126
112
|
- Gemfile
|
|
113
|
+
- Gemfile.lock
|
|
127
114
|
- LICENSE
|
|
128
115
|
- PRE_1_CHANGELOG.md
|
|
129
116
|
- Rakefile
|
|
@@ -133,6 +120,7 @@ files:
|
|
|
133
120
|
- data/deploy.sh.erb
|
|
134
121
|
- docs/3rd_party_plugins.md
|
|
135
122
|
- docs/Readme.md
|
|
123
|
+
- docs/assets/images/mina.png
|
|
136
124
|
- docs/cookbook.md
|
|
137
125
|
- docs/default_plugins.md
|
|
138
126
|
- docs/deploying.md
|
|
@@ -159,47 +147,91 @@ files:
|
|
|
159
147
|
- lib/mina/version.rb
|
|
160
148
|
- lib/mina/windows_patches.rb
|
|
161
149
|
- mina.gemspec
|
|
150
|
+
- spec/configs/default.rb
|
|
151
|
+
- spec/configs/dsl.rb
|
|
152
|
+
- spec/configs/e2e.rb
|
|
153
|
+
- spec/e2e/docker-compose.yml
|
|
154
|
+
- spec/e2e/e2e_run.sh
|
|
155
|
+
- spec/e2e/e2e_spec.rb
|
|
156
|
+
- spec/e2e/ssh
|
|
157
|
+
- spec/e2e/ssh.pub
|
|
162
158
|
- spec/lib/mina/application_spec.rb
|
|
163
159
|
- spec/lib/mina/backend/local_spec.rb
|
|
164
160
|
- spec/lib/mina/backend/remote_spec.rb
|
|
165
161
|
- spec/lib/mina/commands_spec.rb
|
|
166
162
|
- spec/lib/mina/configuration_spec.rb
|
|
163
|
+
- spec/lib/mina/dsl_spec.rb
|
|
167
164
|
- spec/lib/mina/helpers/internal_spec.rb
|
|
168
165
|
- spec/lib/mina/helpers/output_spec.rb
|
|
166
|
+
- spec/lib/mina/runner/exec_spec.rb
|
|
167
|
+
- spec/lib/mina/runner/pretty_spec.rb
|
|
168
|
+
- spec/lib/mina/runner/printer_spec.rb
|
|
169
|
+
- spec/lib/mina/runner/system_spec.rb
|
|
169
170
|
- spec/lib/mina/runner_spec.rb
|
|
170
171
|
- spec/spec_helper.rb
|
|
171
172
|
- spec/support/outputs/bundle_clean.txt
|
|
172
173
|
- spec/support/outputs/bundle_install.txt
|
|
173
|
-
- spec/support/outputs/
|
|
174
|
-
- spec/support/outputs/
|
|
174
|
+
- spec/support/outputs/chruby_with_env.txt
|
|
175
|
+
- spec/support/outputs/chruby_without_env.txt
|
|
176
|
+
- spec/support/outputs/debug_configuration_variables.txt
|
|
175
177
|
- spec/support/outputs/deploy_cleanup.txt
|
|
176
178
|
- spec/support/outputs/deploy_force_unlock.txt
|
|
177
179
|
- spec/support/outputs/deploy_link_shared_paths.txt
|
|
180
|
+
- spec/support/outputs/dsl_deploy.txt
|
|
181
|
+
- spec/support/outputs/dsl_in_path.txt
|
|
182
|
+
- spec/support/outputs/dsl_local_run.txt
|
|
183
|
+
- spec/support/outputs/dsl_on.txt
|
|
184
|
+
- spec/support/outputs/dsl_remote_run.txt
|
|
185
|
+
- spec/support/outputs/dsl_reset.txt
|
|
186
|
+
- spec/support/outputs/e2e_deploy_after_setup.txt
|
|
187
|
+
- spec/support/outputs/e2e_deploy_without_setup.txt
|
|
188
|
+
- spec/support/outputs/e2e_setup.txt
|
|
189
|
+
- spec/support/outputs/environment.txt
|
|
178
190
|
- spec/support/outputs/git_clone.txt
|
|
179
191
|
- spec/support/outputs/git_clone_commit.txt
|
|
192
|
+
- spec/support/outputs/git_ensure_pushed.txt
|
|
180
193
|
- spec/support/outputs/git_revision.txt
|
|
181
|
-
- spec/support/outputs/log.txt
|
|
182
194
|
- spec/support/outputs/rails_assets_clean.txt
|
|
183
195
|
- spec/support/outputs/rails_assets_precompile.txt
|
|
196
|
+
- spec/support/outputs/rails_assets_precompile_force_precompile.txt
|
|
197
|
+
- spec/support/outputs/rails_assets_precompile_outside_deploy_block.txt
|
|
198
|
+
- spec/support/outputs/rails_assets_precompile_with_diff.txt
|
|
199
|
+
- spec/support/outputs/rails_console.txt
|
|
184
200
|
- spec/support/outputs/rails_db_create.txt
|
|
185
|
-
- spec/support/outputs/
|
|
201
|
+
- spec/support/outputs/rails_db_migrate_force_migrate.txt
|
|
202
|
+
- spec/support/outputs/rails_db_migrate_outside_deploy_block.txt
|
|
203
|
+
- spec/support/outputs/rails_db_migrate_with_diff.txt
|
|
186
204
|
- spec/support/outputs/rails_db_rollback.txt
|
|
187
205
|
- spec/support/outputs/rails_db_schema_load.txt
|
|
206
|
+
- spec/support/outputs/rails_log.txt
|
|
207
|
+
- spec/support/outputs/rails_with_arguments.txt
|
|
208
|
+
- spec/support/outputs/rails_without_arguments.txt
|
|
209
|
+
- spec/support/outputs/rake_with_arguments.txt
|
|
210
|
+
- spec/support/outputs/rake_without_arguments.txt
|
|
188
211
|
- spec/support/outputs/rbenv_load.txt
|
|
189
212
|
- spec/support/outputs/rollback.txt
|
|
190
213
|
- spec/support/outputs/run.txt
|
|
191
|
-
- spec/support/outputs/
|
|
192
|
-
- spec/support/outputs/
|
|
214
|
+
- spec/support/outputs/rvm_use_with_env.txt
|
|
215
|
+
- spec/support/outputs/rvm_use_without_env.txt
|
|
216
|
+
- spec/support/outputs/rvm_wrapper_with_arguments.txt
|
|
217
|
+
- spec/support/outputs/rvm_wrapper_without_arguments.txt
|
|
218
|
+
- spec/support/outputs/ry_with_env.txt
|
|
219
|
+
- spec/support/outputs/ry_without_env.txt
|
|
193
220
|
- spec/support/outputs/setup.txt
|
|
221
|
+
- spec/support/outputs/ssh.txt
|
|
222
|
+
- spec/support/outputs/ssh_keyscan_domain.txt
|
|
194
223
|
- spec/support/outputs/ssh_keyscan_repo.txt
|
|
195
224
|
- spec/support/rake_example_group.rb
|
|
196
225
|
- spec/tasks/bundler_spec.rb
|
|
226
|
+
- spec/tasks/chruby_spec.rb
|
|
197
227
|
- spec/tasks/default_spec.rb
|
|
198
228
|
- spec/tasks/deploy_spec.rb
|
|
199
229
|
- spec/tasks/git_spec.rb
|
|
200
230
|
- spec/tasks/init_spec.rb
|
|
201
231
|
- spec/tasks/rails_spec.rb
|
|
202
|
-
- spec/tasks/
|
|
232
|
+
- spec/tasks/rbenv_spec.rb
|
|
233
|
+
- spec/tasks/rvm_spec.rb
|
|
234
|
+
- spec/tasks/ry_spec.rb
|
|
203
235
|
- tasks/mina/bundler.rb
|
|
204
236
|
- tasks/mina/chruby.rb
|
|
205
237
|
- tasks/mina/default.rb
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
\(cd\ .*/deploy/current\ &&\ RAILS_ENV="production"\ bundle\ exec\ rails\ console\ &&\ cd\ -\)
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
\(cd\ .*deploy/shared/log\ &&\ tail\ \-f\ production\.log\ &&\ cd\ -\)
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
if\ diff\ \-qrN\ ".*deploy/current/db/migrate"\ "\./db/migrate"\ 2>/dev/null\s*then\s*echo\ "\-\-\-\-\->\ DB\ migrations\ unchanged;\ skipping\ DB\ migration"\s*else\s*echo\ "\-\-\-\-\->\ Migrating\ database"\s*RAILS_ENV="production"\ bundle\ exec\ rake\ db:migrate\s*fi
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
echo\ "\-\-\-\-\->\ Using\ RVM\ environment\ \\\"123\\\"\"\s*if\ \[\[\ !\ \-s\ "\$HOME/\.rvm/scripts/rvm"\ \]\];\ then\s*echo\ "!\ Ruby\ Version\ Manager\ not\ found"\s*echo\ "!\ If\ RVM\ is\ installed,\ check\ your\ :rvm_use_path\ setting\."\s*exit 1\s*fi\s*source\ \$HOME/\.rvm/scripts/rvm\n\s*rvm\ use\ \"123\"\ \-\-create
|
data/spec/support/outputs/ry.txt
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
echo "-----> Loading ry"
|
|
2
|
-
|
|
3
|
-
if [[ ! -e "$HOME/.local/bin" ]]; then
|
|
4
|
-
echo "! ry not found"
|
|
5
|
-
echo "! If ry is installed, check your :ry_path setting."
|
|
6
|
-
exit 1
|
|
7
|
-
fi
|
|
8
|
-
|
|
9
|
-
export PATH="$HOME/.local/bin:$PATH"
|
|
10
|
-
eval "$(ry setup)"
|
|
11
|
-
RY_RUBY=""
|
|
12
|
-
|
|
13
|
-
if [ -n "$RY_RUBY" ]; then
|
|
14
|
-
ry use $RY_RUBY || exit 1
|
|
15
|
-
fi
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
require 'spec_helper'
|
|
2
|
-
|
|
3
|
-
RSpec.describe 'ruby_managers', type: :rake do
|
|
4
|
-
describe 'ry' do
|
|
5
|
-
it 'ry' do
|
|
6
|
-
expect { invoke_all }.to output(output_file('ry')).to_stdout
|
|
7
|
-
end
|
|
8
|
-
end
|
|
9
|
-
|
|
10
|
-
describe 'rbenv:load' do
|
|
11
|
-
it 'rbenv:load' do
|
|
12
|
-
expect { invoke_all }.to output(output_file('rbenv_load')).to_stdout
|
|
13
|
-
end
|
|
14
|
-
end
|
|
15
|
-
|
|
16
|
-
describe 'chruby' do
|
|
17
|
-
it 'chruby' do
|
|
18
|
-
expect { invoke_all('123') }.to output(output_file('chruby')).to_stdout
|
|
19
|
-
end
|
|
20
|
-
end
|
|
21
|
-
|
|
22
|
-
describe 'rvm:use' do
|
|
23
|
-
it 'rvm:use' do
|
|
24
|
-
expect { invoke_all('123') }.to output(output_file('rvm_use')).to_stdout
|
|
25
|
-
end
|
|
26
|
-
end
|
|
27
|
-
|
|
28
|
-
# describe 'rvm:wrapper' do
|
|
29
|
-
# it 'rails db migrate' do
|
|
30
|
-
# expect { invoke_all('123') }.to output('').to_stdout
|
|
31
|
-
# end
|
|
32
|
-
# end
|
|
33
|
-
end
|