theme-juice 0.6.5 → 0.6.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/theme-juice/service.rb +2 -2
- data/lib/theme-juice/services/create_site.rb +8 -10
- data/lib/theme-juice/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f0e8e49ed6690203699cd75872e527f2172b537b
|
4
|
+
data.tar.gz: 377ba96a2c4063cbaeabceac6d1dc0b42233989d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0ea2fd878b16908385cbb19280471de4451b3cf172fea0b7aed822e7b2782871768a016af70b37955e28bb84426d8dfa8bc5b1165527520067d1d8bd5e425107
|
7
|
+
data.tar.gz: 5ac5d180650ebfa92052a92c797e5100a12ad85f8612cc12217f4ae67850ea2b9a2e3a6cbaba91213105fab351bfbf17be564aaf3350a65a5799b28d6d221930
|
data/lib/theme-juice/service.rb
CHANGED
@@ -148,8 +148,8 @@ module ThemeJuice
|
|
148
148
|
#
|
149
149
|
# @return {Bool}
|
150
150
|
#
|
151
|
-
def
|
152
|
-
!Dir["#{@opts[:site_location]}/*"].select { |f| File.basename(f) =~ %r{wp(-content)?|wordpress|app|content} }.empty?
|
151
|
+
def starter_theme_is_setup?
|
152
|
+
!Dir["#{@opts[:site_location]}/*"].select { |f| File.basename(f) =~ %r{wp(-content)?|wordpress|app|public|web|content} }.empty?
|
153
153
|
end
|
154
154
|
|
155
155
|
#
|
@@ -21,7 +21,7 @@ module ThemeJuice
|
|
21
21
|
@interaction.notice "Running setup for '#{@opts[:site_name]}'"
|
22
22
|
|
23
23
|
setup_project_dir unless project_dir_is_setup?
|
24
|
-
|
24
|
+
setup_starter_theme unless starter_theme_is_setup?
|
25
25
|
setup_vvv unless vvv_is_setup?
|
26
26
|
setup_wildcard_subdomains unless wildcard_subdomains_is_setup?
|
27
27
|
setup_hosts unless hosts_is_setup?
|
@@ -265,25 +265,23 @@ module ThemeJuice
|
|
265
265
|
end
|
266
266
|
|
267
267
|
#
|
268
|
-
#
|
269
|
-
#
|
270
|
-
# Clones starter theme into site location
|
268
|
+
# Clone starter theme into site location, run install
|
271
269
|
#
|
272
270
|
# @return {Void}
|
273
271
|
#
|
274
|
-
def
|
272
|
+
def setup_starter_theme
|
275
273
|
unless @opts[:site_bare]
|
276
|
-
@interaction.log "Setting up
|
274
|
+
@interaction.log "Setting up starter theme"
|
277
275
|
|
278
276
|
run [
|
279
277
|
"cd #{@opts[:site_location]}",
|
280
278
|
"git clone --depth 1 #{@opts[:site_starter_theme]} .",
|
281
279
|
]
|
282
280
|
|
283
|
-
if
|
284
|
-
|
281
|
+
if starter_theme_is_setup?
|
282
|
+
install_starter_theme_dependencies if config_is_setup?
|
285
283
|
else
|
286
|
-
@interaction.error "Could not setup
|
284
|
+
@interaction.error "Could not setup starter theme. Make sure you have write capabilities to '#{@opts[:site_location]}'."
|
287
285
|
end
|
288
286
|
end
|
289
287
|
end
|
@@ -365,7 +363,7 @@ module ThemeJuice
|
|
365
363
|
#
|
366
364
|
# @return {Void}
|
367
365
|
#
|
368
|
-
def
|
366
|
+
def install_starter_theme_dependencies
|
369
367
|
use_config
|
370
368
|
|
371
369
|
@interaction.log "Installing theme dependencies"
|
data/lib/theme-juice/version.rb
CHANGED