awestruct 0.4.2.x7 → 0.4.2.x8

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.
@@ -14,7 +14,8 @@ module Awestruct
14
14
 
15
15
  def run()
16
16
  begin
17
- puts "Generating site"
17
+ base_url = @profile['base_url'] || @default_base_url
18
+ puts "Generating site: #{base_url}"
18
19
  @engine.run( @profile, @base_url, ( @profile ? @profile['base_url'] : @default_base_url ), @force )
19
20
  rescue =>e
20
21
  puts e
@@ -54,14 +54,22 @@ module Awestruct
54
54
  nil
55
55
  else
56
56
  if options.profile
57
- profiles_data[options.profile]
57
+ profiles_data[options.profile] || {}
58
58
  else
59
59
  # if no profile given, pick the first with deploy config
60
60
  options.profile, profile_data = profiles_data.select { |k,v| v && v['deploy'] }.first
61
+ profile_data
61
62
  end
62
63
  end
63
64
  end
64
65
  end
66
+
67
+ unless @profile
68
+ $stderr.puts "Unable to locate profile: #{options.profile}" if options.profile
69
+ options.profile = 'NONE'
70
+ @profile = {}
71
+ end
72
+ $stderr.puts "Using profile: #{options.profile}"
65
73
  end
66
74
 
67
75
  def setup_config()
@@ -1,4 +1,4 @@
1
1
 
2
2
  module Awestruct
3
- VERSION='0.4.2.x7'
3
+ VERSION='0.4.2.x8'
4
4
  end
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: awestruct
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease: 6
5
- version: 0.4.2.x7
5
+ version: 0.4.2.x8
6
6
  platform: ruby
7
7
  authors:
8
8
  - Bob McWhirter
@@ -313,7 +313,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
313
313
  requirements:
314
314
  - - ">="
315
315
  - !ruby/object:Gem::Version
316
- hash: -3441842577235075834
316
+ hash: -4586524403344190985
317
317
  segments:
318
318
  - 0
319
319
  version: "0"