theme-juice 0.1.3 → 0.1.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 4964da65fba7f6f253d08619b19586abf43665bc
4
- data.tar.gz: 70d86b05315d3bfb93f82a48cf8ce7c633e7a974
3
+ metadata.gz: 565a687f643fc79093fb63727ce6c83d4da53a34
4
+ data.tar.gz: 513290bb744155430c37c5f99042427847cfb423
5
5
  SHA512:
6
- metadata.gz: e8793bb4a4d6823dd35984a6f9e435468c12f56175eaac2f33738015388606db66f29abc2d4d05e501e64984b20710e7116aaa07d10dfa425f2c6f2823ce3f5a
7
- data.tar.gz: 29096f37c0136ea829cfe4996041823d96cabee04ae127d3823a70631f6baafd804340299bba268bcf91e27a564596fbdc2f63d1eae4f1bfc3cc3d259412c967
6
+ metadata.gz: 4288bdd288904940cc20289de4b484759470e62ee6b7734e839af6e45b8544105f20602ed62d7e68c3f7c385d097c9b3b2ccb3bc7137ad07b18ba9b4b5a32802
7
+ data.tar.gz: 6d622f07646dc65b9b376a7850231f72f7fe47b4d4ff074ed37d385600168d2564a79f6b61c583203111f86ad606b766600066717f0347a23da4ffbf62c79a42
@@ -63,7 +63,7 @@ module ThemeJuice
63
63
  setup_synced_folder
64
64
  end
65
65
 
66
- unless wpcli_is_setup?
66
+ if wpcli_exists?
67
67
  setup_wpcli
68
68
  end
69
69
 
@@ -273,8 +273,8 @@ module ThemeJuice
273
273
  ###
274
274
  # @return {Bool}
275
275
  ###
276
- def wpcli_is_setup?
277
- File.readlines(File.expand_path("#{@opts[:site_location]}/wp-cli.yml")).grep(/(### Begin '#{@opts[:site_name]}')/m).any?
276
+ def wpcli_exists?
277
+ File.exists? File.expand_path("#{@opts[:site_location]}/wp-cli.yml")
278
278
  end
279
279
 
280
280
  ###
@@ -492,10 +492,6 @@ module ThemeJuice
492
492
  ###
493
493
  def setup_wpcli
494
494
  File.open "#{@opts[:site_location]}/wp-cli.yml", "a+" do |file|
495
- file.puts "### Begin '#{@opts[:site_name]}'"
496
- file.puts "#"
497
- file.puts "# This block is automatically generated by ThemeJuice. Do not edit."
498
- file.puts "###"
499
495
  file.puts "require:"
500
496
  file.puts "\t- vendor/autoload.php"
501
497
  file.puts "ssh:"
@@ -503,15 +499,9 @@ module ThemeJuice
503
499
  file.puts "\t\turl: #{@opts[:dev_url]}"
504
500
  file.puts "\t\tpath: /srv/www/tj-#{@opts[:site_name]}"
505
501
  file.puts "\t\tcmd: cd ~/vagrant && vagrant ssh-config > /tmp/vagrant_ssh_config && ssh -q %pseudotty% -F /tmp/vagrant_ssh_config default %cmd%"
506
- file.puts "### End '#{@opts[:site_name]}'"
507
502
  file.puts "\n"
508
503
  end
509
-
510
- if wpcli_is_setup?
511
- say "Successfully added ssh settings to 'wp-cli.yml'.", :green
512
- else
513
- say "Could not add ssh settings for '#{@opts[:site_name]}' to 'wp-cli.yml'.", :red
514
- end
504
+ say "Successfully added ssh settings to 'wp-cli.yml'.", :green
515
505
  end
516
506
 
517
507
  ###
@@ -1,3 +1,3 @@
1
1
  module ThemeJuice
2
- VERSION = "0.1.3"
2
+ VERSION = "0.1.4"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: theme-juice
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.3
4
+ version: 0.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ezekiel Gabrielse
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-12-09 00:00:00.000000000 Z
11
+ date: 2014-12-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: thor