terraspace 0.5.2 → 0.5.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/lib/terraspace/cli/check_setup.rb +11 -3
- data/lib/terraspace/command.rb +1 -1
- data/lib/terraspace/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3046cd50c2a592878bc84dce2fdf21f00fbcf93e4a4fd47a57fe59fbab87adf5
|
4
|
+
data.tar.gz: 154ec374284a4758b3e45111653e67d7540ad0ed02661cabd2b5dfa1f79ad35c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ab3def1c9c10a952aef42cbea27de2c645627c69af0ae452baceef36c15ed6f87abd43ab2cda16b0d1f76bc0080a50eb75d802ef6f540e77c13a7796a46ba78f
|
7
|
+
data.tar.gz: 2b6e9314e91cd27ef3e19e3a827006dbc081ae8a7ad0d38da445482bc503f978d38575470836f91b1a9a10799fb707d8dacb895818b94a513e46a64f14cbf1da
|
data/CHANGELOG.md
CHANGED
@@ -3,6 +3,10 @@
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
4
4
|
This project *loosely tries* to adhere to [Semantic Versioning](http://semver.org/), even before v1.0.
|
5
5
|
|
6
|
+
## [0.5.3] - 2020-11-27
|
7
|
+
- [#60](https://github.com/boltops-tools/terraspace/pull/60) fix terraspace check_setup, use type and allow to run outside project
|
8
|
+
- improve terraform is not installed message
|
9
|
+
|
6
10
|
## [0.5.2] - 2020-11-27
|
7
11
|
- [#59](https://github.com/boltops-tools/terraspace/pull/59) only run bundler/setup within terraspace project and check standalone install
|
8
12
|
- fix terraspace help
|
@@ -17,7 +17,7 @@ class Terraspace::CLI
|
|
17
17
|
puts "Detected #{terraform_version_message}"
|
18
18
|
check_required_version!
|
19
19
|
else
|
20
|
-
puts
|
20
|
+
puts terraform_is_not_installed
|
21
21
|
exit 1
|
22
22
|
end
|
23
23
|
end
|
@@ -38,9 +38,16 @@ class Terraspace::CLI
|
|
38
38
|
ARGV[0] == "check_setup"
|
39
39
|
end
|
40
40
|
|
41
|
+
def terraform_is_not_installed
|
42
|
+
<<~EOL
|
43
|
+
Terraform not installed. Unable to detect a terraform command. Please double check that terraform is installed.
|
44
|
+
See: https://terraform.cloud/docs/install/terraform/
|
45
|
+
EOL
|
46
|
+
end
|
47
|
+
|
41
48
|
def ok?
|
42
49
|
unless terraform_bin
|
43
|
-
puts
|
50
|
+
puts terraform_is_not_installed
|
44
51
|
exit 1
|
45
52
|
end
|
46
53
|
|
@@ -57,7 +64,8 @@ class Terraspace::CLI
|
|
57
64
|
end
|
58
65
|
|
59
66
|
def terraform_bin
|
60
|
-
|
67
|
+
out = `type terraform 2>&1`.strip
|
68
|
+
bin_path = out.match(/is (.*)/)[1]
|
61
69
|
bin_path if $?.success?
|
62
70
|
end
|
63
71
|
memoize :terraform_bin
|
data/lib/terraspace/command.rb
CHANGED
@@ -94,7 +94,7 @@ module Terraspace
|
|
94
94
|
def check_project!(command_name)
|
95
95
|
return if subcommand?
|
96
96
|
return if command_name.nil?
|
97
|
-
return if %w[-h -v completion completion_script help new test version].include?(command_name)
|
97
|
+
return if %w[-h -v check_setup completion completion_script help new test version].include?(command_name)
|
98
98
|
return if File.exist?("#{Terraspace.root}/config/app.rb")
|
99
99
|
logger.error "ERROR: It doesnt look like this is a terraspace project. Are you sure you are in a terraspace project?".color(:red)
|
100
100
|
ENV['TS_TEST'] ? raise : exit(1)
|
data/lib/terraspace/version.rb
CHANGED