wpcli 0.2.0 → 0.2.1

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: 7420ce749bad764f4dda2f91b153f58960e83b96
4
- data.tar.gz: e50fd5760ae5ff81b700fce11b0a11b8e46302fd
3
+ metadata.gz: 7bce31a88598058efbab2fac04d858af2ea143da
4
+ data.tar.gz: 8f29072e069a89cc2854975b8a4f11df7a791d96
5
5
  SHA512:
6
- metadata.gz: 2ae33c6283a5f25718357318e4256e5cf4a6c6d7f11e35bab2c117846b0d415817a92e7b794586117fb9d98aba75b9d17895541360c6cda6eb955259d30a326e
7
- data.tar.gz: 544697a49646184df988918d1ba4b87809e3db528925715da58b755db9daf34763057444ce9957744f64334b9bb04affc807e22479a9aa0e4ec8c54b5522ce7c
6
+ metadata.gz: 7865e76f6da19e776df1d941338a77668fe4584e29870e26781a4e62554f0132633bfd511ca53e735d04bc8c3b0a50754fe5521198a9e32309532ec285154eb8
7
+ data.tar.gz: 1177e7632ff0fb12efd50bfefe63971975e392fafcd9282baab69ee6da2fd053deb56e3b1bc444061e38e2e41552206beda8e97af23616e32646d1b035f559d9
data/README.md CHANGED
@@ -8,7 +8,7 @@ Just pass commands (http://wp-cli.org/commands/) to run method and use returned
8
8
 
9
9
  Add this line to your application's Gemfile:
10
10
 
11
- gem 'wpcli', "~> 0.2.0"
11
+ gem 'wpcli', "~> 0.2.1"
12
12
 
13
13
  And then execute:
14
14
 
@@ -60,4 +60,4 @@ If you like to use client for example in command line, you can create instance w
60
60
  4. Push to the branch (`git push origin my-new-feature`)
61
61
  5. Create new Pull Request
62
62
 
63
- [![Gem Version](https://badge.fury.io/rb/wpcli.png)](http://badge.fury.io/rb/wpcli) [![Build Status](https://travis-ci.org/hasanen/wpcli.png?branch=master)](https://travis-ci.org/hasanen/wpcli)
63
+ [![Gem Version](https://badge.fury.io/rb/wpcli.png)](http://badge.fury.io/rb/wpcli) [![Build Status](https://travis-ci.org/hasanen/wpcli.png?branch=master)](https://travis-ci.org/hasanen/wpcli)[![Coverage Status](https://coveralls.io/repos/hasanen/wpcli/badge.png?branch=master)](https://coveralls.io/r/hasanen/wpcli?branch=master)
data/lib/wpcli/rails.rb CHANGED
@@ -1,24 +1,26 @@
1
1
  module Wpcli
2
- def wpcli key
3
- load_apps if @apps.nil?
4
- @apps[key]
5
- end
2
+ module RailsExt
3
+ def wpcli key
4
+ load_apps if @apps.nil?
5
+ @apps[key]
6
+ end
6
7
 
7
- def wp_apps?
8
- load_apps if @apps.nil?
9
- !@apps.empty?
10
- end
8
+ def wp_apps?
9
+ load_apps if @apps.nil?
10
+ !@apps.empty?
11
+ end
11
12
 
12
- private
13
+ private
13
14
 
14
- def load_apps
15
- file = File.read("#{Rails.root}/config/wpcli.yml")
16
- config = YAML.load(file)
15
+ def load_apps
16
+ file = File.read("#{Rails.root}/config/wpcli.yml")
17
+ config = YAML.load(file)
17
18
 
18
- @apps = {}
19
- if config.has_key?("apps") && !config["apps"].nil?
20
- config["apps"].each do |key, path|
21
- @apps[key.to_sym] = Client.new path
19
+ @apps = {}
20
+ if config.has_key?("apps") && !config["apps"].nil?
21
+ config["apps"].each do |key, path|
22
+ @apps[key.to_sym] = Client.new path
23
+ end
22
24
  end
23
25
  end
24
26
  end
data/lib/wpcli/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Wpcli
2
- VERSION = "0.2.0"
2
+ VERSION = "0.2.1"
3
3
  end
data/spec/spec_helper.rb CHANGED
@@ -1,9 +1,5 @@
1
- # This file was generated by the `rspec --init` command. Conventionally, all
2
- # specs live under a `spec` directory, which RSpec adds to the `$LOAD_PATH`.
3
- # Require this file using `require "spec_helper"` to ensure that it is only
4
- # loaded once.
5
- #
6
- # See http://rubydoc.info/gems/rspec-core/RSpec/Core/Configuration
1
+ require 'coveralls'
2
+ Coveralls.wear!
7
3
 
8
4
  require_relative "../lib/wpcli"
9
5
 
@@ -11,10 +7,5 @@ RSpec.configure do |config|
11
7
  config.treat_symbols_as_metadata_keys_with_true_values = true
12
8
  config.run_all_when_everything_filtered = true
13
9
  config.filter_run :focus
14
-
15
- # Run specs in random order to surface order dependencies. If you find an
16
- # order dependency and want to debug it, you can fix the order by providing
17
- # the seed, which is printed after each run.
18
- # --seed 1234
19
10
  config.order = 'random'
20
11
  end
data/wpcli.gemspec CHANGED
@@ -21,4 +21,5 @@ Gem::Specification.new do |spec|
21
21
  spec.add_development_dependency "bundler", "~> 1.3"
22
22
  spec.add_development_dependency "rake", "~> 10.1.0"
23
23
  spec.add_development_dependency "rspec", "~> 2.14.1"
24
+ spec.add_development_dependency 'coveralls', '~> 0.7.0'
24
25
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: wpcli
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Joni Hasanen
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-02-09 00:00:00.000000000 Z
11
+ date: 2014-02-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -52,6 +52,20 @@ dependencies:
52
52
  - - ~>
53
53
  - !ruby/object:Gem::Version
54
54
  version: 2.14.1
55
+ - !ruby/object:Gem::Dependency
56
+ name: coveralls
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - ~>
60
+ - !ruby/object:Gem::Version
61
+ version: 0.7.0
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - ~>
67
+ - !ruby/object:Gem::Version
68
+ version: 0.7.0
55
69
  description: Simple wrapper for wp-cli (http://wp-cli.org/)
56
70
  email:
57
71
  - joni.hasanen@pieceofcode.net