cyborg 0.5.7 → 0.5.8

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 1cddb387475ec938aa53e54febb779a2661dfe48
4
- data.tar.gz: 3fac26915273b3500334685edd6729edf417f36b
3
+ metadata.gz: 10c7fc85107d039e3be21f652f763aa41b20a88b
4
+ data.tar.gz: ddaf07aefc6cb04c9ac8c3e5500e8c8aa10308ad
5
5
  SHA512:
6
- metadata.gz: c804eee39819f9875e037bee952ce285cf1b1b1fd083ee9ff9544a29097a8751dd3f6ba0dd3f72e093a9a75e233bdc1e6e7e7c0585b904d863e04f250ec44bbc
7
- data.tar.gz: 2fe26e3d1a9ec1d8293d553cb197c11ec0881680ba653cef5ac8811f4f0f52842beb44ab34cd522ca262c60079295e221739cc53e75daea947b734b6d04ec256
6
+ metadata.gz: 96fb13b716595b0cef0159a54a67b66a56b54436ce839493419836e2a31e0b41f19c6c26f10df7ea63dd4096615986702a40161c41de380ab02a6fe948fada12
7
+ data.tar.gz: 460761c7b551ab79799bdbf46e4549f8591310e00c76497771cae9a2780611c280f318eb7ecad253b6fea99de9d3f9bedc2d1fc15c0b183f54833dd3bc7bebf1
data/bin/cyborg CHANGED
@@ -48,17 +48,21 @@ OptionParser.new do |opts|
48
48
  options[:select_assets] = true
49
49
  options[:js] = true
50
50
  end
51
+
51
52
  opts.on("-c", "--css", "Build css.") do |val|
52
53
  options[:select_assets] = true
53
54
  options[:css] = true
54
55
  end
56
+
55
57
  opts.on("-s", "--svg", "Build svgs.") do |val|
56
58
  options[:select_assets] = true
57
59
  options[:svg] = true
58
60
  end
61
+
59
62
  opts.on("-P", "--production", "Build assets as with production mode.") do |val|
60
63
  options[:production] = true
61
64
  end
65
+
62
66
  opts.on("-C", "--clean", "Remove cache files before build.") do |val|
63
67
  options[:clean] = true
64
68
  end
@@ -68,6 +72,10 @@ OptionParser.new do |opts|
68
72
  opts.on("-p", "--port PORT", String, "serve site at port") do |val|
69
73
  options[:port] = val
70
74
  end
75
+
76
+ opts.on("-b", "--bind HOST", String, "Bind to a specific host, e.g. 0.0.0.0") do |val|
77
+ options[:host] = val
78
+ end
71
79
  end
72
80
 
73
81
  opts.on("-v", "--version", "Print version") do |version|
@@ -89,8 +89,8 @@ module Cyborg
89
89
  File.join asset_prefix, name
90
90
  end
91
91
 
92
- def production_asset_root
93
- @production_asset_root || asset_root
92
+ def production_root
93
+ @production_asset_root ||= asset_root
94
94
  end
95
95
 
96
96
  def config(options)
@@ -128,8 +128,8 @@ module Cyborg
128
128
 
129
129
  def asset_url(file=nil)
130
130
 
131
- path = if Cyborg.production?
132
- production_asset_root
131
+ path = if Cyborg.production? || ENV[name.upcase + '_FORCE_LOCAL_ASSETS']
132
+ production_root
133
133
  else
134
134
  asset_root
135
135
  end
@@ -1,3 +1,3 @@
1
1
  module Cyborg
2
- VERSION = "0.5.7"
2
+ VERSION = "0.5.8"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cyborg
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.7
4
+ version: 0.5.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brandon Mathis
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-01-27 00:00:00.000000000 Z
11
+ date: 2017-01-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: sass